[open-ils-commits] r7555 - in
trunk/Open-ILS/xul/staff_client/server: cat patron
svn at svn.open-ils.org
svn at svn.open-ils.org
Mon Jul 16 16:17:29 EDT 2007
Author: phasefx
Date: 2007-07-16 16:12:03 -0400 (Mon, 16 Jul 2007)
New Revision: 7555
Modified:
trunk/Open-ILS/xul/staff_client/server/cat/record_buckets.js
trunk/Open-ILS/xul/staff_client/server/patron/hold_notices.xul
Log:
fancy_prompt and modal_xulG bug where window.open was being used instead of the JSAN wrapper library (util.window) where the modal_xulG way of passing data to/from modal windows is managed
Modified: trunk/Open-ILS/xul/staff_client/server/cat/record_buckets.js
===================================================================
--- trunk/Open-ILS/xul/staff_client/server/cat/record_buckets.js 2007-07-15 14:36:40 UTC (rev 7554)
+++ trunk/Open-ILS/xul/staff_client/server/cat/record_buckets.js 2007-07-16 20:12:03 UTC (rev 7555)
@@ -508,7 +508,8 @@
xml += '</tr></table></form>';
//obj.data.temp_merge_top = top_xml; obj.data.stash('temp_merge_top');
//obj.data.temp_merge_mid = xml; obj.data.stash('temp_merge_mid');
- window.open(
+ JSAN.use('util.window'); var win = new util.window();
+ var fancy_prompt_data = win.open(
urls.XUL_FANCY_PROMPT,
//+ '?xml_in_stash=temp_merge_mid'
//+ '&top_xml_in_stash=temp_merge_top'
@@ -518,15 +519,15 @@
'top_xml' : top_xml, 'xml' : xml, 'title' : 'Record Merging'
}
);
- obj.data.stash_retrieve();
- if (obj.data.fancy_prompt_data == '') { alert('Merge Aborted'); return; }
+ //obj.data.stash_retrieve();
+ if (fancy_prompt_data.fancy_status == 'incomplete') { alert('Merge Aborted'); return; }
var robj = obj.network.simple_request('MERGE_RECORDS',
[
ses(),
- obj.data.fancy_prompt_data.lead,
+ fancy_prompt_data.lead,
util.functional.filter_list( record_ids,
function(o) {
- return o != obj.data.fancy_prompt_data.lead;
+ return o != fancy_prompt_data.lead;
}
)
]
@@ -568,8 +569,8 @@
netscape.security.PrivilegeManager.enablePrivilege('UniversalXPConnect UniversalBrowserWrite');
var top_xml = '<vbox xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" flex="1" >';
- top_xml += '<description>Delete these records? (Select the "lead" record first)</description>';
- top_xml += '<hbox><button id="lead" disabled="true" label="Delete" name="fancy_submit"/><button label="Cancel" accesskey="C" name="fancy_cancel"/></hbox></vbox>';
+ top_xml += '<description>Delete these records?</description>';
+ top_xml += '<hbox><button id="lead" disabled="false" label="Delete" name="fancy_submit"/><button label="Cancel" accesskey="C" name="fancy_cancel"/></hbox></vbox>';
var xml = '<form xmlns="http://www.w3.org/1999/xhtml">';
xml += '<table><tr valign="top">';
@@ -589,7 +590,8 @@
xml += '</tr></table></form>';
//obj.data.temp_merge_top = top_xml; obj.data.stash('temp_merge_top');
//obj.data.temp_merge_mid = xml; obj.data.stash('temp_merge_mid');
- window.open(
+ JSAN.use('util.window'); var win = new util.window();
+ var fancy_prompt_data = win.open(
urls.XUL_FANCY_PROMPT,
//+ '?xml_in_stash=temp_merge_mid'
//+ '&top_xml_in_stash=temp_merge_top'
@@ -599,8 +601,8 @@
'top_xml' : top_xml, 'xml' : xml, 'title' : 'Record Purging'
}
);
- obj.data.stash_retrieve();
- if (obj.data.fancy_prompt_data == '') { alert('Delete Aborted'); return; }
+ //obj.data.stash_retrieve();
+ if (fancy_prompt_data.fancy_status == 'incomplete') { alert('Delete Aborted'); return; }
var s = '';
for (var i = 0; i < record_ids.length; i++) {
var robj = obj.network.simple_request('FM_BRE_DELETE',[ses(),record_ids[i]]);
Modified: trunk/Open-ILS/xul/staff_client/server/patron/hold_notices.xul
===================================================================
--- trunk/Open-ILS/xul/staff_client/server/patron/hold_notices.xul 2007-07-15 14:36:40 UTC (rev 7554)
+++ trunk/Open-ILS/xul/staff_client/server/patron/hold_notices.xul 2007-07-16 20:12:03 UTC (rev 7555)
@@ -195,7 +195,7 @@
//g.data.init({'via':'stash'});
//g.data.temp_notification_xml = xml; g.data.stash('temp_notification_xml');
JSAN.use('util.window'); var win = new util.window();
- var fancy_prompt_data = window.open(
+ var fancy_prompt_data = win.open(
urls.XUL_FANCY_PROMPT,
//+ '?xml_in_stash=temp_notification_xml'
//+ '&focus=' + window.escape('method')
More information about the open-ils-commits
mailing list