guard_against_physical_delete:guard_against_physical_delete是ActiveRecord的猴子补丁。 该补丁可防止物理删除记录

时间:2024-05-28 08:53:14
【文件属性】:

文件名称:guard_against_physical_delete:guard_against_physical_delete是ActiveRecord的猴子补丁。 该补丁可防止物理删除记录

文件大小:11KB

文件格式:ZIP

更新时间:2024-05-28 08:53:14

Ruby

guard_against_physical_delete guard_against_physical_delete是ActiveRecord的猴子补丁。 此修补程序可防止物理删除记录。 设置逻辑删除列名称。 (默认是:deleted_at) Logical . logical_delete_column = :removed_at Logical . first . delete #=> raise GuardAgainstPhysicalDelete::PhysicalDeleteError Logical . physical_delete { Logical . first . delete } #=> allow physical_delete 支持 active_record> = 4.1.0,<5.1.0 版权 版权所有:copyright:2012 morita shingo。 有


【文件预览】:
guard_against_physical_delete-master
----.travis.yml(108B)
----Rakefile(406B)
----License.txt(1KB)
----guard_against_physical_delete.gemspec(1KB)
----README.rdoc(536B)
----Gemfile(39B)
----spec()
--------database.rb(2KB)
--------guard_against_physical_delete()
--------spec_helper.rb(416B)
----.gitignore(47B)
----lib()
--------guard_against_physical_delete.rb(582B)
--------guard_against_physical_delete()

网友评论