items out renew
authorphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 23 Jun 2006 20:12:05 +0000 (20:12 +0000)
committerphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 23 Jun 2006 20:12:05 +0000 (20:12 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@4760 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/xul/staff_client/server/patron/items.js

index dc8f5e4..34b1b17 100644 (file)
@@ -72,6 +72,7 @@ patron.items.prototype = {
                                                                                        7012 /* COPY_STATUS_MISSING */, 
                                                                                        7004 /* COPY_NOT_AVAILABLE */, 
                                                                                        7006 /* COPY_IS_REFERENCE */, 
+                                                                                       7008 /* MAX_RENEWALS_REACHED */, 
                                                                                        7010 /* COPY_ALERT_MESSAGE */,
                                                                                ],
                                                                                'text' : {
@@ -90,7 +91,16 @@ patron.items.prototype = {
                                                                                }
                                                                        }
                                                                );
-                                                               if (typeof renew.ilsevent != 'undefined') { if (renew.ilsevent != 0) throw(robj); }
+                                                               if (typeof renew.ilsevent != 'undefined') { 
+                                                                       switch(renew.ilsevent) {
+                                                                               case 0 /* SUCCESS */ : break;
+                                                                               case 5000 /* PERM_FAILURE */: break;
+                                                                               case 7008 /* MAX_RENEWALS_REACHED */ : break;
+                                                                               default:
+                                                                                       throw(renew);
+                                                                               break;
+                                                                       }
+                                                               }
                                                                obj.retrieve();
                                                        }
                                                        obj.retrieve();