The code powering m.abunchtell.com https://m.abunchtell.com
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符
 
 
 
 

24 行
391 B

  1. # frozen_string_literal: true
  2. class ApplicationRecord < ActiveRecord::Base
  3. self.abstract_class = true
  4. include Remotable
  5. class << self
  6. def update_index(_type_name, *_args, &_block)
  7. super if Chewy.enabled?
  8. end
  9. end
  10. def boolean_with_default(key, default_value)
  11. value = attributes[key]
  12. if value.nil?
  13. default_value
  14. else
  15. value
  16. end
  17. end
  18. end