[open-ils-commits] r12314 - trunk/Open-ILS/web/js/dojo/openils/widget (erickson)

svn at svn.open-ils.org svn at svn.open-ils.org
Fri Feb 27 12:05:18 EST 2009


Author: erickson
Date: 2009-02-27 12:05:15 -0500 (Fri, 27 Feb 2009)
New Revision: 12314

Modified:
   trunk/Open-ILS/web/js/dojo/openils/widget/AutoFieldWidget.js
Log:
throw meaningful error when IDL link is invalid

Modified: trunk/Open-ILS/web/js/dojo/openils/widget/AutoFieldWidget.js
===================================================================
--- trunk/Open-ILS/web/js/dojo/openils/widget/AutoFieldWidget.js	2009-02-27 16:29:43 UTC (rev 12313)
+++ trunk/Open-ILS/web/js/dojo/openils/widget/AutoFieldWidget.js	2009-02-27 17:05:15 UTC (rev 12314)
@@ -188,6 +188,9 @@
                 }
             }
 
+            if(!vfield) 
+                throw new Error("'" + linkClass + "' has no '" + self.idlField.key + "' field!");
+
             this.widget.searchAttr = this.widget.labelAttr = vfield.selector || vfield.name;
             this.widget.valueAttr = vfield.name;
 



More information about the open-ils-commits mailing list