From 31cbce472b69a0685f4dbc78f5c1c3576fab3cdd Mon Sep 17 00:00:00 2001 From: dbs Date: Fri, 9 Jul 2010 15:00:16 +0000 Subject: [PATCH] Restore whitespace consistency (spaces not tabs) git-svn-id: svn://svn.open-ils.org/ILS/trunk@16898 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- Open-ILS/xul/staff_client/server/cat/marcedit.js | 52 ++++++++++++------------ 1 file changed, 26 insertions(+), 26 deletions(-) diff --git a/Open-ILS/xul/staff_client/server/cat/marcedit.js b/Open-ILS/xul/staff_client/server/cat/marcedit.js index 8dbcb10e5..912d2e63a 100644 --- a/Open-ILS/xul/staff_client/server/cat/marcedit.js +++ b/Open-ILS/xul/staff_client/server/cat/marcedit.js @@ -91,31 +91,31 @@ function wrap_long_fields (node) { function swap_editors () { - dojo.require('MARC.Record'); - - var xe = $('xul-editor'); - var te = $('text-editor'); - - te.hidden = te.hidden ? false : true; - xe.hidden = xe.hidden ? false : true; - - if (te.hidden) { - // get the marcxml from the text box - var xml_string = new MARC.Record({ - marcbreaker : $('text-editor-box').value, - delimiter : '$' - }).toXmlString(); - - // reset the xml record and rerender it - xml_record = new XML( xml_string ); - loadRecord(xml_record); - } else { - var xml_string = xml_record.toXMLString(); - - // push the xml record into the textbox - var rec = new MARC.Record ({ delimiter : '$', marcxml : xml_string }); - $('text-editor-box').value = rec.toBreaker(); - } + dojo.require('MARC.Record'); + + var xe = $('xul-editor'); + var te = $('text-editor'); + + te.hidden = te.hidden ? false : true; + xe.hidden = xe.hidden ? false : true; + + if (te.hidden) { + // get the marcxml from the text box + var xml_string = new MARC.Record({ + marcbreaker : $('text-editor-box').value, + delimiter : '$' + }).toXmlString(); + + // reset the xml record and rerender it + xml_record = new XML( xml_string ); + loadRecord(xml_record); + } else { + var xml_string = xml_record.toXMLString(); + + // push the xml record into the textbox + var rec = new MARC.Record ({ delimiter : '$', marcxml : xml_string }); + $('text-editor-box').value = rec.toBreaker(); + } } function my_init() { @@ -147,7 +147,7 @@ function my_init() { document.getElementById('save-button').setAttribute('label', window.xulG.save.label); document.getElementById('save-button').setAttribute('oncommand', - 'if ($("xul-editor").hidden) swap_editors(); ' + + 'if ($("xul-editor").hidden) swap_editors(); ' + 'mangle_005(); ' + 'var xml_string = xml_escape_unicode( xml_record.toXMLString() ); ' + 'save_attempt( xml_string ); ' + -- 2.11.0