From: <dco...@us...> - 2009-05-28 10:18:35
|
Revision: 4122 http://geonetwork.svn.sourceforge.net/geonetwork/?rev=4122&view=rev Author: dcorpataux Date: 2009-05-28 10:18:25 +0000 (Thu, 28 May 2009) Log Message: ----------- #14607 Modified Paths: -------------- sandbox/geocat.ch/trunk/web/geonetwork/scripts/ed.js Modified: sandbox/geocat.ch/trunk/web/geonetwork/scripts/ed.js =================================================================== --- sandbox/geocat.ch/trunk/web/geonetwork/scripts/ed.js 2009-05-28 09:45:44 UTC (rev 4121) +++ sandbox/geocat.ch/trunk/web/geonetwork/scripts/ed.js 2009-05-28 10:18:25 UTC (rev 4122) @@ -32,10 +32,10 @@ * list on search action. */ function popXLink (action, ref, name, id){ - /** - * Display popup according to ref element. - * Contact could be gmd:pointOfContact, gmd:contact, ... - */ + /** + * Display popup according to ref element. + * Contact could be gmd:pointOfContact, gmd:contact, ... + */ if (name.toUpperCase().indexOf("CONTACT") != -1 || name.toUpperCase().indexOf("PARTY") != -1) { mode = "CONTACT"; @@ -151,7 +151,7 @@ // remove the "xlink-s" text input Ext.get("popXLink").first("#xlink-s").remove(); - + // insert divs for the text field and button Ext.DomHelper.insertFirst("popXLink", { tag: "div", id: "pop-kw", children: [ @@ -184,12 +184,12 @@ }, success: function(response) { var el = Ext.get("keywordList").select(".href"); - + if (el) { el.remove(); } var txt = response.responseText; - + if (txt && txt.length > 0) { Ext.DomHelper.append("keywordList", response.responseText); } @@ -326,7 +326,7 @@ $('createService').style.display = 'none'; $('scopedDesc').style.display = 'none'; $('createDataset').style.display = 'none'; - + if (type=="service") { $('mdsButton').style.display = 'block'; $('mddInfo').style.display = 'block'; @@ -339,7 +339,7 @@ $('mddButton').style.display = 'block'; $('scopedDesc').style.display = 'block'; } - + displayModalBox('popSearcher', boxTitle); initSearcher (type); @@ -354,23 +354,25 @@ // Clean href element on each popup init in order // to avoid mix of elements. document.mainForm.href.value = ""; - + // store the variables of the request for use by the Create button dialogRequest.action = action; dialogRequest.ref = ref; dialogRequest.name = name; dialogRequest.id = id; - + // Hide optional fields var optionalFields = ['contact.role', 'extent.resolution', 'extent.map']; $('popXLink').descendants().each(function(el) { if (optionalFields.indexOf(el.id) != -1) el.style.display = "none"; }); - + // Clean keywords result list + $('keywordList').innerHTML = ''; + displayModalBox('popXLink', translateStrings('searchElements')); - + popXLink (action, ref, name, id); - + document.mainForm.ref.value = ref; document.mainForm.name.value = name; //return false; @@ -380,7 +382,7 @@ var validationReportBox; function displayModalBox(contentDivId, boxTitle) { - + var el; el = Ext.get("popXLink").first("#xlink-s"); if (!el) { @@ -396,7 +398,7 @@ if (el) { el.remove(); } - + $(contentDivId).style.display = 'block'; if (!modalBox) { modalBox = new Ext.Window({ @@ -418,7 +420,7 @@ contentEl: contentDivId }); } - + if (modalBox) { modalBox.show(); modalBox.setHeight(400); @@ -677,10 +679,10 @@ // update values in edit form. var input = document.getElementById('datasetIds'); input.value = ids; - + var srvScopedName = document.getElementById('srvScopedName'); srvScopedName.value = scopedName; - + doAction(Env.locService+'/metadata.services.attachDataset'); } @@ -709,9 +711,9 @@ var updateMDD = document.getElementById('upMdd'); updateMDD.value = updateMddCheckbox; - + var srvScopedName = document.getElementById('srvScopedName'); srvScopedName.value = scopedName; - + doAction(Env.locService+'/metadata.update.onlineSrc'); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |