LP 1772993: Ability to blank Age Hold Protection in Vol/Copy Editor.
authorJason Stephenson <jason@sigio.com>
Thu, 24 May 2018 13:34:17 +0000 (09:34 -0400)
committerJason Stephenson <jason@sigio.com>
Thu, 5 Jul 2018 19:13:16 +0000 (15:13 -0400)
Add the <NONE> option to the age-based hold protection field in the
web staff client Vol/Copy Editor.

To test:

1. Add a value for age-based hold protection to a copy.

2. Attempt to remove the value in the copy editor.  Note that the
   dropdown does not allow you to do so.

3. Apply this commit.

4. Repeat step 2.  Now there is a <NONE> option that removes the value
   from the copy.

Signed-off-by: Jason Stephenson <jason@sigio.com>
Signed-off-by: Jeff Davis <jdavis@sitka.bclibraries.ca>

Open-ILS/src/templates/staff/cat/volcopy/t_attr_edit.tt2

index 9d6d2a4..0818af5 100644 (file)
                 <div class="col-md-6" ng-class="{'bg-success': working.age_protect !== undefined}">
                     <select class="form-control"
                         ng-disabled="!defaults.attributes.age_protect" ng-model="working.age_protect"
-                        ng-options="a.id() as a.name() for a in age_protect_list"
-                    ></select>
+                        ng-options="a.id() as a.name() for a in age_protect_list">
+                      <option value="">[% l('&lt;NONE&gt;') %]</option>
+                    </select>
                 </div>
                 <div class="col-md-6" ng-class="{'bg-success': working.mint_condition !== undefined}">
                     <div class="row">