aboutsummaryrefslogtreecommitdiffstats
path: root/archiva-modules/archiva-web/archiva-webapp/src/main/webapp
diff options
context:
space:
mode:
authorMartin Stockhammer <martin_s@apache.org>2017-05-07 17:26:49 +0200
committerMartin Stockhammer <martin_s@apache.org>2017-05-10 21:39:15 +0200
commit1acc6e7b8439b482e611392700f2decaef54b6e6 (patch)
treefc98db8d5433006bb83e4389f1dfc7f6ddf8ebdf /archiva-modules/archiva-web/archiva-webapp/src/main/webapp
parent10b408249ea9d8e2d63054ba95714e3a628ca782 (diff)
downloadarchiva-1acc6e7b8439b482e611392700f2decaef54b6e6.tar.gz
archiva-1acc6e7b8439b482e611392700f2decaef54b6e6.zip
Adding check path to remote repositories
Allow to set a check path for connection checks to the remote repositories. This is useful for repositories that do not allow to browse the base directory. Improved the fix for MRM-1933
Diffstat (limited to 'archiva-modules/archiva-web/archiva-webapp/src/main/webapp')
-rw-r--r--archiva-modules/archiva-web/archiva-webapp/src/main/webapp/js/archiva/admin/repository/maven2/repositories.js7
-rw-r--r--archiva-modules/archiva-web/archiva-webapp/src/main/webapp/js/templates/archiva/repositories.html14
2 files changed, 19 insertions, 2 deletions
diff --git a/archiva-modules/archiva-web/archiva-webapp/src/main/webapp/js/archiva/admin/repository/maven2/repositories.js b/archiva-modules/archiva-web/archiva-webapp/src/main/webapp/js/archiva/admin/repository/maven2/repositories.js
index 3a6cb5ff3..abfb373b3 100644
--- a/archiva-modules/archiva-web/archiva-webapp/src/main/webapp/js/archiva/admin/repository/maven2/repositories.js
+++ b/archiva-modules/archiva-web/archiva-webapp/src/main/webapp/js/archiva/admin/repository/maven2/repositories.js
@@ -692,7 +692,7 @@ function(jquery,i18n,jqueryTmpl,bootstrap,jqueryValidate,ko) {
RemoteRepository=function(id,name,layout,indexDirectory,url,userName,password,timeout,downloadRemoteIndex,remoteIndexUrl,
remoteDownloadNetworkProxyId,cronExpression,remoteDownloadTimeout,downloadRemoteIndexOnStartup,
- description,extraParametersEntries,extraHeadersEntries){
+ description,extraParametersEntries,extraHeadersEntries,checkPath){
var self=this;
@@ -774,6 +774,9 @@ function(jquery,i18n,jqueryTmpl,bootstrap,jqueryValidate,ko) {
self.modified(true);
});
+ this.checkPath=ko.observable(checkPath);
+ this.checkPath.subscribe(function(newValue){self.modified(true)});
+
this.modified=ko.observable(false);
}
@@ -799,7 +802,7 @@ function(jquery,i18n,jqueryTmpl,bootstrap,jqueryValidate,ko) {
return new RemoteRepository(data.id,data.name,data.layout,data.indexDirectory,data.url,data.userName,data.password,
data.timeout,data.downloadRemoteIndex,data.remoteIndexUrl,data.remoteDownloadNetworkProxyId,
data.cronExpression,data.remoteDownloadTimeout,data.downloadRemoteIndexOnStartup,data.description,
- extraParametersEntries,extraHeadersEntries);
+ extraParametersEntries,extraHeadersEntries,data.checkPath);
}
mapRemoteRepositories=function(data){
diff --git a/archiva-modules/archiva-web/archiva-webapp/src/main/webapp/js/templates/archiva/repositories.html b/archiva-modules/archiva-web/archiva-webapp/src/main/webapp/js/templates/archiva/repositories.html
index 3d16cf84f..c23158e95 100644
--- a/archiva-modules/archiva-web/archiva-webapp/src/main/webapp/js/templates/archiva/repositories.html
+++ b/archiva-modules/archiva-web/archiva-webapp/src/main/webapp/js/templates/archiva/repositories.html
@@ -733,6 +733,20 @@
</div>
</div>
+ <div class="control-group">
+ <label class="control-label" for="checkPath">${$.i18n.prop('remoteRepository.checkPath')}</label>
+
+ <div class="controls">
+ <input type="text" class="input-xxlarge" id="checkPath" name="checkPath"
+ data-bind="value: remoteRepository.checkPath"/>
+ <a class="btn btn-warning btn-mini popover-doc" id="remoteRepository-checkPath-info-button"
+ data-original-title="${$.i18n.prop('remoteRepository.checkPath.help.title')}"
+ data-content="${$.i18n.prop('remoteRepository.checkPath.help.content')}">
+ <i class="icon-question-sign icon-white"></i>
+ </a>
+ </div>
+ </div>
+
<div class="row-fluid">
<div class="control-group span6">
<strong>${$.i18n.prop('remoteRepository.extraParametersEntries')}</strong>