sul-dlss / folio-tasks

Migration and data-loading tasks for FOLIO
MIT License
2 stars 1 forks source link

update data import rake tasks #288

Closed shelleydoljack closed 7 months ago

shelleydoljack commented 8 months ago

We need to be able to:

From https://github.com/sul-dlss/FOLIO-Project-Stanford/issues/605

shelleydoljack commented 8 months ago

default profiles should have a metadata block like this:

"metadata"=>
     {"createdDate"=>"2020-11-23T12:00:00.000+00:00",
      "createdByUserId"=>"00000000-0000-0000-0000-000000000000",
      "createdByUsername"=>"System",
      "updatedDate"=>"2020-11-24T12:00:00.000+00:00",
      "updatedByUserId"=>"00000000-0000-0000-0000-000000000000",
      "updatedByUsername"=>"System"}}],
shelleydoljack commented 8 months ago

For the mapping profiles, the System user ID is not 00000000-0000-0000-0000-000000000000 but rather 6a010e5b-5421-5b1c-9b52-568b37038575 which is an Unknown user in our system. So to delete the default mapping profiles from our json when we pull it, we can use the userInfo field, userName = System.

 "userInfo" : {
    "firstName" : "System",
    "lastName" : "System",
    "userName" : "System"
  },