Browse Source

create rake task to set correct creation method values for existing logs

CLDC-2492-create-rake-task-to-set-creation-method-for-existing-logs
Arthur Campbell 1 year ago
parent
commit
80bbce2fd7
  1. 5
      lib/tasks/creation_method.rake

5
lib/tasks/creation_method.rake

@ -0,0 +1,5 @@
desc "set creation method to bulk upload if a log has a bulk upload id"
task set_creation_method: :environment do
LettingsLog.where.not(bulk_upload_id: nil).update_all(creation_method: "bulk upload")
SalesLog.where.not(bulk_upload_id: nil).update_all(creation_method: "bulk upload")
end
Loading…
Cancel
Save