geobtaa / geoblacklight_admin

MIT License
4 stars 2 forks source link

Enable publication state to be changed via CSV imports #23

Open karenmajewicz opened 9 months ago

karenmajewicz commented 9 months ago

Publication State is now importable and exportable. However, I don't think the import is working. Itested importing a set to change records from 'unpublished' to 'published' but the state did not change.

ewlarson commented 9 months ago

Ahhh... Yes, you cannot change state that way, as state is held in the document_transitions table. You can only import the current state.

ewlarson commented 9 months ago

We might be able to fire a callback to ensure state is sync'd after import tho... I'll think it over.

karenmajewicz commented 9 months ago

OK - otherwise, if we cannot change the state this way, we should remove it from the import table.

ewlarson commented 9 months ago

I think the answer here is to just simplify publication state and NOT track document transitions between draft => published => unpublished. State tracking is nice for long running jobs like URI analysis, but it's far less helpful if you want to import publication state.

I think we refactor publication state here to just be a select option on the document table itself.