LP#1759352: improve webstaff fix checkout specific due date UX
authorCesar Velez <cesar.velez@equinoxinitiative.org>
Fri, 30 Mar 2018 15:32:45 +0000 (11:32 -0400)
committerGalen Charlton <gmc@equinoxinitiative.org>
Fri, 25 May 2018 18:51:00 +0000 (14:51 -0400)
The Date Options dropdown UI added as a result of bug 1717025
hides the state of the "checkboxes" for custom due date and
the datepicker wasn't disabled when custom due date was disabled.
This addresses these UX issues, to that the user has visual feedback
as to the state of that option.

Signed-off-by: Cesar Velez <cesar.velez@equinoxinitiative.org>
Signed-off-by: Rogan Hamby <rogan.hamby@gmail.com>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>

Open-ILS/src/templates/staff/circ/patron/t_checkout.tt2

index f52451d..85df24c 100644 (file)
@@ -41,7 +41,7 @@
 
 <div class="input-group">
 <div class="input-group-btn" uib-dropdown>
-      <button type="button" class="btn btn-default" uib-dropdown-toggle>
+      <button type="button" ng-class="{'btn-success' : date_options.has_sticky_date}" class="btn btn-default" uib-dropdown-toggle>
         [% l('Date Options') %]
         <span class="caret"></span>
       </button>
@@ -77,7 +77,8 @@
       </div> -->
       <!-- FIXME: This needs a time component as well, but type="datetime" 
             is not yet supported by any browsers -->
-      <div><eg-date-input ng-model="checkoutArgs.due_date"></eg-date-input>
+      <div>
+        <eg-date-input ng-model="checkoutArgs.due_date" ng-disabled="!date_options.has_sticky_date"></eg-date-input>
       </div>
 </div>
     </div>