check for errors on the bills request
authorphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 24 Jul 2009 19:20:06 +0000 (19:20 +0000)
committerphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 24 Jul 2009 19:20:06 +0000 (19:20 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@13729 dcc99617-32d9-48b4-a31d-7c20da2025e4

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

index a3d6956..31fbcbd 100644 (file)
@@ -39,7 +39,7 @@ patron.bills.prototype = {
                                        obj.SHOW_ME_THE_BILLS,
                                        [ ses(), obj.patron_id ]
                                );
-                               //alert('obj.bills = ' + js2JSON(obj.bills));
+                if (typeof obj.bills.ilsevent != 'undefined' || typeof obj.bills == 'null') { throw(obj.bills); }
 
                                for (var i = 0; i < obj.bills.length; i++) {
                                        if (instanceOf(obj.bills[i],mobts)) {
@@ -668,6 +668,7 @@ patron.bills.prototype = {
                                                obj.SHOW_ME_THE_BILLS,  
                                                [ ses(), obj.patron_id ]
                                        );
+                    if (typeof obj.bills.ilsevent != 'undefined' || typeof obj.bills == 'null') { throw(obj.bills); }
                                        for (var i = 0; i < obj.bills.length; i++) {
                                                if (instanceOf(obj.bills[i],mobts)) {
                                                        obj.bills[i] = { 'transaction' : obj.bills[i] }