You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
6 lines
263 B
6 lines
263 B
5 years ago
|
class UpdateTidingsDeleteStatus < ActiveRecord::Migration[5.2]
|
||
5 years ago
|
def change
|
||
5 years ago
|
Tiding.where.not(container_type: 'DeleteCourse').where(belong_container_type: "Course", belong_container_id: Course.where(is_delete: 1).pluck(:id)).update_all(is_delete: 1)
|
||
5 years ago
|
end
|
||
|
end
|