Hello, We've encountered the error reported in Sebastien's point (2) below. It occurs when a reviewer tries to preview a workflow task. If the webui.itemdisplay.default config line includes a "date" field but no value was entered in the submission form, ItemTag.java fails when trying to display the date. The error won't happen if you set the given date field to required in the submission form because the submitter must enter a date to get it out of his/her workspace. I can confirm that dc.date.issued is not required nor set by default. We use dc.date.created.
Here's the workaround that I used (around line 540 of ItemTag.java in the 4.0 code): else if (isDate) { DCDate dd = new DCDate(values[j].value); // Parse the date if (!dd.toString().equals("null")) { out.print(UIUtil.displayDate(dd, false, false, (HttpServletRequest)pageContext.getRequest())); } } Note sure if that's the best solution but it works for us. I hope this helps. Anthony -----Original Message----- From: Sebastien Ival [mailto:sebastien.i...@rmc.ca] Sent: Friday, June 27, 2014 10:47 AM To: Tim Donohue; dspace-tech@lists.sourceforge.net Cc: Trevor Wilson Subject: Re: [Dspace-tech] Publication Date Metadata Hi Tim, The default setup is what we are looking at. Users have submit theses = original work. So the users should not have to set this date. It should be automated as per version 3.2. Once we did the upgrade from 3.2 to 4.1, submitting a new thesis would result in a blank dc.date.issued. I was trying to revert for this portion to the 3.2 behavior. It seems to me that adding the initial questions does not fix this. > Are you trying to set "dc.date.issued" to today's date at all times? Yes, this is the behavior we would like to see. > What is the reason why you'd rather your submitters not be required to > specify the "dc.date.issued" themselves (which is the default setting in > DSpace 4.x)? They are submitting original work. You did not assume wrongly. I am trying (unsuccessfully) to revert to the 3.2 behaviour. Thanks for your help. This is really appreciated. -----Original Message----- From: Tim Donohue [mailto:tdono...@duraspace.org] Sent: June-27-14 10:37 AM To: Sebastien Ival; dspace-tech@lists.sourceforge.net Cc: Trevor Wilson Subject: Re: [Dspace-tech] Publication Date Metadata Hi Sebastien and Trevor, Maybe I've misunderstood things. It might help to take a step back. What is the setup you are trying to achieve in the DSpace submission steps? In other words, what is your use case here? As you mentioned, it's very possible the "Initial Question" step doesn't meet your use case. If so, it might be good to clarify how you want the submission forms to act, e.g. Are you trying to set "dc.date.issued" to today's date at all times? What is the reason why you'd rather your submitters not be required to specify the "dc.date.issued" themselves (which is the default setting in DSpace 4.x)? It's harder for us to debug this issue without a better understanding of what it is you are trying to achieve. It sounds like I had wrongly assumed you just wanted the same setup as in DSpace 3 (which is why I recommended just re-enabling "Initial Questions"). - Tim On 6/27/2014 9:14 AM, Sebastien Ival wrote: > Hi Tim, > > I have two points to make > > 1) I think as mentioned in https://jira.duraspace.org/browse/DS-1655, the > initial question step is a bit unclear and is now handled as part of the > submission process. So having to re-enable it feels like going backward. I > don't think the two should be hooked together. > > 2) To have the question "The item has been published or publicly distributed > before" showing up, I also need to add dc.identifier.citation and > dc.publisher. The field only shows up, if you answer yes to the question and > you can set all of these values otherwise, it still look like the date is not > being set. > > As when I try to take the task I get an internal server error with : > -- Method: POST > -- Parameters were: > -- submit_claim: "Take Task" > -- workflow_id: "186" > -- step: "0" > > org.apache.jasper.JasperException: java.lang.NullPointerException .... > at > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) > at java.lang.Thread.run(Thread.java:744) > Caused by: java.lang.NullPointerException > at org.dspace.content.DCDate.getMonthUTC(DCDate.java:368) > at org.dspace.content.DCDate.displayUTCDate(DCDate.java:520) > at org.dspace.content.DCDate.displayDate(DCDate.java:487) > at org.dspace.app.webui.util.UIUtil.displayDate(UIUtil.java:249) > at org.dspace.app.webui.jsptag.ItemTag.render(ItemTag.java:541) > at org.dspace.app.webui.jsptag.ItemTag.doStartTag(ItemTag.java:289) > at > org.apache.jsp.mydspace.preview_002dtask_jsp._jspService(preview_002dtask_jsp.java:352) > at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70) > at javax.servlet.http.HttpServlet.service(HttpServlet.java:727) > at > org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432) > ... 44 more > > > This makes me think the dc.date.issued is still blank. > > > Any ideas ? > > Sebastien > > Original Message > From: Tim Donohue <tdono...@duraspace.org> > Sent: Thursday, June 26, 2014 10:03 AM > To: Trevor Wilson; dspace-tech@lists.sourceforge.net > Subject: Re: [Dspace-tech] Publication Date Metadata > > > Trevor, > > Sorry for the delay in getting back. I'm still trying to catch up on email > since the Open Repositories conference earlier this month. > > I've cleaned up the documentation a bit: > https://wiki.duraspace.org/display/DSDOC4x/Metadata+Recommendations > > Setting "dc.date.issued" to "today" only really works when you are using > SWORD or external tools to submit data. > > If you are mostly submitting from the web UI, your best bet is to likely > re-enable the "Initial Questions" page (see above docs for the link). > This lets submitters tell you if the item was published or not. If it was not > published before, then the "dc.date.issued" will be auto-set to today's date. > > By default, in DSpace 4.0, the "Initial Questions" page is disabled. > This means that the 'dc.date.issued' field is REQUIRED to be entered > for every submission (i.e. it'll never be empty, and it will never be > automatically set to today's date -- the submitter must manually > choose the appropriate date) > > Hopefully this makes sense, and meets your use cases. If you need to > configure DSpace in some other way, you may need to write a custom Submission > step to do so. But, feel free to ask more questions if this isn't clear. > > - Tim > > ------------------------------------------------------------------------------ Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft _______________________________________________ DSpace-tech mailing list DSpace-tech@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dspace-tech List Etiquette: https://wiki.duraspace.org/display/DSPACE/Mailing+List+Etiquette ------------------------------------------------------------------------------ Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft _______________________________________________ DSpace-tech mailing list DSpace-tech@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dspace-tech List Etiquette: https://wiki.duraspace.org/display/DSPACE/Mailing+List+Etiquette