[open-ils-commits] r10092 - trunk/Open-ILS/web/js/dojo/openils/widget

svn at svn.open-ils.org svn at svn.open-ils.org
Tue Jul 22 21:44:40 EDT 2008


Author: miker
Date: 2008-07-22 21:44:39 -0400 (Tue, 22 Jul 2008)
New Revision: 10092

Modified:
   trunk/Open-ILS/web/js/dojo/openils/widget/TranslatorPopup.js
Log:
be careful with identity values

Modified: trunk/Open-ILS/web/js/dojo/openils/widget/TranslatorPopup.js
===================================================================
--- trunk/Open-ILS/web/js/dojo/openils/widget/TranslatorPopup.js	2008-07-23 01:44:00 UTC (rev 10091)
+++ trunk/Open-ILS/web/js/dojo/openils/widget/TranslatorPopup.js	2008-07-23 01:44:39 UTC (rev 10092)
@@ -52,7 +52,7 @@
 
 			postCreate : function () {
 
-				dojo.connect(this.tooltipDialog, 'onFocus', this, 'renderTranslatorPopup');
+				dojo.connect(this.tooltipDialog, 'onOpen', this, 'renderTranslatorPopup');
 
 				this.nls = dojo.i18n.getLocalization("openils.widget", "TranslatorPopup");
 
@@ -183,7 +183,7 @@
 					isdeleted : method == 'delete' ? 1 : 0,
 					id : trans_id,
 					fq_field : this._targetObject.classname + '.' + this.field,
-					identity_value : this._targetObject.id(),
+					identity_value : this._targetObject[fieldmapper[this._targetObject.classname].Identifier](),
 					translation : dijit.byId('locale_' + trans_id).getValue(),
 					string : dijit.byId('translation_' + trans_id).getValue()
 				});
@@ -197,7 +197,7 @@
 				var trans_obj = new i18n().fromHash({
 					isnew : 1,
 					fq_field : this._targetObject.classname + '.' + this.field,
-					identity_value : this._targetObject.id(),
+					identity_value : this._targetObject[fieldmapper[this._targetObject.classname].Identifier](),
 					translation : dijit.byId('i18n_new_locale_' + this._targetObject.classname + '.' + this.field + this.unique).getValue(),
 					string : dijit.byId('i18n_new_translation_' + this._targetObject.classname + '.' + this.field + this.unique).getValue()
 				});



More information about the open-ils-commits mailing list