From: dbs Date: Tue, 15 Apr 2008 00:23:18 +0000 (+0000) Subject: i18n for the MARC editor X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=df14974382bd68294c6bf771e3a89cd9a6ea10e1;p=Evergreen.git i18n for the MARC editor Note that marcedit.js doesn't like messagecatalog calls for some reason git-svn-id: svn://svn.open-ils.org/ILS/trunk@9356 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/xul/staff_client/server/cat/marc_new.xul b/Open-ILS/xul/staff_client/server/cat/marc_new.xul index 480d3b4ba1..990d5b0914 100644 --- a/Open-ILS/xul/staff_client/server/cat/marc_new.xul +++ b/Open-ILS/xul/staff_client/server/cat/marc_new.xul @@ -1,6 +1,9 @@ + @@ -11,7 +14,7 @@ + ]> @@ -38,7 +41,9 @@ function my_init() { try { netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect"); - if (typeof JSAN == 'undefined') { throw( "The JSAN library object is missing."); } + if (typeof JSAN == 'undefined') { + throw( document.getElementById('commonStrings').getString('common.jsan.missing') ); + } JSAN.errorLevel = "die"; // none, warn, or die JSAN.addRepository('/xul/server/'); JSAN.use('util.error'); g.error = new util.error(); @@ -82,15 +87,15 @@ var params = { 'record' : { 'marc' : marc }, 'save' : { - 'label' : 'Create Record', + 'label' : $('catStrings').getString('staff.cat.marc_new.create_record.label'), 'func' : function(new_marcxml) { try { var robj = g.network.simple_request( 'MARC_XML_RECORD_IMPORT', - [ ses(), new_marcxml, 'System Local', 1 ] + [ ses(), new_marcxml, $('catStrings').getString('staff.cat.marc_new.system_local.label'), 1 ] ); if (typeof robj.ilsevent != 'undefined') throw(robj); - alert('Record created.'); + alert($('catStrings').getString('staff.cat.marc_new.record_created.label')); /* Replace tab with OPAC-view of record */ @@ -102,13 +107,13 @@ }; xulG.set_tab( xulG.url_prefix(urls.XUL_OPAC_WRAPPER), - {'tab_name':'Retrieving title...'}, + {'tab_name': $('catStrings').getString('staff.cat.marc_new.retrieving.label')}, content_params ); } catch(E) { g.error.standard_unexpected_error_alert( - 'Error creating MARC record.', E + $('catStrings').getString('staff.cat.marc_new.creating_record.error'), E ); } } @@ -125,8 +130,7 @@ } catch(E) { g.error.standard_unexpected_error_alert( - 'Error loading MARC template: ' + template_name, - E + $('catStrings').getFormattedString('staff.cat.marc_new.loading_template.error', [template_name]), E ); } @@ -142,10 +146,14 @@ ]]> + + + + -