Module: Paranoid2::Scoping::ClassMethods
- Defined in:
- lib/paranoid2/scoping.rb
Instance Method Summary collapse
Instance Method Details
#only_deleted ⇒ Object
15 16 17 |
# File 'lib/paranoid2/scoping.rb', line 15 def only_deleted with_deleted.where.not(deleted_at: nil) end |
#paranoid_scope ⇒ Object
11 12 13 |
# File 'lib/paranoid2/scoping.rb', line 11 def paranoid_scope where(deleted_at: nil) end |
#with_deleted ⇒ Object
Rails < 4.1
22 23 24 |
# File 'lib/paranoid2/scoping.rb', line 22 def with_deleted unscope(where: :deleted_at) end |