From: dbs Date: Mon, 7 Mar 2011 15:07:39 +0000 (+0000) Subject: Fix cloning of AutoField widgets: LP #728055 X-Git-Tag: kcls-grey-screen-prod1~2^2~54 X-Git-Url: http://git.equinoxoli.org/?p=evergreen-equinox.git;a=commitdiff_plain;h=608e437f0bf62c03bdbb805982b665fa747c4f41 Fix cloning of AutoField widgets: LP #728055 Cloning Action/Trigger event definitions was not working properly, as all values were being copied from the original object using their display strings rather than the underlying values. Bill Erickson suggested a fix in IRC that works, so full credit to him for this change! git-svn-id: svn://svn.open-ils.org/ILS/trunk@19590 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js b/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js index 3e99b28..ecbdf95 100644 --- a/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js +++ b/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js @@ -469,8 +469,8 @@ if(!dojo._hasResource['openils.widget.AutoGrid']) { if(field.widget.widget.attr('disabled')) return; var w = clonePane.fieldList.filter( function(i) { return (i.name == field.name) })[0]; - w.widget.baseWidgetValue(field.widget.widgetValue); // sync widgets - w.widget.onload = function(){w.widget.baseWidgetValue(field.widget.widgetValue)}; // async widgets + w.widget.baseWidgetValue(field.widget.widget.attr('value')); // sync widgets + w.widget.onload = function(){w.widget.baseWidgetValue(field.widget.widget.attr('value'))}; // async widgets } ); origPane.destroy();