Serials: Issuance "Date Published" Should be Required Field

Bug #1361801 reported by Jennifer Pringle
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Fix Released
Fix Released
Fix Released

Bug Description

2.6 and Master as of August 23rd 2014

Using the Serials Control View it is currently possible to create a serial issuance leaving the Date Published field blank. If this field is blank the system returns the following errors when you attempt to make predictions because it has no date to base the predictions on.

Error Message 1:
Network or server failure. Please check your Internet connection to and choose Retry Network. If you need to enter Offline Mode, choose Ignore Errors in this and subsequent dialogues. If you believe this error is due to a bug in Evergreen and not network problems, please contact your help desk or friendly Evergreen administrators, and give them this information:
{"payload":[],"debug":"osrfMethodException : *** Call to [open-ils.serial.make_predictions] failed for session [1409077231.878238.14090772312025], thread trace [1]:\nInvalid date format: at /usr/share/perl5/ line 416.\n\n","status":500}

Error Message 2:
Successfully predicted undefined item(s) for subscription # 1

Nothing is actually predicted.

My suggestion is make the Date Published field a required field so that the issuance cannot be saved without it.

tags: added: serials
Revision history for this message
Remington Steed (rjs7) wrote :

The quick fix is to add a "requiredFields" parameter to the issuance.tt2 autogrid as follows:

- requiredFields="['date_published','holding_code']"

This prevents the form from being saved until you fill in the required fields (which fixes the error message on predicting new issuances). However, it doesn't provide any indication that those fields are required, even when you try to submit an empty form. It simply does nothing until you fill in all the required fields. So I'm providing a branch with the above addition, but I will also open a bug for the necessary UI changes to make our dojo forms more usable.

Here is my branch:;a=shortlog;h=refs/heads/user/rsteed/serial_issuance_required_fields

Revision history for this message
Remington Steed (rjs7) wrote :

Here is the new bug about improving how we handle required fields:

tags: added: pullrequest
Changed in evergreen:
status: New → Confirmed
importance: Undecided → Medium
milestone: none →
Changed in evergreen:
assignee: nobody → Jennifer Pringle (jpringle-u)
Revision history for this message
Jennifer Pringle (jpringle-u) wrote :

I have tested this code and consent to signing off on it with my email address, jpringle@<email address hidden>, and name, Jennifer Pringle.

(Indication of required field with will make this functionality better in the future.)

Changed in evergreen:
assignee: Jennifer Pringle (jpringle-u) → nobody
Kathy Lussier (klussier)
tags: added: signedoff
Revision history for this message
Ben Shum (bshum) wrote :

Added Jennifer's signoff (with a proper email address) and pushed to master with backports to rel_2_6 and rel_2_5. Thanks Remington and Jennifer!

Changed in evergreen:
milestone: → 2.7.0
status: Confirmed → Fix Committed
Changed in evergreen:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.