diff options
author | Olivier Lamy <olamy@apache.org> | 2012-03-01 11:46:24 +0000 |
---|---|---|
committer | Olivier Lamy <olamy@apache.org> | 2012-03-01 11:46:24 +0000 |
commit | aaa3870d461a4a33970ebf99d3553292c726e696 (patch) | |
tree | 09459c01647e85c4bf45ab634d62c1e2aa0a5164 | |
parent | b96bf22f523201912ecbc03d4fda77498c586c80 (diff) | |
download | archiva-aaa3870d461a4a33970ebf99d3553292c726e696.tar.gz archiva-aaa3870d461a4a33970ebf99d3553292c726e696.zip |
[MRM-1610] Use Jackson as jaxrs provider for cxf for performance reasons
fix proxy connector screen update policies.
git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1295525 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r-- | archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/proxy-connectors.js | 24 |
1 files changed, 16 insertions, 8 deletions
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/proxy-connectors.js b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/proxy-connectors.js index dbd73ec98..6cc6272a7 100644 --- a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/proxy-connectors.js +++ b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/proxy-connectors.js @@ -80,9 +80,11 @@ $(function() { //this.modified.subscribe(function(newValue){$.log("ProxyConnector modified:"+newValue)}); this.updatePolicyEntry=function(key,value){ - for(var i=0;i<policiesEntries.length;i++){ - if (policiesEntries[i].key==key){ - policiesEntries[i].value=value; + $.log("updatePolicyEntry:"+key+":"+value); + for(var i=0;i<self.policiesEntries().length;i++){ + if (self.policiesEntries()[i].key==key){ + self.policiesEntries()[i].value=value; + $.log("really updatedPolicyEntry:"+key+":"+self.policiesEntries()[i].value); self.modified(true); } } @@ -138,8 +140,13 @@ $(function() { } changePolicyOption=function(id){ - var value = $("#main-content #policy-"+id + " option:selected").val(); - self.proxyConnector.updatePolicyEntry(id,value); + var selectedOption=$("#main-content #policy-"+id + " option:selected"); + if (selectedOption.length>0){ + var value = selectedOption.val(); + $.log("changePolicyOption:"+id+":"+value); + self.proxyConnector.updatePolicyEntry(id,value); + + } } @@ -366,9 +373,8 @@ $(function() { proxyConnector:ko.toJS(proxyConnector) } ).html(); - $.log("tmpl:"+tmplHtml); targetContent.append(tmplHtml); - $.log("showSettings#targetContent:"+id+","+targetContent.length+","+targetContent.attr("id")+",html:"+targetContent.html()); + var targetImg = $((targetImgStartId?targetImgStartId:"#proxy-connectors-grid-remoterepo-settings-edit-") +proxyConnector.sourceRepoId()+"-"+proxyConnector.targetRepoId()); targetImg.attr("data-content",targetContent.html()); @@ -618,7 +624,9 @@ $(function() { if (data==null){ return null; } - return new PolicyInformation(mapStringArray(data.options),data.defaultOption,data.id,data.name); + var policyInformation = new PolicyInformation(mapStringArray(data.options),data.defaultOption,data.id,data.name); + $.log("policyInformation.options:"+policyInformation.options()); + return policyInformation; } mapPolicyInformations=function(data){ |