fix some bugs that slipped in with AutoFieldWidget and .hide/.show (Set No Hold and...
authorphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Thu, 25 Mar 2010 14:10:55 +0000 (14:10 +0000)
committerphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Thu, 25 Mar 2010 14:10:55 +0000 (14:10 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@15976 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/web/js/ui/default/acq/picklist/user_request.js

index b995d37..392273b 100644 (file)
@@ -29,11 +29,11 @@ function drawRequest() {
 
     // toggle the View Picklist/Add to Picklist button label
     if (aur_obj.lineitem()) {
-        openils.Util.show( 'add_to_picklist' );
-        openils.Util.hide( 'view_picklist' );
-    } else {
-        openils.Util.show( 'view_picklist' );
         openils.Util.hide( 'add_to_picklist' );
+        openils.Util.show( 'view_picklist' );
+    } else {
+        openils.Util.hide( 'view_picklist' );
+        openils.Util.show( 'add_to_picklist' );
     }
 
     // draw a detail page for a particular request
@@ -134,7 +134,7 @@ function setNoHold() {
         {   async: true,
             params: [openils.User.authtoken, [reqId]],
             oncomplete: function(r) {
-                drawRequest();
+                location.href = location.href; // kludge to reload the interface
             }
         }
     );