Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

API: pre-populate "Depositor" and "Deposit Date" #457

Closed
eaquigley opened this issue Jul 9, 2014 · 11 comments
Closed

API: pre-populate "Depositor" and "Deposit Date" #457

eaquigley opened this issue Jul 9, 2014 · 11 comments
Assignees
Labels

Comments

@eaquigley
Copy link
Contributor


Author Name: Steve Kraffmiller (@sekmiller)
Original Redmine Issue: 3872, https://redmine.hmdc.harvard.edu/issues/3872
Original Date: 2014-04-22
Original Assignee: Eleni Castro


We are pre-populating Deposit Date and Depositor on the DatasetPage. There is an issue with how to handle datasets created via the API. How will we know/handle the possibility that the depositor "Blanks out" the field.

Assigning to Eleni for now to think about use cases.

@eaquigley eaquigley added this to the Dataverse 4.0: In Review milestone Jul 9, 2014
@eaquigley eaquigley modified the milestones: Dataverse 4.0: Beta 4, Dataverse 4.0: In Review Jul 15, 2014
@posixeleni
Copy link
Contributor

@eaquigley @sekmiller @pdurbin We can just take the system generated information for Deposit Date as to the date when the Data was deposited in Dataverse via the API. This is how it worked in 3.6 with the API, would this still be possible in 4.0?

As for Depositor we can create a system generated name for when datasets are deposited using the API: "API Depositor" and allow the option for them to edit this field in UI after the fact if they want to. Or allow folks using the Data Deposit API to modify this value/text in the code to something more specific "OJS API Depositor".

@pdurbin
Copy link
Member

pdurbin commented Oct 27, 2014

How will we know/handle the possibility that the depositor "Blanks out" the field.

@sekmiller it has always been the case that datasets that are edited via SWORD "blank out" fields that can't be expressed in dcterms. I documented this at https://github.com/IQSS/dvn/blob/develop/doc/sphinx/source/dataverse-api-main.rst#replacing-cataloging-information-title-author-etc-for-a-study like this: "Please note that all cataloging information will be replaced, including fields that can not be expressed with 'dcterms' fields."

We can just take the system generated information for Deposit Date as to the date when the Data was deposited in Dataverse via the API. This is how it worked in 3.6 with the API, would this still be possible in 4.0?

@posixeleni I wasn't even aware of this. So you want SWORD to pre-populate "Depositor" and "Deposit Date" at both create and update time? Would you consider it to be a backward-incompatible change if it doesn't?

@posixeleni
Copy link
Contributor

@pdurbin Similar to contact email, it doesnt need to change at update time since this information would be system generated in the UI at the time of dataset creation. For Depositor: Either put in the admin name for the account, or have a static text that says something along the lines of "API Depositor". And for Deposit Date: can we just rely on our system to enter this date information like it does in the UI?

@pdurbin
Copy link
Member

pdurbin commented Oct 27, 2014

Similar to contact email, it doesnt need to change at update time

Actually, datasetContact ("Contact E-mail") does get set by SWORD at update time too. Here's the ticket where this is going through QA: #921 (comment)

The same is true for Subject.

Maybe we need to sit down and figure out exactly what the rules should be.

@posixeleni
Copy link
Contributor

Lets meet on Wednesday to go over exactly what these should be

@pdurbin
Copy link
Member

pdurbin commented Oct 28, 2014

As for Depositor we can create a system generated name for when datasets are deposited using the API: "API Depositor"

According to #965 Depositor name is currently being pre-populated in the "wrong order". It's being saved as "FirstName LastName" but the desired fix in that ticket is to have "LastName, FirstName" with a comma.

@posixeleni I'm assuming you don't want "Depositor, API" with a comma. I guess you're saying that usually the "Depositor" field will have a comma but sometimes it won't.

@posixeleni
Copy link
Contributor

I definitely dont want "Depositor, API". As far as depositor name (similar to author) can also have an organization/institution name be entered which would not follow the lastname, firstname but would just be ONE name. I was only suggesting this if we could not put in the Admin name of the Dataverse.

@pdurbin
Copy link
Member

pdurbin commented Dec 11, 2014

I feel like whatever I do for this ticket I'll have to re-do once the bug in #965 is fixed. That's the ticket that I believe will inevitably lead us to altering how the authenticated users table looks, changing from a single "name" to first name" and "last name".

The good news is that I think I'll be able to use the trick @scolapasta showed me in 47e3fbf for #1114 (comment)

@scolapasta scolapasta modified the milestones: Beta 12 - Dataverse 4.0, In Review - Dataverse 4.0 Feb 6, 2015
@eaquigley
Copy link
Contributor Author

This ticket is contingent on #965 being done. Moving it to Beta 15 for the time being and giving to @scolapasta since @pdurbin mentions in the last comment that Gustavo wanted to think about it.

@pdurbin
Copy link
Member

pdurbin commented Mar 2, 2015

For Depositor: Either put in the admin name for the account, or have a static text that says something along the lines of "API Depositor"

We're going with the former. Datasets are created by users which I think is what @posixeleni meant by "admin name for the account". Basically, we're making SWORD work like the UI where if you're logged in as Sabrina Spruce the "depositor" will be with the last name first like "Spruce, Sabrina".

@scolapasta and @ekraffmiller and @rtreacy please not that the "native" API doesn't populate "depositor" at all if you leave it blank. Should it? Maybe it's fine that it doesn't since you have the ability to populate it with the JSON.

Passing to QA. Please note that "depositor" should be populated when both creating and editing datasets via SWORD but I'm unable to test the latter due to #1554

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

6 participants