The traditional (Rails ERB template) 'Create Plan' workflow that researchers have been using for more than 5 years
The new (ReactJS) 'Upload Plan' workflow which live in the react-client directory
The Dashboard that is displayed shows ALL registered DMPs regardless of the method used to create them. This is because we want the pilot partner admins to be able to curate related works that are discovered for any of their DMPs.
The React pages work with the DMP-ID record that is stored in the DMPHub Dynamo Table. This is fine for DMPs created via the 'DMP Upload' workflow. Changes made to a DMP created via the old Create Plan workflow though will update the DMPHub copy of the DMP ID and not the old plans,contributorsandresearch_outputs` tables.
I added logic in the controllers/api/v3/dmps_controller.rb to backfill changes into these tables but it feels fragile and will not be sustainable. The new system we are building will not have this issue.
To save ourselves time and headaches. We should update the React code so that when the GET /dmps/10.12345/A1B2C3 call includes a "draft_data": { "legacy_dmp": "true", "legacy_path": "plans/12345" } flag, the React page should not allow the user to modify anything besides the Related Works.
A message should be displayed for the user explaining that they must go to the page supplied in the legacy_path to modify the DMP.
DMPs can now be created in 2 different ways:
react-client
directoryThe Dashboard that is displayed shows ALL registered DMPs regardless of the method used to create them. This is because we want the pilot partner admins to be able to curate related works that are discovered for any of their DMPs.
The React pages work with the DMP-ID record that is stored in the DMPHub Dynamo Table. This is fine for DMPs created via the 'DMP Upload' workflow. Changes made to a DMP created via the old
Create Plan
workflow though will update the DMPHub copy of the DMP ID and not the oldplans,
contributorsand
research_outputs` tables.I added logic in the
controllers/api/v3/dmps_controller.rb
to backfill changes into these tables but it feels fragile and will not be sustainable. The new system we are building will not have this issue.To save ourselves time and headaches. We should update the React code so that when the
GET /dmps/10.12345/A1B2C3
call includes a"draft_data": { "legacy_dmp": "true", "legacy_path": "plans/12345" }
flag, the React page should not allow the user to modify anything besides the Related Works.A message should be displayed for the user explaining that they must go to the page supplied in the
legacy_path
to modify the DMP.