]> source.dussan.org Git - archiva.git/commitdiff
move all templates to a dedicated directory
authorOlivier Lamy <olamy@apache.org>
Mon, 26 Mar 2012 22:51:55 +0000 (22:51 +0000)
committerOlivier Lamy <olamy@apache.org>
Mon, 26 Mar 2012 22:51:55 +0000 (22:51 +0000)
git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1305653 13f79535-47bb-0310-9956-ffa450edef68

36 files changed:
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/main-tmpl.js
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/general-admin.html [deleted file]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/grids-generics.html [deleted file]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/menu.html [deleted file]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/message.html [deleted file]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/modal.html [deleted file]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/network-proxies.html [deleted file]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/proxy-connectors.html [deleted file]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/repositories.html [deleted file]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/repository-groups.html [deleted file]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/search.html [deleted file]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/redback-tmpl.js
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/login.html [deleted file]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/password-change-form.html [deleted file]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/register-form.html [deleted file]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/roles-tmpl.html [deleted file]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/user-edit-form.html [deleted file]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/user-edit.html [deleted file]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/user-grids.html [deleted file]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/general-admin.html [new file with mode: 0644]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/grids-generics.html [new file with mode: 0644]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/menu.html [new file with mode: 0644]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/message.html [new file with mode: 0644]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/modal.html [new file with mode: 0644]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/network-proxies.html [new file with mode: 0644]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/proxy-connectors.html [new file with mode: 0644]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/repositories.html [new file with mode: 0644]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/repository-groups.html [new file with mode: 0644]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/search.html [new file with mode: 0644]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/login.html [new file with mode: 0644]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/password-change-form.html [new file with mode: 0644]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/register-form.html [new file with mode: 0644]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/roles-tmpl.html [new file with mode: 0644]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/user-edit-form.html [new file with mode: 0644]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/user-edit.html [new file with mode: 0644]
archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/user-grids.html [new file with mode: 0644]

index 6dafd15c8db32c30e514182f8c1186f74717b3ae..121eacaac088d146384eae19de57ce39d52b8f7b 100644 (file)
  * specific language governing permissions and limitations
  * under the License.
  */
-define("main-templates",["text!archiva/templates/menu.html",
-          "text!archiva/templates/message.html",
-          "text!archiva/templates/modal.html",
-          "text!archiva/templates/grids-generics.html",
-          "text!archiva/templates/repositories.html",
-          "text!archiva/templates/network-proxies.html",
-          "text!archiva/templates/proxy-connectors.html",
-          "text!archiva/templates/repository-groups.html",
-          "text!archiva/templates/search.html",
-          "text!archiva/templates/general-admin.html",
+define("main-templates",["text!templates/archiva/menu.html",
+          "text!templates/archiva/message.html",
+          "text!templates/archiva/modal.html",
+          "text!templates/archiva/grids-generics.html",
+          "text!templates/archiva/repositories.html",
+          "text!templates/archiva/network-proxies.html",
+          "text!templates/archiva/proxy-connectors.html",
+          "text!templates/archiva/repository-groups.html",
+          "text!templates/archiva/search.html",
+          "text!templates/archiva/general-admin.html",
           "jquery_tmpl","utils"],
   function(menu,message,modal,grids_generics,repositories,network_proxies,proxies_connectors,
            repository_groups,search,general_admin) {
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/general-admin.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/general-admin.html
deleted file mode 100644 (file)
index ff5ea23..0000000
+++ /dev/null
@@ -1,509 +0,0 @@
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one
-  ~ or more contributor license agreements.  See the NOTICE file
-  ~ distributed with this work for additional information
-  ~ regarding copyright ownership.  The ASF licenses this file
-  ~ to you under the Apache License, Version 2.0 (the
-  ~ "License"); you may not use this file except in compliance
-  ~ with the License.  You may obtain a copy of the License at
-  ~
-  ~   http://www.apache.org/licenses/LICENSE-2.0
-  ~
-  ~ Unless required by applicable law or agreed to in writing,
-  ~ software distributed under the License is distributed on an
-  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-  ~ KIND, either express or implied.  See the License for the
-  ~ specific language governing permissions and limitations
-  ~ under the License.
--->
-<script id="legacy-artifact-path-main" type="text/html">
- <div id="legacy-artifact-path-screen">
-     <div class="page-header">
-       <h2>${$.i18n.prop('legacy-artifact-paths.list')}</h2>
-     </div>
-
-     <ul id="legacy-artifact-paths-view-tabs" class="nav nav-tabs">
-       <li id="legacy-artifact-paths-view-tabs-li-grid">
-         <a data-toggle="tab" href="#legacy-artifact-paths-view" id="legacy-artifact-paths-view-tabs-a-grid">${$.i18n.prop('legacy-artifact-paths.grid.tab.title')}</a>
-       </li>
-       <li id="legacy-artifact-paths-view-tabs-li-edit">
-         <a data-toggle="tab" href="#legacy-artifact-paths-edit">${$.i18n.prop('add')}</a>
-       </li>
-     </ul>
-     <div id="legacy-artifact-paths-view-tabs-content" class="tab-content">
-       <div id="legacy-artifact-paths-view" class="tab-pane">
-           <table class="table table-striped table-bordered" id="legacy-artifact-paths-table"
-                  data-bind="simpleGrid: gridViewModel,simpleGridTemplate:'ko-legacy-artifact-paths-grid',pageLinksId:'legacy-artifact-pathsPagination'">
-           </table>
-           <div id="legacy-artifact-pathsPagination"></div>
-       </div>
-       <div id="legacy-artifact-paths-edit" class="tab-pane" data-bind='template: {name:"legacy-artifact-paths-edit-tmpl"}'></div>
-     </div>
- </div>
-</script>
-
-<script id='ko-legacy-artifact-paths-grid' type='text/html'>
-    <thead>
-    <tr>
-        {{each(i, columnDefinition) columns}}
-        <th>${ columnDefinition.headerText }</th>
-        {{/each}}
-        <th>${$.i18n.prop('delete')}</th>
-    </tr>
-    </thead>
-    <tbody>
-    {{each(i, row) itemsOnCurrentPage()}}
-      <tr data-bind="css:{ 'modified': row.modified()}">
-        {{each(j, columnDefinition) columns}}
-        {{var val = (typeof columnDefinition.rowText == 'function' ? columnDefinition.rowText(row) : row[columnDefinition.rowText])}}
-          <td>
-              ${val}
-          </td>
-        {{/each}}
-          <td>
-            <a href="#" data-bind="click: function(){ removeLegacyArtifactPath(row) }">
-              <img src="images/edit-cut.png" title="${$.i18n.prop('delete')}"/>
-            </a>
-          </td>
-    </tr>
-    {{/each}}
-    </tbody>
-
-</script>
-
-<script id="legacy-artifact-paths-edit-tmpl" type="text/html">
-    <form id="legacy-artifact-paths-edit-form" class="well form-horizontal">
-      <fieldset id="legacy-artifact-paths-edit-fieldset">
-        <div class="control-group">
-          <label class="control-label" for="groupId">${$.i18n.prop('legacy-artifact-paths.groupId')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge required" id="groupId" name="groupId" size="8"
-                   data-bind="value: legacyArtifactPath.groupId"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="artifactId">${$.i18n.prop('legacy-artifact-paths.artifactId')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge required" id="artifactId" name="artifactId" size="8"
-                   data-bind="value: legacyArtifactPath.artifactId"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="version">${$.i18n.prop('legacy-artifact-paths.version')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge required" id="version" name="version" size="8"
-                   data-bind="value: legacyArtifactPath.version"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="classifier">${$.i18n.prop('legacy-artifact-paths.classifier')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge" id="classifier" name="classifier" size="8"
-                   data-bind="value: legacyArtifactPath.classifier"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="type">${$.i18n.prop('legacy-artifact-paths.type')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge required" id="type" name="type" size="8"
-                   data-bind="value: legacyArtifactPath.type"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="path">${$.i18n.prop('legacy-artifact-paths.path')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge required" id="path" name="path" size="8"
-                   data-bind="value: legacyArtifactPath.path"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="artifact">${$.i18n.prop('legacy-artifact-paths.artifact')}</label>
-          <div class="controls">
-            <span title="calculated from values" class="uneditable-input"
-                  id="artifact" data-bind="text: legacyArtifactPath.artifact"></span>
-          </div>
-        </div>
-
-      </fieldset>
-      <button id="network-proxy-btn-save" data-bind="click: save" class="btn">${$.i18n.prop('save')}</button>
-      <button id="network-proxy-btn-cancel" data-bind="click: displayGrid" class="btn">${$.i18n.prop('cancel')}</button>
-      <button id="network-proxy-btn-calculate-path" data-bind="click: calculatePath" class="btn btn-success">${$.i18n.prop('legacy-artifact-paths.calculatePath')}</button>
-    </form>
-</script>
-
-<script id="legacy-artifact-path-delete-warning-tmpl" type="text/html">
-    <div>
-      <span class="label label-warning">${$.i18n.prop('warning.not.undone.operation')}</span>
-    </div>
-</script>
-
-<script id="repository-scanning-main" type="text/html">
-  <div id="repository-scanning-screen">
-    <div class="page-header">
-      <h2>${$.i18n.prop('repository-scanning.head')}</h2>
-    </div>
-  </div>
-
-  <ul id="repositories-tabs" class="nav nav-tabs">
-    <li class="active">
-      <a data-toggle="tab" href="#file-types-content">${$.i18n.prop('repository-scanning.file-types.head')}</a>
-    </li>
-    <li>
-      <a data-toggle="tab" href="#consumers-content">${$.i18n.prop('repository-scanning.consumers.head')}</a>
-    </li>
-  </ul>
-
-  <div class="tab-content">
-    <div id="file-types-content" class="tab-pane active" data-bind='template: {name:"file-types-tmpl"}'>
-    </div>
-    <div id="consumers-content" class="tab-pane">
-      <div id="consumers-known-content" data-bind='template: {name:"consumers-known-content-tmpl"}'></div>
-      <div id="consumers-invalid-content" data-bind='template: {name:"consumers-invalid-content-tmpl"}'></div>
-    </div>
-  </div>
-
-</script>
-
-<script id="file-types-tmpl" type="text/html">
-<div class="accordion" id="accordion-file-types">
-  <div class="span4">
-  {{each(i, fileType) fileTypes}}
-  <div class="accordion-group">
-    <div class="accordion-heading">
-      <a class="accordion-toggle" href="#collapse-pattern-${fileType.id}"
-         data-parent="#accordion-file-types" data-toggle="collapse">${fileType.id}&nbsp;<i class="icon-resize-vertical"/></a>
-    </div>
-    <div id="collapse-pattern-${fileType.id}" class="accordion-body collapse">
-    <table class="table table-condensed">
-      {{each(j,pattern) fileType.patterns}}
-      <tr>
-        <td>${pattern}</td>
-        <td>
-          <a href="#" data-bind="click: function(){ removeFileTypePattern(fileType.id(),pattern) }">
-            <img src="images/edit-cut-22-22.png" title="${$.i18n.prop('delete')}"/>
-          </a>
-        </td>
-      </tr>
-      {{/each}}
-      <tr>
-        <td><input type="text" id="pattern-${fileType.id}"/></td>
-        <td>
-          <a href="#" data-bind="click: function(){addFileTypePattern(fileType.id())}">
-            <img src="images/list-add-22-22.png" title="${$.i18n.prop('add')}"/>
-          </a>
-        </td>
-      </tr>
-    </table>
-    </div>
-  </div>
-  {{/each}}
-  </div>
-</div>
-</script>
-
-<script id="consumers-known-content-tmpl" type="text/html">
-  <div class="page-header">
-    <h4>${$.i18n.prop('repository-scanning.consumers.know-content.head')}</h4>
-  </div>
-  <table class="table table-condensed">
-    <thead>
-      <tr>
-        <th>${$.i18n.prop('repository-scanning.consumers.grid.enabled')}</th>
-        <th>${$.i18n.prop('repository-scanning.consumers.grid.id')}</th>
-        <th>${$.i18n.prop('repository-scanning.consumers.grid.description')}</th>
-      </tr>
-    </thead>
-    <tbody>
-      {{each(i,knownAdminRepositoryConsumer) knownAdminRepositoryConsumers}}
-      <tr>
-        {{if knownAdminRepositoryConsumer.enabled()==true}}
-          <td>
-            <a href="#" data-bind="click: function(){ disableKnowContentConsumer(knownAdminRepositoryConsumer) }">
-              <img src="images/weather-clear-22-22.png"/>
-            </a>
-          </td>
-          {{else}}
-          <td>
-            <a href="#" data-bind="click: function(){ enableKnowContentConsumer(knownAdminRepositoryConsumer) }">
-              <img src="images/dialog-error-22-22.png"/>
-            </a>
-          </td>
-        {{/if}}
-
-        <td>${knownAdminRepositoryConsumer.id}</td>
-        <td>${knownAdminRepositoryConsumer.description}</td>
-      </tr>
-      {{/each}}
-    </tbody>
-  </table>
-</script>
-
-<script id="consumers-invalid-content-tmpl" type="text/html">
-  <div class="page-header">
-    <h4>${$.i18n.prop('repository-scanning.consumers.invalid-content.head')}</h4>
-  </div>
-  <table class="table table-condensed">
-    <thead>
-      <tr>
-        <th>${$.i18n.prop('repository-scanning.consumers.grid.enabled')}</th>
-        <th>${$.i18n.prop('repository-scanning.consumers.grid.id')}</th>
-        <th>${$.i18n.prop('repository-scanning.consumers.grid.description')}</th>
-      </tr>
-    </thead>
-    <tbody>
-      {{each(i,invalidAdminRepositoryConsumer) invalidAdminRepositoryConsumers}}
-      <tr>
-        {{if invalidAdminRepositoryConsumer.enabled()==true}}
-          <td>
-            <a href="#" data-bind="click: function(){ disableInvalidContentConsumer(invalidAdminRepositoryConsumer) }">
-              <img src="images/weather-clear-22-22.png"/>
-            </a>
-          </td>
-          {{else}}
-          <td>
-            <a href="#" data-bind="click: function(){ enableInvalidContentConsumer(invalidAdminRepositoryConsumer) }">
-              <img src="images/dialog-error-22-22.png"/>
-            </a>
-          </td>
-        {{/if}}
-        <td>${invalidAdminRepositoryConsumer.id}</td>
-        <td>${invalidAdminRepositoryConsumer.description}</td>
-      </tr>
-      {{/each}}
-    </tbody>
-  </table>
-</script>
-
-<script id="network-configuration-screen" type="text/html">
-  <div class="page-header">
-    <h3>${$.i18n.prop('network-configuration.header')}</h3>
-  </div>
-  <div id="network-configuration-form" data-bind='template: {name:"network-configuration-form-tmpl"}'></div>
-</script>
-
-<script id="network-configuration-form-tmpl" type="text/html">
-    <form id="network-proxy-edit-form" class="well form-horizontal">
-      <fieldset id="network-proxy-edit-fieldset">
-        <div class="control-group">
-          <label class="control-label" for="maxTotal">${$.i18n.prop('network-configuration.maxTotal')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge required digits" id="maxTotal" name="maxTotal" size="8"
-                   data-bind="value: networkConfiguration().maxTotal"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="maxTotal">${$.i18n.prop('network-configuration.maxTotalPerHost')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge required digits" id="maxTotalPerHost" name="maxTotalPerHost" size="8"
-                   data-bind="value: networkConfiguration().maxTotalPerHost"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="usePooling">${$.i18n.prop('network-configuration.usePooling')}</label>
-          <div class="controls">
-            <input type="checkbox" id="usePooling" name="usePooling" data-bind="checked: networkConfiguration().usePooling"/>
-          </div>
-        </div>
-      </fieldset>
-      <button id="network-configuration-btn-save" data-bind="click: save" class="btn">${$.i18n.prop('save')}</button>
-    </form>
-</script>
-
-<script id="system-status-main" type="text/html">
-
-  <div class="page-header">
-    <h3>${$.i18n.prop('system-status.header.main')}&nbsp;<a href="#" onclick="refreshSystemStatus()"><img src="images/view-refresh-22-22.png"/></a></h3>
-  </div>
-  <div class="page-header">
-    <h4>${$.i18n.prop('system-status.header.queues')}</h4>
-  </div>
-  <div id="status_queues">
-    <img src="images/small-spinner.gif"/>
-  </div>
-
-  <div class="page-header">
-    <h4>${$.i18n.prop('system-status.header.scanning')}&nbsp;<a href="#" onclick="displayScanningStats()"><img src="images/view-refresh.png"/></a></h4>
-  </div>
-  <div id="status_scanning">
-    <img src="images/small-spinner.gif"/>
-  </div>
-
-  <div class="page-header">
-    <h4>${$.i18n.prop('system-status.header.caches')}&nbsp;<a href="#" onclick="displayCacheEntries()"><img src="images/view-refresh.png"/></a></h4>
-  </div>
-  <div id="status_caches">
-      <img src="images/small-spinner.gif"/>
-  </div>
-
-  <div class="page-header">
-    <h4>${$.i18n.prop('system-status.header.memory')}&nbsp;<a href="#" onclick="displayMemoryUsage()"><img src="images/view-refresh.png"/></a></h4>
-  </div>
-  <div id="status_memory_info">
-    <img src="images/small-spinner.gif"/>
-  </div>
-
-  <div class="page-header">
-    <h4>${$.i18n.prop('system-status.header.current.time')}</h4>
-  </div>
-  <div id="status_current_time">
-    <img src="images/small-spinner.gif"/>
-  </div>
-
-  <div class="page-header">
-    <h4>${$.i18n.prop('system-status.header.version.info')}</h4>
-  </div>
-  <div id="status_version_info">
-    <img src="images/small-spinner.gif"/>
-  </div>
-
-</script>
-
-<script id="status_caches_tmpl" type="text/html">
-  <a href="#" class="btn btn-warning" onclick="flushAllCaches()">
-    ${$.i18n.prop('system-status.caches.flushAll')}
-  </a>
-  <table class="table table-condensed">
-    <thead>
-      <tr>
-        <th>${$.i18n.prop('system-status.caches.grid.header.key')}</th>
-        <th>${$.i18n.prop('system-status.caches.grid.header.size')}</th>
-        <th>${$.i18n.prop('system-status.caches.grid.header.cacheHits')}</th>
-        <th>${$.i18n.prop('system-status.caches.grid.header.cacheMiss')}</th>
-        <th>${$.i18n.prop('system-status.caches.grid.header.cacheHitRate')}</th>
-        <th>${$.i18n.prop('system-status.caches.grid.header.flush')}</th>
-      </tr>
-    </thead>
-    <tbody>
-    {{each(i,cacheEntry) cacheEntries}}
-      <tr>
-        <td>${cacheEntry.key}</td>
-        <td>${cacheEntry.size}</td>
-        <td>${cacheEntry.cacheHits}</td>
-        <td>${cacheEntry.cacheMiss}</td>
-        <td>${cacheEntry.cacheHitRate}</td>
-        <td>
-          <a href="#" onclick="flushCache('${cacheEntry.key}')">
-            {{if  cacheEntry.size > 0 }}
-              <img src="images/user-trash-full.png"/>
-            {{else}}
-              <img src="images/user-trash.png"/>
-            {{/if}}
-          </a>
-        </td>
-      </tr>
-    {{/each}}
-    </tbody>
-  </table>
-</script>
-
-
-<script id="status_queues_tmpl" type="text/html">
-  <table class="table table-condensed">
-    <thead>
-      <tr>
-        <th>${$.i18n.prop('system-status.queues.grid.header.key')}</th>
-        <th>${$.i18n.prop('system-status.queues.grid.header.size')}</th>
-      </tr>
-    </thead>
-    <tbody>
-    {{each(i,queueEntry) queueEntries}}
-      <tr>
-        <td>${queueEntry.key}</td>
-        <td>${queueEntry.entriesNumber}</td>
-      </tr>
-    {{/each}}
-    </tbody>
-  </table>
-</script>
-
-<script id="status_scanning_tmpl" type="text/html">
-  {{if repositoryScannerStatisticsList.length == 0}}
-    <h5>No scans in progress.</h5>
-  {{else}}
-    <table class="table table-condensed">
-      <thead>
-        <tr>
-          <th>${$.i18n.prop('system-status.scanning.grid.header.repository')}</th>
-          <th>${$.i18n.prop('system-status.scanning.grid.header.files.processed')}</th>
-          <th>${$.i18n.prop('system-status.scanning.grid.header.files.new')}</th>
-          <th>${$.i18n.prop('system-status.scanning.grid.header.stats')}</th>
-        </tr>
-      </thead>
-      <tbody>
-      {{each(i,repositoryScannerStatistics) repositoryScannerStatisticsList}}
-        <tr>
-          <td>${repositoryScannerStatistics.managedRepository.name()}</td>
-          <td>${repositoryScannerStatistics.totalFileCount}</td>
-          <td>${repositoryScannerStatistics.newFileCount}</td>
-          <td>
-            <blockquote>
-            <table>
-              <thead>
-                <tr>
-                  <th>${$.i18n.prop('system-status.scanning.consumers.grid.header.name')}</th>
-                  <th>${$.i18n.prop('system-status.scanning.consumers.grid.header.total')}</th>
-                  <th>${$.i18n.prop('system-status.scanning.consumers.grid.header.average')} ms</th>
-                  <th>${$.i18n.prop('system-status.scanning.consumers.grid.header.invocations.time')}</th>
-                </tr>
-              </thead>
-              <tbody>
-                {{each(j,consumerScanningStatistics) repositoryScannerStatistics.consumerScanningStatisticsList}}
-                <tr>
-                  <td>${consumerScanningStatistics.consumerKey}</td>
-                  <td>${consumerScanningStatistics.count}</td>
-                  <td>${consumerScanningStatistics.average}ms</td>
-                  <td>${consumerScanningStatistics.time}ms</td>
-                </tr>
-                {{/each}}
-              </tbody>
-            </table>
-            </blockquote>
-          </td>
-        </tr>
-      {{/each}}
-      </tbody>
-    </table>
-  {{/if}}
-</script>
-
-<script id="changeAppearance" type="text/html">
-    <div class="page-header">
-        <h2>${$.i18n.prop('appearance-configuration.title-page')}</h2>
-    </div>
-
-    <h2>${$.i18n.prop('appearance-configuration.organisation-details')}</h2>
-
-    <p>
-        ${$.i18n.prop('apperance-configuration.details-description')}
-    </p>
-    
-    <form id="appearance-configuration-form-id" class="well form-horizontal">
-        <fieldset id="appearance-configuration-fielset-id">
-            <div class="control-group">
-                <label class="control-label" for="name">${$.i18n.prop('appearance-configuration.name-label')}</label>
-                <div class="controls">
-                    <input type="text" class="xlarge required" id="name" name="name" size="50"
-                           data-bind="value: organisationInformation().name"/>
-                </div>
-            </div>
-            <div class="control-group">
-                <label class="control-label" for="name">${$.i18n.prop('appearance-configuration.url-label')}</label>
-                <div class="controls">
-                    <input type="text" class="xlarge required" id="url" name="url" size="50"
-                           data-bind="value: organisationInformation().url"/>
-                </div>
-            </div>
-            <div class="control-group">
-                <label class="control-label"
-                       for="name">${$.i18n.prop('appearance-configuration.logoLocation-label')}</label>
-                <div class="controls">
-                    <input type="text" class="xlarge" id="logoLocation" name="logoLocation" size="50"
-                           data-bind="value: organisationInformation().logoLocation"/>
-                </div>
-            </div>
-        </fieldset>
-        <button id="appearance-configuration-btn-save" data-bind="click: save" class="btn">${$.i18n.prop('save')}</button>
-    </form>
-</script>
-
-
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/grids-generics.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/grids-generics.html
deleted file mode 100644 (file)
index 0f94a83..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one
-  ~ or more contributor license agreements.  See the NOTICE file
-  ~ distributed with this work for additional information
-  ~ regarding copyright ownership.  The ASF licenses this file
-  ~ to you under the Apache License, Version 2.0 (the
-  ~ "License"); you may not use this file except in compliance
-  ~ with the License.  You may obtain a copy of the License at
-  ~
-  ~   http://www.apache.org/licenses/LICENSE-2.0
-  ~
-  ~ Unless required by applicable law or agreed to in writing,
-  ~ software distributed under the License is distributed on an
-  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-  ~ KIND, either express or implied.  See the License for the
-  ~ specific language governing permissions and limitations
-  ~ under the License.
--->
-<script id="ko_simpleGrid_pageLinks" type="text/html">
-  <div class="pagination">
-      <ul>
-      {{each(i) ko.utils.range(1, maxPageIndex)}}
-          <li data-bind="css: { active: i == currentPageIndex() }">
-            <a href="#" data-bind="click: function() { currentPageIndex(i) }">
-              ${ i + 1 }
-            </a>
-          </li>
-      {{/each}}
-      </ul>
-  </div>
-</script>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/menu.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/menu.html
deleted file mode 100644 (file)
index 2d0b5f3..0000000
+++ /dev/null
@@ -1,122 +0,0 @@
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one
-  ~ or more contributor license agreements.  See the NOTICE file
-  ~ distributed with this work for additional information
-  ~ regarding copyright ownership.  The ASF licenses this file
-  ~ to you under the Apache License, Version 2.0 (the
-  ~ "License"); you may not use this file except in compliance
-  ~ with the License.  You may obtain a copy of the License at
-  ~
-  ~   http://www.apache.org/licenses/LICENSE-2.0
-  ~
-  ~ Unless required by applicable law or agreed to in writing,
-  ~ software distributed under the License is distributed on an
-  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-  ~ KIND, either express or implied.  See the License for the
-  ~ specific language governing permissions and limitations
-  ~ under the License.
--->
-<script type="text/html" id="main_menu_tmpl">
-  <div id="main-menu">
-
-    <ul class="nav nav-list">
-      <li class="nav-header">${$.i18n.prop('menu.artifacts')}</li>
-      <li>
-        <a href="#" id="menu-find-search-a" onclick="displaySearch(this)">${$.i18n.prop('menu.artifacts.search')}</a>
-      </li>
-      <li>
-        <a href="#" id="menu-find-browse-a" onclick="displayBrowse(true)">${$.i18n.prop('menu.artifacts.browse')}</a>
-      </li>
-    </ul>
-
-    <ul class="nav nav-list" redback-permissions="{permissions: ['archiva-manage-configuration']}">
-      <li class="nav-header">${$.i18n.prop('menu.administration')}</li>
-      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-configuration']}">
-        <a href="#" id="menu-repository-groups-list-a" onclick="displayRepositoryGroups()">${$.i18n.prop('menu.repository.groups')}</a>
-      </li>
-      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-configuration']}">
-        <a href="#" id="menu-repositories-list-a" onclick="displayRepositoriesGrid()">${$.i18n.prop('menu.repositories')}</a>
-      </li>
-      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-configuration']}">
-        <a href="#" id="menu-proxy-connectors-list-a" onclick="displayProxyConnectors()">${$.i18n.prop('menu.proxy-connectors')}</a>
-      </li>
-      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-configuration']}">
-        <a href="#" id="menu-network-proxies-list-a" onclick="displayNetworkProxies()">${$.i18n.prop('menu.network-proxies')}</a>
-      </li>
-      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-configuration']}">
-        <a href="#" id="menu-legacy-support-list-a" onclick="displayLegacyArtifactPathSupport()">${$.i18n.prop('menu.legacy-artifact-support')}</a>
-      </li>
-      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-configuration']}">
-        <a href="#" id="menu-repository-scanning-list-a" onclick="displayRepositoryScanning()">${$.i18n.prop('menu.repository-scanning')}</a>
-      </li>
-      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-configuration']}">
-        <a href="#" id="menu-network-configuration-list-a" onclick="displayNetworkConfiguration()">${$.i18n.prop('menu.network-configuration')}</a>
-      </li>
-      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-configuration']}">
-        <a href="#" id="menu-system-status-list-a" onclick="displaySystemStatus()">${$.i18n.prop('menu.system-status')}</a>
-      </li>
-      <li style="display:none" redback-permissions="{permissions: ['archiva-manage-configuration']}">
-        <a href="#" id="menu-appearance-list-a" onclick="displayAppearanceConfiguration()">${$.i18n.prop('menu.appearance-configuration')}</a>
-      </li>
-
-
-    </ul>
-
-    <ul class="nav nav-list" redback-permissions="{permissions: ['archiva-manage-users']}">
-      <li class="nav-header">${$.i18n.prop('menu.users')}</li>
-      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-users']}">
-        <a href="#" id="menu-users-list-a" onclick="displayUsersGrid(this)">${$.i18n.prop('menu.users.manage')}</a>
-      </li>
-      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-users']}">
-        <a href="#" id="menu-roles-list-a" onclick="displayRolesGrid()">${$.i18n.prop('menu.users.roles')}</a>
-      </li>
-    </ul>
-
-  </div>
-</script>
-
-<script id="topbar_menu_tmpl" type="text/html">
-    <div id="topbar-menu">
-    <div class="navbar navbar-fixed-top">
-
-      <div style="max-height: 40px" class="navbar-inner">
-        <div class="container-fluid">
-          <div id="organisation-logo" class="pull-left"></div>
-          <ul class="nav pull-right">
-            <li id="create-admin-link" style="display: none">
-              <a href="#" onclick="adminCreateBox();" id="create-admin-link-a">
-                <span class="label label-important">${$.i18n.prop('create.admin.page.link')}</span>
-              </a>
-            </li>
-            <li id="login-link" style="display: none">
-              <a href="#" onclick="loginBox();" id="login-link-a">
-                <span class="label label-success force-upper-case">${$.i18n.prop('login')}</span>
-              </a>
-            </li>
-            <li id="change-password-link">
-              <a href="#" onclick="editUserDetailsBox();">${$.i18n.prop('edit.details')}</a>
-            </li>
-            <li id="logout-link" style="display: none">
-              <a href="#" onclick="logout(true);" id="logout-link-a">
-                <span class="label label-important force-upper-case">${$.i18n.prop('logout')}</span>
-              </a>
-            </li>
-            <li id="register-link" style="display: none">
-              <a href="#" onclick="registerBox();" id="register-link-a">
-                <span class="label label-info force-upper-case">${$.i18n.prop('register')}</span>
-              </a>
-            </li>
-            <li>
-              <div class="ui-widget navbar-search">
-
-                <input type="text" class="ui-autocomplete-input search-query" id="quick-search-autocomplete"
-                                   placeholder="${$.i18n.prop('menu.topbar.quicksearch')}" />
-              </div>
-            </li>
-          </ul>
-        </div>
-      </div>
-
-    </div>
-    </div>
-</script>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/message.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/message.html
deleted file mode 100644 (file)
index 44cf4da..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one
-  ~ or more contributor license agreements.  See the NOTICE file
-  ~ distributed with this work for additional information
-  ~ regarding copyright ownership.  The ASF licenses this file
-  ~ to you under the Apache License, Version 2.0 (the
-  ~ "License"); you may not use this file except in compliance
-  ~ with the License.  You may obtain a copy of the License at
-  ~
-  ~   http://www.apache.org/licenses/LICENSE-2.0
-  ~
-  ~ Unless required by applicable law or agreed to in writing,
-  ~ software distributed under the License is distributed on an
-  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-  ~ KIND, either express or implied.  See the License for the
-  ~ specific language governing permissions and limitations
-  ~ under the License.
--->
-<script id='alert-message-success' type='text/html'>
-  <div class="alert fade in alert-success" data-alert="alert">
-    <a class="close" data-dismiss="alert" href="#" id='alert-message-success-close-a'>&#215;</a>
-    ${message}
-  </div>
-</script>
-<script id='alert-message-error' type='text/html'>
-  <div class="alert fade in alert-error" data-alert="alert">
-    <a class="close" data-dismiss="alert" href="#" id='alert-message-error-close-a'>&#215;</a>
-    ${message}
-  </div>
-</script>
-<script id='alert-message-warning' type='text/html'>
-  <div class="alert fade in alert-heading" data-alert="alert">
-    <a class="close" data-dismiss="alert" href="#" id='alert-message-warning-close-a'>&#215;</a>
-    ${message}
-  </div>
-</script>
-<script id='alert-message-info' type='text/html'>
-  <div class="alert fade in alert-info" data-alert="alert">
-    <a class="close" data-dismiss="alert" href="#" id='alert-message-info-close-a'>&#215;</a>
-    ${message}
-  </div>
-</script>
-
-<script id='footer-tmpl' type='text/html'>
-  <div class="pull-left">
-    <a target="_blank" href="http://archiva.apache.org/">Apache Archiva&nbsp;-&nbsp;${version}</a>
-  </div>
-  <div class="pull-right">
-    Copyright &#169;  ${copyrightRange}  <a target="_blank" href="http://www.apache.org/">The Apache Software Foundation</a>
-  </div>
-</script>
-
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/modal.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/modal.html
deleted file mode 100644 (file)
index 890d1ab..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one
-  ~ or more contributor license agreements.  See the NOTICE file
-  ~ distributed with this work for additional information
-  ~ regarding copyright ownership.  The ASF licenses this file
-  ~ to you under the Apache License, Version 2.0 (the
-  ~ "License"); you may not use this file except in compliance
-  ~ with the License.  You may obtain a copy of the License at
-  ~
-  ~   http://www.apache.org/licenses/LICENSE-2.0
-  ~
-  ~ Unless required by applicable law or agreed to in writing,
-  ~ software distributed under the License is distributed on an
-  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-  ~ KIND, either express or implied.  See the License for the
-  ~ specific language governing permissions and limitations
-  ~ under the License.
--->
-<div id="dialog-confirm-modal" class="modal hide fade" style="display: block;">
-  <div class="modal-header">
-    <a class="close" href="#" data-dismiss="modal">&#215;</a>
-    <h3 id="dialog-confirm-modal-header-title"></h3>
-  </div>
-  <div class="modal-body">
-   <p id="dialog-confirm-modal-body-text"></p>
-  </div>
-  <div class="modal-footer">
-    <a class="btn secondary" id="dialog-confirm-modal-cancel" href="#">${$.i18n.prop('cancel')}</a>
-    <a class="btn primary" id="dialog-confirm-modal-ok" href="#">${$.i18n.prop('ok')}</a>
-  </div>
-</div>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/network-proxies.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/network-proxies.html
deleted file mode 100644 (file)
index 9c86057..0000000
+++ /dev/null
@@ -1,171 +0,0 @@
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one
-  ~ or more contributor license agreements.  See the NOTICE file
-  ~ distributed with this work for additional information
-  ~ regarding copyright ownership.  The ASF licenses this file
-  ~ to you under the Apache License, Version 2.0 (the
-  ~ "License"); you may not use this file except in compliance
-  ~ with the License.  You may obtain a copy of the License at
-  ~
-  ~   http://www.apache.org/licenses/LICENSE-2.0
-  ~
-  ~ Unless required by applicable law or agreed to in writing,
-  ~ software distributed under the License is distributed on an
-  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-  ~ KIND, either express or implied.  See the License for the
-  ~ specific language governing permissions and limitations
-  ~ under the License.
--->
-<script id="networkProxiesMain" type="text/html">
-  <div class="page-header">
-    <h2><img src="images/internet-web-browser-32-32.png"/>${$.i18n.prop('network-proxies.list')}</h2>
-  </div>
-
-  <ul id="network-proxies-view-tabs" class="nav nav-tabs">
-    <li id="network-proxies-view-tabs-li-grid">
-      <a data-toggle="tab" href="#network-proxies-view" id="network-proxies-view-tabs-a-network-proxies-grid">${$.i18n.prop('network-proxies.grid.tab.title')}</a>
-    </li>
-    <li id="network-proxies-view-tabs-li-edit">
-      <a data-toggle="tab" href="#network-proxies-edit">${$.i18n.prop('add')}</a>
-    </li>
-  </ul>
-  <div id="network-proxies-view-tabs-content" class="tab-content">
-    <div id="network-proxies-view" class="tab-pane">
-        <div id="network-proxies-bulk-save-btn" data-bind='template:{name:"network-proxies-bulk-save-tmpl"}'></div>
-        <table class="table table-striped table-bordered" id="networkProxiesTable"
-               data-bind="simpleGrid: gridViewModel,simpleGridTemplate:'ko-network-proxies-grid',pageLinksId:'network-proxiesPagination'">
-        </table>
-        <div id="network-proxiesPagination"></div>
-    </div>
-    <div id="network-proxies-edit" class="tab-pane" data-bind='template: {name:"network-proxy-edit-tmpl"}'></div>
-  </div>
-
-</script>
-
-<script id='ko-network-proxies-grid' type='text/html'>
-    <thead>
-    <tr>
-        {{each(i, columnDefinition) columns}}
-        <th>${ columnDefinition.headerText }</th>
-        {{/each}}
-        <th>${$.i18n.prop('password')}</th>
-        <th>${$.i18n.prop('network.proxy.useNtlm')}</th>
-        <th>${$.i18n.prop('edit')}</th>
-        <th>${$.i18n.prop('delete')}</th>
-        <th>${$.i18n.prop('modified')}</th>
-    </tr>
-    </thead>
-    <tbody>
-    {{each(i, row) itemsOnCurrentPage()}}
-      <tr data-bind="css:{ 'modified': row.modified()}">
-        {{each(j, columnDefinition) columns}}
-        {{var val = (typeof columnDefinition.rowText == 'function' ? columnDefinition.rowText(row) : row[columnDefinition.rowText])}}
-          <td>
-              ${val}
-          </td>
-        {{/each}}
-        {{if row.password()}}
-          <td>*****</td>
-        {{else}}
-          <td></td>
-        {{/if}}
-          <td>${row.useNtlm()}</td>
-          <td>
-            <a href="#" data-bind="click: function(){ editNetworkProxy(row) }">
-              <img src="images/edit-find-22-22.png" title="${$.i18n.prop('edit')}">
-            </a>
-          </td>
-          <td>
-            <a href="#" data-bind="click: function(){ removeNetworkProxy(row) }">
-              <img src="images/edit-cut.png" title="${$.i18n.prop('delete')}"/>
-            </a>
-          </td>
-        {{if row.modified()}}
-          <td>
-            <a href="#" data-bind="click: function(){ updateNetworkProxy(row) }" class="btn btn-warning">${$.i18n.prop('save')}</a>
-          </td>
-        {{else}}
-          <td></td>
-        {{/if}}
-
-    </tr>
-    {{/each}}
-    </tbody>
-
-</script>
-
-<script id="network-proxy-edit-tmpl" type='text/html'>
-    <form id="network-proxy-edit-form" class="well form-horizontal">
-      <fieldset id="network-proxy-edit-fieldset">
-        <div class="control-group">
-          <label class="control-label" for="id">${$.i18n.prop('id')}</label>
-          <div class="controls">
-            {{if update}}
-              <span class="uneditable-input">${$data.networkProxy.id}</span>
-            {{else}}
-              <input type="text" class="xlarge" id="id" name="id" size="10"
-                     data-bind="value: networkProxy.id,css:{'uneditable-input': update},readonly:update"/>
-            {{/if}}
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="protocol">${$.i18n.prop('protocol')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge required" id="protocol" name="protocol" size="8"
-                   data-bind="value: networkProxy.protocol"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="host">${$.i18n.prop('host')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge required" id="host" name="host" size="15"
-                   data-bind="value: networkProxy.host"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="port">${$.i18n.prop('port')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge required digits" id="port" name="port" size="6"
-                   data-bind="value: networkProxy.port"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="username">${$.i18n.prop('username')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge" id="username" name="username" size="50"
-                   data-bind="value: networkProxy.username"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="password">${$.i18n.prop('password')}</label>
-          <div class="controls">
-            <input type="password" class="xlarge" id="password" name="password" size="50"
-                   data-bind="value: networkProxy.password"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="useNtlm">${$.i18n.prop('network.proxy.useNtlm')}</label>
-          <div class="controls">
-            <input type="checkbox" id="useNtlm" name="useNtlm" data-bind="checked: networkProxy.useNtlm"/>
-          </div>
-        </div>
-
-      </fieldset>
-      <button id="network-proxy-btn-save" data-bind="click: save" class="btn">${$.i18n.prop('save')}</button>
-      {{if networkProxy.modified()}}
-       ${("#network-proxy-btn-save").button('reset')}
-      {{/if}}
-      <button data-bind="click: displayGrid" class="btn">${$.i18n.prop('cancel')}</button>
-    </form>
-</script>
-
-<script id="network-proxies-bulk-save-tmpl" type='text/html'>
-  {{if bulkSave()}}
-    <a data-bind="click: updateModifiedNetworkProxies" class="btn btn-danger" href="#">${$.i18n.prop('save.all')}</a>
-  {{/if}}
-</script>
-<script id="network-proxy-delete-warning-tmpl" type='text/html'>
-    <div>
-      <span class="label label-warning">${$.i18n.prop('warning.not.undone.operation')}</span>
-    </div>
-</script>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/proxy-connectors.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/proxy-connectors.html
deleted file mode 100644 (file)
index c9d1920..0000000
+++ /dev/null
@@ -1,310 +0,0 @@
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one
-  ~ or more contributor license agreements.  See the NOTICE file
-  ~ distributed with this work for additional information
-  ~ regarding copyright ownership.  The ASF licenses this file
-  ~ to you under the Apache License, Version 2.0 (the
-  ~ "License"); you may not use this file except in compliance
-  ~ with the License.  You may obtain a copy of the License at
-  ~
-  ~   http://www.apache.org/licenses/LICENSE-2.0
-  ~
-  ~ Unless required by applicable law or agreed to in writing,
-  ~ software distributed under the License is distributed on an
-  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-  ~ KIND, either express or implied.  See the License for the
-  ~ specific language governing permissions and limitations
-  ~ under the License.
--->
-<script id="proxyConnectorsMain" type="text/html">
-  <div class="page-header">
-    <h2><img src="images/preferences-system-network-proxy-32-32.png"/>${$.i18n.prop('proxy-connectors.list')}</h2>
-  </div>
-
-  <ul id="proxy-connectors-view-tabs" class="nav nav-tabs">
-    <li id="proxy-connectors-view-tabs-li-grid" class="active">
-      <a data-toggle="tab" href="#proxy-connectors-view" id="proxy-connectors-view-tabs-a-network-proxies-grid">${$.i18n.prop('proxy-connectors.grid.tab.title')}</a>
-    </li>
-    <li id="proxy-connectors-view-tabs-li-edit">
-      <a data-toggle="tab" href="#proxy-connectors-edit" id="proxy-connectors-view-tabs-a-edit">${$.i18n.prop('add')}</a>
-    </li>
-    <li id="proxy-connectors-view-tabs-li-edit-order">
-      <a data-toggle="tab" href="#proxy-connectors-edit-order" id="proxy-connectors-view-tabs-a-edit-order">${$.i18n.prop('proxy-connectors.grid.tab.edit.order')}</a>
-    </li>
-  </ul>
-  <div id="proxy-connectors-view-tabs-content" class="tab-content">
-    <div id="proxy-connectors-view" class="tab-pane active">
-      <div id="proxy-connectors-bulk-save-btn" data-bind='template:{name:"proxy-connectors-bulk-save-tmpl"}'></div>
-      <table class="table table-striped table-bordered" id="proxyConnectorsTable"
-             data-bind="simpleGrid: gridViewModel,simpleGridTemplate:'ko-proxy-connectors-grid',pageLinksId:'proxy-connectorsPagination'">
-      </table>
-      <div id="proxy-connectorsPagination"></div>
-    </div>
-    <div id="proxy-connectors-edit" class="tab-pane"></div>
-    <div id="proxy-connector-edit-order" class="tab-pane span8">
-      <div id="proxy-connector-edit-order-managed-repository-div" data-bind='template:{name:"proxy-connector-edit-order-managed-repository-tmpl"}'></div>
-      <div id="proxy-connector-edit-order-div"
-         data-bind="sortable: { template: 'proxy-connector-edit-order-tmpl', data: proxyConnectors,afterMove: proxyConnectorMoved}">
-      </div>
-    </div>
-  </div>
-
-</script>
-
-<script id='ko-proxy-connectors-grid' type='text/html'>
-    <thead>
-      <tr>
-        <th title="${$.i18n.prop('proxy-connectors.grid.managedrepo.title')}">
-          ${$.i18n.prop('proxy-connectors.grid.managedrepo.grid.header')}
-        </th>
-        <th title="${$.i18n.prop('proxy-connectors.grid.remoterepo.title')}">
-          ${$.i18n.prop('proxy-connectors.grid.remoterepo.grid.header')}
-        </th>
-        <th>${$.i18n.prop('proxy-connectors.grid.remoterepo.settings.popover.title')}</th>
-        <th>${$.i18n.prop('edit')}</th>
-        <th>${$.i18n.prop('delete')}</th>
-        <th>${$.i18n.prop('save')}</th>
-        <th>${$.i18n.prop('proxy-connectors.grid.header.order')}</th>
-      </tr>
-    </thead>
-    <tbody>
-    {{each(i, row) itemsOnCurrentPage()}}
-    <tr data-bind="css:{ 'modified': row.modified()}">
-      <td>${row.sourceRepoId()}</td>
-      <td>${row.targetRepoId()}</td>
-      <td>
-          <img src="images/utilities-system-monitor-22-22.png" id="proxy-connectors-grid-remoterepo-settings-edit-${row.sourceRepoId()}-${row.targetRepoId()}"
-               data-original-title="${$.i18n.prop('proxy-connectors.grid.remoterepo.settings.popover.title')}"
-               data-bind="event: { mouseover: function(){ showSettings(row)},}">
-          <div id="proxy-connectors-grid-remoterepo-settings-content-${row.sourceRepoId()}-${row.targetRepoId()}"
-               style="display:none"></div>
-      </td>
-      <td>
-        <a data-bind="click: function(){ editProxyConnector(row)}" href="#">
-          <img src="images/edit-find-22-22.png" title="${$.i18n.prop('edit')}">
-        </a>
-      </td>
-      <td>
-        <a href="#" data-bind="click: function(){ deleteProxyConnector(row)}">
-          <img src="images/edit-cut-22-22.png" title="${$.i18n.prop('delete')}"/>
-        </a>
-      </td>
-      <td>
-        {{if row.modified()}}
-          <a href="#" class="btn btn-warning" data-bind="click: function(){ updateProxyConnector(row)}">
-              ${$.i18n.prop('save')}
-          </a>
-        {{/if}}
-      </td>
-      <td>
-        {{if orderChangeAware(row)}}
-          <a href="#" class="btn btn-info" data-bind="click: function(){ displayOrderEdit(row)}">
-              ${$.i18n.prop('proxy-connectors.order.edit')}
-          </a>
-          <span class="badge badge-info">${row.order()}</span>
-        {{/if}}
-      </td>
-    </tr>
-    {{/each}}
-    </tbody>
-    <div id="proxy-connectors-grid-remoterepo-settings-content-${val}-${targetRepoId}" style="display:none"></div>
-</script>
-
-<script id='proxy-connectors-remote-settings-popover-tmpl' type='text/html'>
-  <div>
-    {{if proxyId}}
-      ${$.i18n.prop('proxy-connectors.remoterepo.settings.networkproxy')}: ${proxyConnector.proxyId}
-    {{else}}
-      ${$.i18n.prop('proxy-connectors.remoterepo.settings.networkproxy')}: ${$.i18n.prop('none')}
-    {{/if}}
-    <table class="table">
-      <thead>
-        <th colspan="2">${$.i18n.prop('proxy-connector.policies')}</th>
-      </thead>
-      <tbody>
-        {{each(i, entry) proxyConnector.policiesEntries}}
-        {{var name = proxyConnectorsViewModel.findPolicyInformationName(entry.key)}}
-        <tr>
-          <td>${name}</td>
-          <td>${entry.value}</td>
-        </tr>
-        {{/each}}
-      </tbody>
-    </table>
-  </div>
-</script>
-
-<script id="proxy-connector-edit-form-tmpl" type='text/html'>
-
-    <form id="proxy-connector-edit-form" class="well form-horizontal">
-      <fieldset id="remote-repository-edit-fieldset">
-        <div class="control-group">
-          <label class="control-label" for="proxyId">${$.i18n.prop('proxy-connector.network-proxy.id')}</label>
-          <div class="controls">
-            <select id="proxyId"
-                    data-bind="options: proxyConnectorsViewModel.networkProxies, optionsText: 'id',optionsValue:'id',
-                     value: proxyConnector.proxyId, optionsCaption: 'direct connection'"></select>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="proxyId">${$.i18n.prop('proxy-connector.managed.repository.id')}</label>
-          <div class="controls">
-              <select id="sourceRepoId"
-                      data-bind="options: proxyConnectorsViewModel.managedRepositories, optionsText: 'id',optionsValue:'id',
-                      value: proxyConnector.sourceRepoId,attr: {disabled: isUpdate() }"></select>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="proxyId">${$.i18n.prop('proxy-connector.remote.repository.id')}</label>
-          <div class="controls">
-            <select id="targetRepoId"
-                    data-bind="options: proxyConnectorsViewModel.remoteRepositories, optionsText: 'id',optionsValue:'id',
-                     value: proxyConnector.targetRepoId,attr: {disabled: isUpdate() }"></select>
-          </div>
-        </div>
-        <div class="row">
-          <div class="control-group span6">
-            <table class="table">
-              <thead>
-                <th colspan="2">${$.i18n.prop('proxy-connector.policies')}</th>
-              </thead>
-              <tbody data-bind="foreach: proxyConnectorsViewModel.policyInformations()">
-                  <tr>
-                    <td data-bind="text: name"></td>
-                    <td>
-                      <select
-                              data-bind="options: getPolicyOptions(id()),value:getSelectedPolicyOption(id()),
-                              attr: { id: 'policy-'+id() },event: { change: function(){ changePolicyOption(id())},}"
-                              ></select>
-                    </td>
-                  </tr>
-              </tbody>
-            </table>
-          </div>
-        </div>
-        <div class="row">
-          <div class="control-group span6">
-            <h4>${$.i18n.prop('proxy-connector.properties')}</h4>
-            <table class="table">
-              <thead>
-                <th><input type="text" id="property-key"/></th>
-                <th><input type="text" id="property-value"/></th>
-                <th><a href="#" data-bind="click: function(){ addProperty() }">${$.i18n.prop('add')}</a></th>
-              </thead>
-              <tbody data-bind="foreach: proxyConnector.propertiesEntries">
-                <tr>
-                  <td data-bind="text: key"></td>
-                  <td data-bind="text: value"></td>
-                  <td><a href="#" data-bind="click: function(){ $parent.deleteProperty(key)}">${$.i18n.prop('delete')}</a></td>
-                </tr>
-              </tbody>
-            </table>
-          </div>
-        </div>
-        <div class="row">
-          <div class="control-group span6">
-            <h4>${$.i18n.prop('proxy-connector.blacklist')}</h4>
-            <table class="table">
-              <thead>
-                <th><input type="text" id="blacklist-value"/></th>
-                <th><a href="#" data-bind="click: function(){ addBlacklistPattern() }">${$.i18n.prop('add')}</a></th>
-              </thead>
-              <tbody data-bind="foreach: proxyConnector.blackListPatterns">
-                <tr>
-                  <td data-bind="text: $data"></td>
-                  <td><a href="#" data-bind="click: function(){removeBlacklistPattern($data)}">${$.i18n.prop('delete')}</a></td>
-                </tr>
-              </tbody>
-            </table>
-          </div>
-        </div>
-        <div class="row">
-          <div class="control-group span6">
-            <h4>${$.i18n.prop('proxy-connector.whitelist')}</h4>
-            <table class="table">
-              <thead>
-                <th><input type="text" id="whitelist-value"/></th>
-                <th><a href="#" data-bind="click: function(){ addWhitelistPattern() }">${$.i18n.prop('add')}</a></th>
-              </thead>
-              <tbody data-bind="foreach: proxyConnector.whiteListPatterns">
-                <tr>
-                  <td data-bind="text: $data"></td>
-                  <td><a href="#" data-bind="click: function(){removeWhitelistPattern($data)}">${$.i18n.prop('delete')}</a></td>
-                </tr>
-              </tbody>
-            </table>
-          </div>
-        </div>
-      </fieldset>
-
-      <button id="proxy-connector-btn-save" data-bind="click: save" class="btn">${$.i18n.prop('save')}</button>
-      {{if modified()}}
-       ${("#network-proxy-btn-save").button('reset')}
-      {{/if}}
-      <button data-bind="click: displayGrid" class="btn">${$.i18n.prop('cancel')}</button>
-
-    </form>
-
-</script>
-<script id="proxy-connectors-bulk-save-tmpl" type='text/html'>
-  {{if bulkSave()}}
-    <a data-bind="click: updateModifiedProxyConnectors" class="btn btn-danger" href="#">${$.i18n.prop('save.all')}</a>
-  {{/if}}
-</script>
-
-<script id="proxy-connector-edit-order-tmpl" type='text/html'>
-  <div class="well draggable-item network-proxy-remote-item">
-    {{var remoteRepository=$parent.findRemoteRepository(targetRepoId)}}
-    <div class="row-fluid">
-      <div class="span1">
-        <img src="images/system-software-update-32-32.png"/>
-          <br/>
-          <img src="images/utilities-system-monitor-22-22.png"
-               id="proxy-connectors-order-remoterepo-settings-edit-${sourceRepoId()}-${targetRepoId()}"
-               data-original-title="${$.i18n.prop('proxy-connectors.grid.remoterepo.settings.popover.title')}"
-               data-bind="event: { mouseover: function(){ displaySettings(sourceRepoId(),targetRepoId())},}">
-          <div id="proxy-connectors-order-remoterepo-settings-content-${sourceRepoId()}-${targetRepoId()}"
-               style="display:none"></div>
-      </div>
-      <div class="span6 pull-left">
-        <blockquote>
-            ${targetRepoId}
-            <br/>
-            ${remoteRepository.name()}&nbsp;(<a href="${remoteRepository.url()}" target="_blank">${remoteRepository.url()}</a>)
-        </blockquote>
-      </div>
-      <div class="span2">
-        <span class="badge badge-info">${order}</span>
-      </div>
-    </div>
-  </div>
-</script>
-
-<script id="proxy-connector-edit-order-managed-repository-tmpl" type="text/html">
-  <div class="well row-fluid">
-    <div class="span1">
-      <img src="images/applications-internet-32-32.png"/>
-    </div>
-    <div class="span6">
-      <blockquote>
-        ${managedRepository.id}
-        <br/>
-        ${managedRepository.name}
-      </blockquote>
-    </div>
-    <div class="span2">
-      {{if proxyConnectorsViewModel.bulkSave()}}
-        <p>
-          <a data-bind="click: function(){updateModifiedProxyConnectors()}"
-             href="#" class="btn btn-warning">${$.i18n.prop('save.all')}</a></p>
-      {{/if}}
-    </div>
-  </div>
-</script>
-
-<script id="proxy-connector-delete-warning-tmpl" type='text/html'>
-    <div>
-      <span class="label label-warning">${$.i18n.prop('warning.not.undone.operation')}</span>
-    </div>
-</script>
-
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/repositories.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/repositories.html
deleted file mode 100644 (file)
index 5cbec28..0000000
+++ /dev/null
@@ -1,483 +0,0 @@
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one
-  ~ or more contributor license agreements.  See the NOTICE file
-  ~ distributed with this work for additional information
-  ~ regarding copyright ownership.  The ASF licenses this file
-  ~ to you under the Apache License, Version 2.0 (the
-  ~ "License"); you may not use this file except in compliance
-  ~ with the License.  You may obtain a copy of the License at
-  ~
-  ~   http://www.apache.org/licenses/LICENSE-2.0
-  ~
-  ~ Unless required by applicable law or agreed to in writing,
-  ~ software distributed under the License is distributed on an
-  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-  ~ KIND, either express or implied.  See the License for the
-  ~ specific language governing permissions and limitations
-  ~ under the License.
--->
-<script id="repositoriesMain" type="text/html">
-    <div class="page-header">
-      <h2><img src="images/system-file-manager-32-32.png"/>${$.i18n.prop('administration.repositories')}</h2>
-    </div>
-
-      <ul id="repositories-tabs" class="nav nav-tabs">
-        <li class="active">
-          <a data-toggle="tab" href="#managed-repositories-content">${$.i18n.prop('managedrepositories.grid.head')}</a>
-        </li>  
-        <li>
-          <a data-toggle="tab" href="#remote-repositories-content">${$.i18n.prop('remoterepositories.grid.head')}</a>
-        </li>
-      </ul>  
-      <div class="tab-content">
-       <div id="managed-repositories-content" class="tab-pane active">
-            <ul id="managed-repositories-pills" class="nav nav-pills">
-              <li class="active" id="managed-repositories-view-li">
-                <a data-toggle="tab" href="#managed-repositories-view" id="managed-repositories-view-a">${$.i18n.prop('managedrepositories.grid.tab.title')}</a>
-              </li>
-              <li id="managed-repository-edit-li">
-                <a data-toggle="tab" href="#managed-repository-edit">${$.i18n.prop('add')}</a>
-              </li>
-            </ul>
-            <div id="managed-repositories-tabs-content" class="pill-content">
-              <div id="managed-repositories-view" class="pill-pane active">
-                <div id="managed-repositories-bulk-save-btn" data-bind='template:{name:"managed-repositories-bulk-save-tmpl"}'></div>
-                <table class="table table-striped table-bordered" id="managed-repositories-table"
-                       data-bind="simpleGrid: gridViewModel,simpleGridTemplate:'ko_managed-repositoriesGrid',pageLinksId:'managed-repositoriesPagination',data:'managedRepositories'">
-                </table>
-                <div id="managed-repositoriesPagination"></div>
-                <div id="managed-repositories-pom-snippet"></div>
-              </div>
-              <div id="managed-repository-edit" class="pill-pane" data-bind='template: {name:"managed-repository-edit-tmpl"}'>
-              </div>
-            </div>
-       </div>
-
-
-       <div id="remote-repositories-content" class="tab-pane">
-            <ul id="remote-repositories-pills" class="nav nav-pills">
-              <li class="active" id="remote-repositories-view-li">
-                <a data-toggle="tab" href="#remote-repositories-view" id="remote-repositories-view-a">${$.i18n.prop('remoterepositories.grid.tab.title')}</a>
-              </li>
-              <li id="remote-repository-edit-li">
-                <a data-toggle="tab" href="#remote-repository-edit">${$.i18n.prop('add')}</a>
-              </li>
-            </ul>
-            <div id="remote-repositories-tabs-content" class="pill-content">
-              <div id="remote-repositories-view" class="pill-pane active">
-                  <div id="remote-repositories-bulk-save-btn" data-bind='template:{name:"remote-repositories-bulk-save-tmpl"}'></div>
-                  <table class="table table-striped table-bordered" id="remote-repositories-table"
-                         data-bind="simpleGrid: gridViewModel,simpleGridTemplate:'ko_remote-repositoriesGrid',pageLinksId:'remote-repositoriesPagination',data:'remoteRepositories'">
-                  </table>
-                  <div id="remote-repositoriesPagination"></div>
-              </div>
-              <div id="remote-repository-edit" class="pill-pane" data-bind='template: {name:"remote-repository-edit-tmpl"}'>
-              </div>
-            </div>
-       </div>
-      </div>
-</script>
-
-<script id='ko_managed-repositoriesGrid' type='text/html'>
-  <thead>
-      <tr>
-        {{each(i, columnDefinition) columns}}
-          <th title="${ columnDefinition.title }">${ columnDefinition.headerText }</th>
-        {{/each}}
-        <th>Releases</th>
-        <th>Snapshots</th>
-        <th title="${$.i18n.prop('managedrepository.scan.index')}">${$.i18n.prop('managedrepository.scan.grid.header')}</th>
-        <th>${$.i18n.prop('edit')}</th>
-        <th>${$.i18n.prop('delete')}</th>
-        <th>${$.i18n.prop('modified')}</th>
-        <th>${$.i18n.prop('managedrepository.pomsnippet')}</th>
-        <th title="${$.i18n.prop('managedrepository.stats')}">${$.i18n.prop('managedrepository.stats.grid.header')}</th>
-        <th title="${$.i18n.prop('managedrepository.scan.directories')}">${$.i18n.prop('managedrepository.scan.directories.grid.header')}</th>
-      </tr>
-  </thead>
-  <tbody>
-      {{each(i, row) itemsOnCurrentPage()}}
-          <tr data-bind="css:{ 'modified': row.modified()}">
-            {{each(j, columnDefinition) columns}}
-              <td>${ typeof columnDefinition.rowText == 'function' ? columnDefinition.rowText(row) : row[columnDefinition.rowText] }</td>
-            {{/each}}
-            <td>
-            {{if row.releases() == true}}
-              <img src="images/weather-clear-22-22.png" title="${$.i18n.prop('release.included')}"/>
-            {{else}}
-              <img src="images/dialog-error-22-22.png" title="${$.i18n.prop('release.notincluded')}"/>
-            {{/if}}
-            </td>
-
-            <td>
-              {{if row.snapshots() == true}}
-                <img src="images/weather-clear-22-22.png" title="${$.i18n.prop('snapshots.included')}"/>
-              {{else}}
-                  <img src="images/dialog-error-22-22.png" title="${$.i18n.prop('snapshots.notincluded')}"/>
-              {{/if}}
-            </td>
-            <td>
-              <a href="#" data-bind="click: function(){ scanNow(row) }">
-                <img src="images/view-refresh-22-22.png" title="${$.i18n.prop('managedrepository.scan.now')}"/>
-              </a>
-            </td>
-            <td>
-              <a href="#" data-bind="click: function(){ editManagedRepository(row) }">
-                <img src="images/edit-find-22-22.png" title="${$.i18n.prop('edit')}">
-              </a>
-            </td>
-            <td>
-              <a href="#" data-bind="click: function(){ removeManagedRepository(row) }">
-                <img src="images/edit-cut-22-22.png" title="${$.i18n.prop('delete')}"/>
-              </a>
-            </td>
-            {{if row.modified()}}
-              <td>
-                <a href="#" class="btn btn-warning" data-bind="click: function(){ updateManagedRepository(row) }">${$.i18n.prop('save')}</a>
-              </td>
-            {{else}}
-              <td></td>
-            {{/if}}
-            <td><a href="#" data-bind="click: function(){ showPomSnippet(row) }">${$.i18n.prop('managedrepository.pomsnippet')}</a></td>
-            <td id="managedrepository-stats-${row.id()}">
-              <img src="images/utilities-system-monitor-22-22.png" data-original-title="${$.i18n.prop('managedrepository.stats')}"
-                   data-bind="event: { mouseover: function(){ showStats(row) }, mouseout: function(){ hideStats(row) },}"
-                   id="managedrepository-stats-img-${row.id()}"/>
-            </td>
-            <td>
-              <a href="#" data-bind="click: function(){directoriesScan(row)}" class="btn btn-warning">${$.i18n.prop('managedrepository.scan.directories.grid')}</a>
-            </td>
-          </tr>
-      {{/each}}
-  </tbody>
-
-</script>
-
-<script id="managed-repository-edit-tmpl" type='text/html'>
-    <form id="managed-repository-edit-form" class="well form-horizontal">
-      <fieldset id="managed-repository-edit-fieldset">
-        <div class="control-group">
-          <label class="control-label" for="id">${$.i18n.prop('id')}</label>
-          <div class="controls">
-            {{if update}}
-              <span class="uneditable-input">${$data.managedRepository.id}</span>
-            {{else}}
-              <input type="text" class="xlarge required" id="id" name="id" size="50"
-                     data-bind="value: managedRepository.id,css:{'uneditable-input': update},readonly:update"/>
-            {{/if}}
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="name">${$.i18n.prop('name')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge required" id="name" name="name" size="50"
-                   data-bind="value: managedRepository.name"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="location">${$.i18n.prop('directory')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge required" id="location" name="location" size="50" data-bind="value: managedRepository.location"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="indexDirectory">${$.i18n.prop('index.directory')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge" id="indexDirectory" name="indexDirectory" size="50" data-bind="value: managedRepository.indexDirectory"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="layout">${$.i18n.prop('type')}</label>
-          <div class="controls">
-            <select id="layout" data-bind="options: availableLayouts,optionsText: 'label',optionsValue:'type',value: managedRepository.layout"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="cronExpression">${$.i18n.prop('cronExpression')}</label>
-          <div class="controls">
-            <input type="text" id="cronExpression" class="required" name="cronExpression" size="40" data-bind="value: managedRepository.cronExpression"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="daysOlder">${$.i18n.prop('daysOlder')}</label>
-          <div class="controls">
-            <input type="text" id="daysOlder" class="digits" name="daysOlder" size="5" data-bind="value: managedRepository.daysOlder"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="retentionCount">${$.i18n.prop('retentionCount')}</label>
-          <div class="controls">
-            <input type="text" id="retentionCount" name="retentionCount" size="5" data-bind="value: managedRepository.retentionCount"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="releases">${$.i18n.prop('releases')}</label>
-          <div class="controls">
-            <input type="checkbox" id="releases" name="releases" size="5" data-bind="checked: managedRepository.releases"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="snapshots">${$.i18n.prop('snapshots')}</label>
-          <div class="controls">
-            <input type="checkbox" id="snapshots" name="snapshots" size="5" data-bind="checked: managedRepository.snapshots"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="blockRedeployments">${$.i18n.prop('blockRedeployments')}</label>
-          <div class="controls">
-            <input type="checkbox" id="blockRedeployments" name="blockRedeployments" size="5" data-bind="checked: managedRepository.blockRedeployments"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="scanned">${$.i18n.prop('scanned')}</label>
-          <div class="controls">
-            <input type="checkbox" id="scanned" name="scanned" size="5" data-bind="checked: managedRepository.scanned"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="deleteReleasedSnapshots">${$.i18n.prop('deleteReleasedSnapshots')}</label>
-          <div class="controls">
-            <input type="checkbox" id="deleteReleasedSnapshots" name="deleteReleasedSnapshots" size="5"
-                   data-bind="checked: managedRepository.deleteReleasedSnapshots"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="stageRepoNeeded">${$.i18n.prop('stageRepoNeeded')}</label>
-          <div class="controls">
-            <input type="checkbox" id="stageRepoNeeded" name="stageRepoNeeded" size="5"
-                   data-bind="checked: managedRepository.stageRepoNeeded"/>
-          </div>
-        </div>
-      </fieldset>
-      <button data-bind="click: save" class="btn">${$.i18n.prop('save')}</button>
-      <button data-bind="click: displayGrid" class="btn">${$.i18n.prop('cancel')}</button>
-    </form>
-</script>
-
-<script id="managed-repository-delete-warning-tmpl" type='text/html'>
-  <div>
-    <span class="label label-warning">${$.i18n.prop('warning.not.undone.operation')}</span>
-    <div>
-      <span><strong>${$.i18n.prop('managedrepository.delete.warning.message')}</strong>.</span>
-      <div>${$.i18n.prop('id')}: ${id()}</div>
-      <div>${$.i18n.prop('name')}: ${name()}</div>
-    </div>
-    <div>
-        ${$.i18n.prop('managedrepository.delete.content')}: <input type="checkbox" id="managedrepository-deletecontent">
-    </div>
-  </div>
-</script>
-
-<script type="text/html" id="remote-repository-delete-modal-tmpl">
-    <div>
-      <span class="label label-warning">${$.i18n.prop('warning.not.undone.operation')}</span>
-    </div>
-</script>
-
-<script id="managed-repository-location-warning-tmpl" type='text/html'>
-  <div>
-    <span class="label label-warning">${$.i18n.prop('managedrepository.location.already.exists')}</span>
-    <div>
-      <span><strong>${$.i18n.prop('managedrepository.location.already.exists.warning.message')}</strong>.</span>
-      <div>${$.i18n.prop('id')}: ${id()}</div>
-      <div>${$.i18n.prop('name')}: ${name()}</div>
-    </div>
-  </div>
-</script>
-<script id="managed-repository-scan-now-modal-tmpl" type='text/html'>
-  <div>
-    ${$.i18n.prop('managedrepository.scan.all')}: <input type="checkbox" id="managed-repository-scan-now-all">
-  </div>
-</script>
-<script id="managed-repository-stats-tmpl" type='text/html'>
-  <div id="managedrepository-stats-${managedRepository.id()}-popover" style="display:none">
-    <div>${$.i18n.prop('managedrepository.stats.endTime')}: ${lastScanDate()}</div>
-    <div>${$.i18n.prop('managedrepository.stats.duration')}: ${duration()}ms</div>
-    <div>${$.i18n.prop('managedrepository.stats.totalFileCount')}: ${totalFileCount()}</div>
-    <div>${$.i18n.prop('managedrepository.stats.newFileCount')}: ${newFileCount()}</div>
-  </div>
-</script>
-<script id="pom-snippet-tmpl" type='text/html'>
-  <div class="page-header">
-    <h2>POM Snippet</h2></div>
-  </div>
-  <div><a href="#" onclick="$('#managed-repositories-pom-snippet').effect('blind')">${$.i18n.prop('hide')}</a></div>
-  <pre>${$data}</pre>
-</script>
-
-<!-- remote part -->
-
-<script id='ko_remote-repositoriesGrid' type='text/html'>
-  <thead>
-      <tr>
-        {{each(i, columnDefinition) columns}}
-          <th title="${ columnDefinition.title }">${ columnDefinition.headerText }</th>
-        {{/each}}
-        <th>${$.i18n.prop('edit')}</th>
-        <th>${$.i18n.prop('delete')}</th>
-        <th>${$.i18n.prop('modified')}</th>
-        <th>${$.i18n.prop('remoterepository.downloadremoteindex')}</th>
-      </tr>
-  </thead>
-  <tbody>
-      {{each(i, row) itemsOnCurrentPage()}}
-          <tr data-bind="css:{ 'modified': row.modified()}">
-            {{each(j, columnDefinition) columns}}
-              <td>${ typeof columnDefinition.rowText == 'function' ? columnDefinition.rowText(row) : row[columnDefinition.rowText] }</td>
-            {{/each}}
-            <td>
-              <a href="#" data-bind="click: function(){ editRemoteRepository(row) }">
-                <img src="images/edit-find-22-22.png" title="${$.i18n.prop('edit')}">
-              </a>
-            </td>
-            <td>
-              <a href="#" data-bind="click: function(){ removeRemoteRepository(row) }">
-                <img src="images/edit-cut-22-22.png" title="${$.i18n.prop('delete')}"/>
-              </a>
-            </td>
-            {{if row.modified()}}
-              <td>
-                <a href="#" class="btn btn-warning" data-bind="click: function(){ updateRemoteRepository(row) }">${$.i18n.prop('save')}</a>
-              </td>
-            {{else}}
-              <td></td>
-            {{/if}}
-            <td>
-              <a href="#" data-bind="click: function(){ scheduleDownloadRemoteIndex(row) }">
-                <img src="images/view-refresh-22-22.png" title="${$.i18n.prop('remoterepository.downloadremoteindex.now')}"/>
-              </a>
-            </td>
-          </tr>
-      {{/each}}
-  </tbody>
-
-</script>
-
-
-<script id="remote-repository-edit-tmpl" type='text/html'>
-    <form id="remote-repository-edit-form" class="well form-horizontal">
-      <fieldset id="remote-repository-edit-fieldset">
-        <div class="control-group">
-          <label class="control-label" for="id">${$.i18n.prop('id')}</label>
-          <div class="controls">
-            {{if update}}
-              <span class="uneditable-input">${$data.remoteRepository.id}</span>
-            {{else}}
-              <input type="text" class="xlarge required" id="id" name="id" size="50"
-                     data-bind="value: remoteRepository.id,css:{'uneditable-input': update},readonly:update"/>
-            {{/if}}
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="name">${$.i18n.prop('name')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge required" id="name" name="name" size="50"
-                   data-bind="value: remoteRepository.name"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="url">${$.i18n.prop('url')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge required" id="url" name="location" size="50" data-bind="value: remoteRepository.url"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="userName">${$.i18n.prop('username')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge" id="userName" name="userName" size="50" data-bind="value: remoteRepository.indexDirectory"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="password">${$.i18n.prop('password')}</label>
-           <div class="controls">
-             <input type="password" class="xlarge" id="password" name="password" size="50" data-bind="value: remoteRepository.password"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="timeout">${$.i18n.prop('timeout')}</label>
-          <div class="controls">
-            <input type="text" id="timeout" class="digits" name="daysOlder" size="5" data-bind="value: remoteRepository.timeout"/>
-          </div>
-        </div>
-
-        <div class="control-group">
-          <label class="control-label" for="layout">${$.i18n.prop('type')}</label>
-          <div class="controls">
-            <select id="layout" data-bind="options: availableLayouts,optionsText: 'label',optionsValue:'type',value: remoteRepository.layout"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="downloadRemoteIndex">${$.i18n.prop('downloadRemoteIndex')}</label>
-          <div class="controls">
-            <input type="checkbox" id="downloadRemoteIndex" name="downloadRemoteIndex" size="5" data-bind="checked: remoteRepository.downloadRemoteIndex"/>
-          </div>
-        </div>
-
-        <div class="control-group">
-          <label class="control-label" for="remoteIndexUrl">${$.i18n.prop('remoteIndexUrl')}</label>
-          <div class="controls">
-            <input type="text" id="remoteIndexUrl" name="remoteIndexUrl" size="5" data-bind="value: remoteRepository.remoteIndexUrl"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="cronExpression">${$.i18n.prop('cronExpression')}</label>
-          <div class="controls">
-            <input type="text" id="cronExpression" name="cronExpression" size="40" data-bind="value: remoteRepository.cronExpression"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="indexDirectory">${$.i18n.prop('index.directory')}</label>
-          <div class="controls">
-            <input type="text" class="xlarge" id="indexDirectory" name="indexDirectory" size="50" data-bind="value: remoteRepository.indexDirectory"/>
-          </div>
-        </div>
-        <div class="control-group">
-          <label class="control-label" for="remoteDownloadTimeout">${$.i18n.prop('remoteDownloadTimeout')}</label>
-          <div class="controls">
-            <input type="text" id="remoteDownloadTimeout" class="digits" name="remoteDownloadTimeout" size="5"
-                   data-bind="value: remoteRepository.remoteDownloadTimeout"/>
-          </div>
-        </div>
-
-        <div class="control-group">
-          <label class="control-label" for="remoteDownloadNetworkProxyId">${$.i18n.prop('remoteDownloadNetworkProxyId')}</label>
-          <div class="controls">
-            <select id="remoteDownloadNetworkProxyId" data-bind="options: networkProxies, optionsText: 'id',optionsValue:'id', value: remoteRepository.remoteDownloadNetworkProxyId, optionsCaption: 'Choose...'"></select>
-          </div>
-        </div>
-
-
-        <div class="control-group">
-          <label class="control-label" for="downloadRemoteIndexOnStartup">${$.i18n.prop('downloadRemoteIndexOnStartup')}</label>
-          <div class="controls">
-            <input type="checkbox" id="downloadRemoteIndexOnStartup" name="downloadRemoteIndexOnStartup"
-                   data-bind="checked: remoteRepository.downloadRemoteIndexOnStartup"/>
-          </div>
-        </div>
-
-      </fieldset>
-      <button data-bind="click: save" class="btn">${$.i18n.prop('save')}</button>
-      <button data-bind="click: displayGrid" class="btn">${$.i18n.prop('cancel')}</button>
-    </form>
-</script>
-
-<script id="remote-repository-scan-modal-tmpl" type='text/html'>
-    <div>
-      ${$.i18n.prop('remoterepository.download.remote.now')}: <input type="checkbox" id="remoterepository-scan-now">
-    </div>
-    <div>
-      ${$.i18n.prop('remoterepository.download.remote.full')}: <input type="checkbox" id="remoterepository-scan-full">
-    </div>
-</script>
-
-<script id="managed-repositories-bulk-save-tmpl" type='text/html'>
-  {{if bulkSave()}}
-    <a data-bind="click: updateModifiedManagedRepositories" class="btn btn-danger" href="#">${$.i18n.prop('save.all')}</a>
-  {{/if}}
-</script>
-
-<script id="remote-repositories-bulk-save-tmpl" type='text/html'>
-  {{if bulkSave()}}
-    <a data-bind="click: updateModifiedRemoteRepositories" class="btn btn-danger" href="#">${$.i18n.prop('save.all')}</a>
-  {{/if}}
-</script>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/repository-groups.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/repository-groups.html
deleted file mode 100644 (file)
index 43685e5..0000000
+++ /dev/null
@@ -1,163 +0,0 @@
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one
-  ~ or more contributor license agreements.  See the NOTICE file
-  ~ distributed with this work for additional information
-  ~ regarding copyright ownership.  The ASF licenses this file
-  ~ to you under the Apache License, Version 2.0 (the
-  ~ "License"); you may not use this file except in compliance
-  ~ with the License.  You may obtain a copy of the License at
-  ~
-  ~   http://www.apache.org/licenses/LICENSE-2.0
-  ~
-  ~ Unless required by applicable law or agreed to in writing,
-  ~ software distributed under the License is distributed on an
-  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-  ~ KIND, either express or implied.  See the License for the
-  ~ specific language governing permissions and limitations
-  ~ under the License.
--->
-<script id="repositoryGroupsMain" type="text/html">
-  <div class="page-header">
-    <h2><img src="images/applications-internet-2-32-32.png"/>${$.i18n.prop('repository.groups.list')}</h2>
-  </div>
-  <ul id="repository-groups-view-tabs" class="nav nav-tabs">
-    <li id="repository-groups-view-tabs-li-grid" class="active">
-      <a data-toggle="tab" href="#repository-groups-view" id="repository-groups-view-tabs-a-network-proxies-grid">
-        ${$.i18n.prop('repository-groups.grid.tab.title')}
-      </a>
-    </li>
-    <li id="repository-groups-view-tabs-li-edit">
-      <a data-toggle="tab" href="#repository-groups-edit" id="repository-groups-view-tabs-a-edit">${$.i18n.prop('add')}</a>
-    </li>
-
-  </ul>
-  <div id="repository-groups-view-tabs-content" class="tab-content">
-        <div id="repository-groups-view" class="tab-pane active">
-          <div id="repository-groups-table" data-bind='template:{name:"repository-groups-table-tmpl"}'>
-          </div>
-        </div>
-        <div id="repository-groups-edit" class="tab-pane">
-              <div class="row-fluid">
-                <div class="span5 dotted">
-                  <div id="repository-groups-edit-div" data-bind='template:{name:"repository-group-edit-tmpl"}'></div>
-                  <div id="repository-groups-edit-order-div" style="min-height: 80px"
-                     data-bind="sortable: { template: 'repository-group-edit-order-tmpl',data:repositoryGroup.managedRepositories,afterMove:repositoryMoved}">
-                  </div>
-                </div>
-
-                <div class="span5 dotted">
-                  <h5>${$.i18n.prop('repository.groups.available.repositories')}</h5>
-                  <br/>
-                  <div id="repository-groups-edit-available-repositories" style="min-height: 80px"
-                       data-bind="sortable: { template: 'repository-group-edit-order-tmpl',data:availableRepositories,afterMove:repositoryMoved}">
-
-                  </div>
-                </div>
-
-              </div>
-
-        </div>
-
-  </div>
-</script>
-
-<script id="repository-groups-table-tmpl" type="text/html">
-  <table class="table table-striped table-bordered">
-    <thead>
-      <th>${$.i18n.prop('repository.groups.groups.grid.header')}</th>
-      <th>${$.i18n.prop('repository.groups.repositories.grid.header')}</th>
-      <th>${$.i18n.prop('edit')}</th>
-      <th>${$.i18n.prop('delete')}</th>
-      <th>${$.i18n.prop('save')}</th>
-    </thead>
-    <tbody>
-    {{each(i, repositoryGroup) repositoryGroups}}
-      <tr data-bind="css:{ 'modified': repositoryGroup.modified()}">
-        <td>${repositoryGroup.id}</td>
-        <td>
-          <ul>
-          {{each(j,id) repositoryGroup.repositories()}}
-            <li>${id}</li>
-          {{/each}}
-          </ul>
-        </td>
-        <td>
-          <a href="#" data-bind="click: function(){editRepositoryGroup(repositoryGroup)}">
-            <img src="images/edit-find-22-22.png" title="${$.i18n.prop('edit')}">
-          </a>
-        </td>
-        <td>
-          <a href="#" data-bind="click: function(){deleteRepositoryGroup(repositoryGroup)}">
-            <img src="images/edit-cut-22-22.png" title="${$.i18n.prop('delete')}"/>
-          </a>
-        </td>
-        <td>
-          {{if repositoryGroup.modified()}}
-            <a href="#" class="btn btn-warning" data-bind="click: function(){saveRepositoryGroup(repositoryGroup)}">
-              ${$.i18n.prop('save')}
-            </a>
-          {{/if}}
-        </td>
-      </tr>
-    {{/each}}
-    </tbody>
-  </table>
-</script>
-
-<script id="repository-group-edit-tmpl" type="text/html">
-  <div class="row-fluid">
-  {{if update}}
-    <div class="dotted span8">
-      <blockquote>
-        ${repositoryGroup.id}
-        <br/>
-        <a href="${window.archivaRuntimeInfo.baseUrl}/repository/${repositoryGroup.id()}" target="_blank">
-          ${window.archivaRuntimeInfo.baseUrl}/repository/${repositoryGroup.id()}
-        </a>
-      </blockquote>
-    </div>
-  {{else}}
-    <div class="dotted span8">
-      <form id="repository-group-edit-form" class="well">
-        <fieldset id="repository-group-edit-fieldset">
-          <div class="control-group">
-            <label class="control-label" for="id">${$.i18n.prop('id')}</label>
-            <div class="controls">
-              <input type="text" class="xlarge required" id="id" name="id" size="15"
-                   data-bind="value: repositoryGroup.id,css:{'uneditable-input': update},readonly:update"/>
-            </div>
-          </div>
-        </fieldset>
-      </form>
-    </div>
-  {{/if}}
-  {{if repositoryGroup.modified()}}
-    <div class="span3">
-      <a href="#" class="btn btn-warning" data-bind="click: function(){saveRepositoryGroup(repositoryGroup)}">${$.i18n.prop('save')}</a>
-    </div>
-    <br/>
-  {{/if}}
-  </div>
-</script>
-
-<script id="repository-group-edit-order-tmpl" type="text/html">
-  <div class="well draggable-item">
-    <blockquote>
-      ${$data.id()}
-      <br/>
-      ${$data.name()}
-      <br/>
-      <a href="${window.archivaRuntimeInfo.baseUrl}/repository/${$data.id()}" target="_blank">
-        ${window.archivaRuntimeInfo.baseUrl}/repository/${$data.id()}
-      </a>
-      <br/>
-    </blockquote>
-
-  </div>
-</script>
-
-<script id="repository-group-delete-warning-tmpl" type='text/html'>
-    <div>
-      <span class="label label-warning">${$.i18n.prop('warning.not.undone.operation')}</span>
-    </div>
-</script>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/search.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/search.html
deleted file mode 100644 (file)
index c0fd778..0000000
+++ /dev/null
@@ -1,785 +0,0 @@
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one
-  ~ or more contributor license agreements.  See the NOTICE file
-  ~ distributed with this work for additional information
-  ~ regarding copyright ownership.  The ASF licenses this file
-  ~ to you under the Apache License, Version 2.0 (the
-  ~ "License"); you may not use this file except in compliance
-  ~ with the License.  You may obtain a copy of the License at
-  ~
-  ~   http://www.apache.org/licenses/LICENSE-2.0
-  ~
-  ~ Unless required by applicable law or agreed to in writing,
-  ~ software distributed under the License is distributed on an
-  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-  ~ KIND, either express or implied.  See the License for the
-  ~ specific language governing permissions and limitations
-  ~ under the License.
--->
-
-<script id="browse-tmpl" type="text/html">
-  <div>
-    <div class="page-header">
-      <div><b>${$.i18n.prop('browse.repository')}</b></div>
-      <div id="selected_repository"></div>
-    </div>
-  </div>
-  <div id="main_browse_result">
-    <div id="main_browse_result_content" class="well">
-      <div id="browse_breadcrumb" data-bind='template:{name:"browse-breadcrumb-tmpl"}'></div>
-      <div id="browse_result" class="well" data-bind='template:{name:"browse-groups-tmpl"}'></div>
-      <div id="browse_artifact" class="well" data-bind='template:{name:"browse-artifact-tmpl"}'></div>
-      <div id="browse_artifact_detail" class="well" data-bind='template:{name:"browse-artifact-detail-tmpl"}'></div>
-    </div>
-  </div>
-</script>
-
-<script id="browse-groups-div-tmpl" type="text/html">
-  <div id="browse-groups-div" data-bind='template:{name:"browse-groups-tmpl"}'>
-  </div>
-</script>
-
-<script id="browse-groups-tmpl" type="text/html">
-  <div>
-    <ul>
-      <!-- if null we are on root level -->
-      {{if $root.parentBrowseViewModel}}
-        <li class="browse-list" data-bind="click:function(){displayParentGroupId()}">
-          <a href="#">..</a>
-        </li>
-      {{/if}}
-      {{each(i,browseResultEntry) browseResultEntries}}
-        {{if browseResultEntry.project}}
-          <li class="browse-list-project" data-bind="click:function(){displayProjectEntry(browseResultEntry.name)}">
-            <a href="#">${displayEntry(browseResultEntry.name)}</a>
-        {{else}}
-          <li class="browse-list" data-bind="click:function(){displayGroupId(browseResultEntry.name)}">
-            <a href="#" title="folder ${displayEntry(browseResultEntry.name)}">${displayEntry(browseResultEntry.name)}</a>
-        {{/if}}          
-          </li>
-      {{/each}}
-    </ul>
-  </div>
-</script>
-
-<script id="browse-breadcrumb-tmpl" type="text/html">
-  <ul class="breadcrumb">
-    <li>
-      <a href="#" data-bind="click: function(){ browseRoot()}"><img src="images/go-home.png"/></a>&nbsp;<span class="divider">/</span>
-    </li>
-    {{var number=breadCrumbEntries().length}}
-    {{each(i,breadCrumbEntry) breadCrumbEntries}}
-      <li>
-        {{if i==(number-1)}}
-          ${breadCrumbEntry.displayValue}
-        {{else}}
-          {{if breadCrumbEntry.artifact}}
-            <a href="#" data-bind="click: function(){displayArtifactDetail(breadCrumbEntry.groupId,breadCrumbEntry.artifactId,null,null)}">${breadCrumbEntry.displayValue}</a>
-          {{else}}
-            <a href="#" data-bind="click: function(){displayGroupId(breadCrumbEntry.groupId)}">${breadCrumbEntry.displayValue}</a>
-          {{/if}}
-        {{/if}}
-        {{if i<(number-1)}}
-          <span class="divider">/</span>
-        {{/if}}
-      </li>
-    {{/each}}
-    <li>
-      {{if number>0}}
-        <span class="divider" id="browse-autocomplete-divider">/</span>
-      {{/if}}
-      <input type="text" class="form-search span4" size="50" id="browse-autocomplete"/>
-    </li>
-  </ul>
-
-</script>
-
-<script id="browse-artifact-tmpl" type="text/html">
-  <div class="row-fluid">
-    <div class="span6">
-      <div class="page-header">
-        <h4>${$.i18n.prop('browse.artifact.display.artifactInfo')}</h4>
-      </div>
-      <div id="artifact-info" class="alert alert-info">
-        <table class="table table-condensed">
-          <tbody>
-            <tr>
-              <th>${$.i18n.prop('browse.artifact.groupId')}</th>
-              <td>${groupId}</td>
-            </tr>
-            <tr>
-              <th>${$.i18n.prop('browse.artifact.artifactId')}</th>
-              <td>${artifactId}</td>
-            </tr>
-            <tr>
-              <th>${$.i18n.prop('browse.artifact.name')}</th>
-              <td>${projectVersionMetadata.name}</td>
-            </tr>
-            <tr>
-              <th>${$.i18n.prop('browse.artifact.description')}</th>
-              <td>${projectVersionMetadata.description}</td>
-            </tr>
-            {{if projectVersionMetadata.mavenFacet}}
-            <tr>
-              <th>${$.i18n.prop('browse.artifact.packaging')}</th>
-              <td>${projectVersionMetadata.mavenFacet.packaging}</td>
-            </tr>
-            {{/if}}
-            {{if projectVersionMetadata.organization}}
-            <tr>
-              <th>${$.i18n.prop('browse.artifact.organization.name')}</th>
-              {{if projectVersionMetadata.organization.url}}
-                <td>
-                  <a href="${projectVersionMetadata.organization.url}" target="_blank">
-                    <img src="images/internet-web-browser.png" alt=""/>${projectVersionMetadata.organization.name}
-                  </a>
-                </td>
-              {{else}}
-                <td>${projectVersionMetadata.organization.name}</td>
-              {{/if}}
-            </tr>
-            {{/if}}
-            {{if projectVersionMetadata.issueManagement}}
-            <tr>
-              <th>${$.i18n.prop('browse.artifact.organization.issueManagement')}</th>
-              <td>
-                <a href="${projectVersionMetadata.issueManagement.url}" target="_blank">
-                  <img src="images/internet-web-browser.png" alt=""/>${projectVersionMetadata.issueManagement.system}
-                </a>
-              </td>
-            </tr>
-            {{/if}}
-          </tbody>
-        </table>
-      </div>
-    </div>
-    <div class="span4">
-      <div class="page-header">
-        <h4>${$.i18n.prop('browse.artifact.versions')}</h4>
-      </div>
-      <div class="alert alert-success">
-        <table class="table table-condensed">
-        {{each(i,version) versions}}
-          <tr>
-            <th><a href="#" data-bind="click: function(){displayArtifactVersionDetail(version)}">${version}</a></th>
-          </tr>
-        {{/each}}
-        </table>
-      </div>
-    </div>
-  </div>
-</script>
-<script id="search-artifacts-div-tmpl" type="text/html">
-    <div id="search-artifacts-div" data-bind='template:{name:"search-artifacts-form-tmpl"}'>
-    </div>
-</script>
-
-<script id="search-artifacts-form-tmpl" type="text/html">
-
-  <div class="page-header">
-    <h3>${$.i18n.prop('search.artifact.header')}</h3>
-  </div>
-  <div id="search-artifacts-tabs">
-    <div class="tabbable tabs-below">
-      <ul class="nav nav-tabs">
-        <li class="active" id="search-form-collapse-li">
-          <a data-toggle="tab" href="#search-form-collapse">${$.i18n.prop('search.artifact.form.header')}</a>
-        </li>
-          <li id="search-results-li">
-            <a data-toggle="tab" href="#search-results">${$.i18n.prop('search.artifact.results.header')}</a>
-          </li>
-      </ul>
-      <div class="tab-content">
-
-      <div id="search-form-collapse" class="tab-pane active">
-        <div class="tabbable tabs-below">
-          <ul class="nav nav-pills">
-            <li class="active">
-              <a href="#search-basic-form-pane" data-toggle="tab">${$.i18n.prop('search.artifact.search.form.basic')}</a>
-            </li>
-            <li>
-              <a href="#search-advanced-form-pane" data-toggle="tab">${$.i18n.prop('search.artifact.search.form.advanced')}</a>
-            </li>
-            <li>
-              <a href="#search-osgi-form-pane" data-toggle="tab">${$.i18n.prop('search.artifact.search.form.osgi')}</a>
-            </li>
-          </ul>
-          <div class="pill-content">
-            <div class="pill-pane active" id="search-basic-form-pane">
-              <form class="well form-inline" id="search-basic-form">
-                <fieldset>
-                  <div class="control-group" id="search-basic-repositories">
-                    <select data-placeholder="${$.i18n.prop('search.artifact.search.form.query.repositories')}"
-                            id="search-basic-repostories-select" class="chzn-select"
-                            multiple style="width:350px;" tabindex="4">
-                      <option value="all">${$.i18n.prop('search.artifact.search.form.repositories.all')}</option>
-                      {{each(i,repoId) observableRepoIds}}
-                        <option value="${repoId}">${repoId}</option>
-                      {{/each}}
-                    </select>
-                  </div>
-                  <div class="control-group">
-                    <label class="control-label" for="search-terms"></label>
-                    <div class="controls">
-                      <input type="text" class="input-medium search-query" id="search-terms" name="search-terms" size="50"
-                             data-bind="value: searchRequest().queryTerms" placeholder="${$.i18n.prop('search.artifact.search.form.query.terms')}"/>
-                    </div>
-                  </div>
-                  <button type="submit" id="btn-basic-search" class="btn btn-primary"
-                          data-loading-text="${$.i18n.prop('search.artifact.searching')}" data-bind="click: basicSearch">${$.i18n.prop('search.artifact.search.form.btn.search')}</button>
-                </fieldset>
-              </form>
-            </div>
-            <div class="pill-pane" id="search-advanced-form-pane">
-                <form class="well form-horizontal" id="search-advanced-form">
-                  <fieldset>
-                    <div class="control-group">
-                      <label class="control-label" for="groupId">${$.i18n.prop('search.artifact.search.form.query.groupId')}</label>
-                      <div class="controls">
-                        <input type="text" class="input-medium search-query" id="groupId" name="groupId" size="50"
-                               data-bind="value: searchRequest().groupId"/>
-                      </div>
-                    </div>
-                    <div class="control-group">
-                      <label class="control-label" for="artifactId">${$.i18n.prop('search.artifact.search.form.query.artifactId')}</label>
-                      <div class="controls">
-                        <input type="text" class="input-medium search-query" id="artifactId" name="artifactId" size="50"
-                               data-bind="value: searchRequest().artifactId"/>
-                      </div>
-                    </div>
-                    <div class="control-group">
-                      <label class="control-label" for="artifactId">${$.i18n.prop('search.artifact.search.form.query.version')}</label>
-                      <div class="controls">
-                        <input type="text" class="input-medium search-query" id="version" name="version" size="50"
-                               data-bind="value: searchRequest().version"/>
-                      </div>
-                    </div>
-                    <div class="control-group">
-                      <label class="control-label" for="artifactId">${$.i18n.prop('search.artifact.search.form.query.classifier')}</label>
-                      <div class="controls">
-                        <input type="text" class="input-medium search-query" id="classifier" name="classifier" size="50"
-                               data-bind="value: searchRequest().classifier"/>
-                      </div>
-                    </div>
-                    <div class="control-group">
-                      <label class="control-label" for="artifactId">${$.i18n.prop('search.artifact.search.form.query.packaging')}</label>
-                      <div class="controls">
-                        <input type="text" class="input-medium search-query" id="packaging" name="packaging" size="50"
-                               data-bind="value: searchRequest().packaging"/>
-                      </div>
-                    </div>
-                    <div class="control-group">
-                      <label class="control-label" for="artifactId">${$.i18n.prop('search.artifact.search.form.query.className')}</label>
-                      <div class="controls">
-                        <input type="text" class="input-medium search-query" id="className" name="className" size="50"
-                               data-bind="value: searchRequest().className"/>
-                      </div>
-                    </div>
-
-                  </fieldset>
-                  <button type="submit" id="btn-advanced-search" class="btn btn-primary"
-                          data-bind="click: advancedSearch">${$.i18n.prop('search.artifact.search.form.btn.search')}</button>
-
-                </form>
-            </div>
-            <div class="pill-pane" id="search-osgi-form-pane">
-                <form class="well form-horizontal" id="search-osgi-form">
-                  <fieldset>
-                    <div class="control-group">
-                      <label class="control-label" for="groupId">${$.i18n.prop('search.artifact.search.form.query.bundleSymbolicName')}</label>
-                      <div class="controls">
-                        <input type="text" class="input-medium search-query" id="bundleSymbolicName" name="bundleSymbolicName" size="50"
-                               data-bind="value: searchRequest().bundleSymbolicName"/>
-                      </div>
-                    </div>
-                    <div class="control-group">
-                      <label class="control-label" for="groupId">${$.i18n.prop('search.artifact.search.form.query.bundleVersion')}</label>
-                      <div class="controls">
-                        <input type="text" class="input-medium search-query" id="bundleVersion" name="bundleVersion" size="50"
-                               data-bind="value: searchRequest().bundleVersion"/>
-                      </div>
-                    </div>
-                    <div class="control-group">
-                      <label class="control-label" for="groupId">${$.i18n.prop('search.artifact.search.form.query.bundleExportPackage')}</label>
-                      <div class="controls">
-                        <input type="text" class="input-medium search-query" id="bundleExportPackage" name="bundleExportPackage" size="50"
-                               data-bind="value: searchRequest().bundleExportPackage"/>
-                      </div>
-                    </div>
-                    <div class="control-group">
-                      <label class="control-label" for="groupId">${$.i18n.prop('search.artifact.search.form.query.bundleExportService')}</label>
-                      <div class="controls">
-                        <input type="text" class="input-medium search-query" id="bundleExportService" name="bundleExportService" size="50"
-                               data-bind="value: searchRequest().bundleExportService"/>
-                      </div>
-                    </div>
-                    <div class="control-group">
-                      <label class="control-label" for="groupId">${$.i18n.prop('search.artifact.search.form.query.bundleImportPackage')}</label>
-                      <div class="controls">
-                        <input type="text" class="input-medium search-query" id="bundleImportPackage" name="bundleImportPackage" size="50"
-                               data-bind="value: searchRequest().bundleImportPackage"/>
-                      </div>
-                    </div>
-                    <div class="control-group">
-                      <label class="control-label" for="groupId">${$.i18n.prop('search.artifact.search.form.query.bundleRequireBundle')}</label>
-                      <div class="controls">
-                        <input type="text" class="input-medium search-query" id="bundleRequireBundle" name="bundleRequireBundle" size="50"
-                               data-bind="value: searchRequest().bundleRequireBundle"/>
-                      </div>
-                    </div>
-                  </fieldset>
-                  <button type="submit" id="btn-osgi-search" class="btn btn-primary"
-                          data-bind="click: advancedSearch">${$.i18n.prop('search.artifact.search.form.btn.search')}</button>
-
-                </form>
-            </div>
-          </div>
-        </div>
-      </div>
-
-
-      <div id="search-results" class="tab-pane">
-        <div class="row">
-          <div class="span3">
-            <a href="#" class="btn btn-warning" data-bind="click: removeFilter" id="remove-filter-id">${$.i18n.prop('search.artifact.result.filter')}</a>
-          </div>
-          <div class="span4" id="search-result-number-div">
-
-          </div>
-        </div>
-        <table class="table table-striped table-bordered" id="search-results-grid">
-        </table>
-        <div id="search-results-view-grid-pagination"></div>
-      </div>
-
-      </div>
-    </div>
-  </div>
-
-</script>
-
-<script type="text/html" id="search-result-number-div-tmpl">
-  <blockquote>
-      ${$.i18n.prop('search.artifact.result.size')}:&nbsp;${resultViewModel.artifacts().length}
-  </blockquote>
-
-</script>
-
-<script id="search-results-view-grid-tmpl" type="text/html">
-    <thead>
-        <tr>
-
-            <th title="${$.i18n.prop('search.artifact.results.groupId')}">${$.i18n.prop('search.artifact.results.groupId')}</th>
-            <th title="${$.i18n.prop('search.artifact.results.artifactId')}">${$.i18n.prop('search.artifact.results.artifactId')}</th>
-            <th title="${$.i18n.prop('search.artifact.results.version')}">${$.i18n.prop('search.artifact.results.version')}</th>
-            <th title="${$.i18n.prop('search.artifact.results.classifier')}">${$.i18n.prop('search.artifact.results.classifier')}</th>
-        </tr>
-        <tr>
-
-            <th title="${$.i18n.prop('search.artifact.results.groupId')}">
-              <input type="text" class="form-search" id="search-filter-auto-groupId"
-                     placeholder="${$.i18n.prop('search.artifact.result.grid.filter')}"/>
-            </th>
-            <th title="${$.i18n.prop('search.artifact.results.artifactId')}">
-              <input type="text" class="form-search" id="search-filter-auto-artifactId"
-                     placeholder="${$.i18n.prop('search.artifact.result.grid.filter')}"/>
-            </th>
-            <th title="${$.i18n.prop('search.artifact.results.version')}">
-              <input type="text" class="form-search" id="search-filter-auto-version"
-                     placeholder="${$.i18n.prop('search.artifact.result.grid.filter')}"/>
-            </th>
-            <th title="${$.i18n.prop('search.artifact.results.classifier')}">
-              <input type="text" class="form-search" id="search-filter-auto-classifier"
-                     placeholder="${$.i18n.prop('search.artifact.result.grid.filter')}"/>
-            </th>
-
-        </tr>
-    </thead>
-    <tbody>
-    {{each(i, row) itemsOnCurrentPage()}}
-      <tr>
-        <td><a href="#" data-bind="click: function(){groupIdView(row)}">${row.groupId}</a></td>
-        <td><a href="#" data-bind="click: function(){artifactIdView(row)}">${row.artifactId}</a></td>
-        <td><a href="#" data-bind="click: function(){artifactDetailView(row)}">${row.version}</a></td>
-        <td>${row.classifier}</td>
-      </tr>
-    {{/each}}
-    </tbody>
-</script>
-
-
-<script id="selected_repository_tmpl" type="text/html">
-  <select id="select_browse_repository" onchange="changeBrowseRepository()">
-    <option value="">All</option>
-    {{each(i,repository) repositories}}
-      {{if selected && selected==repository.id}}
-        <option value="${repository.id}" selected>${repository.name}</option>
-      {{else}}
-        <option value="${repository.id}">${repository.name}</option>
-      {{/if}}
-    {{/each}}
-  </select>
-</script>
-
-<script id="browse-artifact-detail-tmpl" type="text/html">
-    <ul id="artifact-details-tabs" class="nav nav-tabs">
-      <li class="active">
-        <a data-toggle="tab" href="#artifact-details-info-content">${$.i18n.prop('artifact.detail.tab.header.info')}</a>
-      </li>
-      <li>
-        <a data-toggle="tab" href="#artifact-details-dependencies-content">${$.i18n.prop('artifact.detail.tab.header.dependencies')}</a>
-      </li>
-      <li>
-        <a data-toggle="tab" href="#artifact-details-dependency-tree-content">${$.i18n.prop('artifact.detail.tab.header.dependency.tree')}</a>
-      </li>
-      <li>
-        <a data-toggle="tab" href="#artifact-details-used-by-content">${$.i18n.prop('artifact.detail.tab.header.used.by')}</a>
-      </li>
-      <li>
-        <a data-toggle="tab" href="#artifact-details-mailing-list-content">${$.i18n.prop('artifact.detail.tab.header.mailing.list')}</a>
-      </li>
-      <li>
-        <a data-toggle="tab" href="#artifact-details-metadatas-content">${$.i18n.prop('artifact.detail.tab.header.metadatas')}</a>
-      </li>
-    </ul>
-    <div class="tab-content">
-         <div id="artifact-details-info-content" class="tab-pane active">
-        <blockquote>${projectVersionMetadata.description}</blockquote>
-        <div class="row-fluid">
-          <div class="span6">
-            <table class="table">
-              <tbody>
-                <tr>
-                  <th>${$.i18n.prop('browse.artifact.groupId')}</th>
-                  <td>${groupId}</td>
-                </tr>
-                <tr>
-                  <th>${$.i18n.prop('browse.artifact.artifactId')}</th>
-                  <td>${artifactId}</td>
-                </tr>
-                <tr>
-                  <th>${$.i18n.prop('browse.artifact.version')}</th>
-                  <td>${version}</td>
-                </tr>
-                <tr>
-                  <th>${$.i18n.prop('browse.artifact.packaging')}</th>
-                  <td>${projectVersionMetadata.mavenFacet.packaging}</td>
-                </tr>
-                {{if projectVersionMetadata.mavenFacet.parent }}
-                <tr>
-                  <th>${$.i18n.prop('browse.artifact.parent')}</th>
-                  <td>
-                    <a href="#" data-bind="click: displayParent">
-                    ${projectVersionMetadata.mavenFacet.parent.groupId}:${projectVersionMetadata.mavenFacet.parent.artifactId}:${projectVersionMetadata.mavenFacet.parent.version}
-                    </a>
-                  </td>
-                </tr>
-                {{/if}}
-              </tbody>
-            </table>
-          </div>
-          <div class="span6">
-            <h4>${$.i18n.prop('browse.artifact.pom.snippet')}</h4>
-              <pre class="prettyprint">&lt;dependency&gt;<br/>&nbsp;&nbsp;&lt;groupId&gt;${groupId}&lt;/groupId&gt;<br/>&nbsp;&nbsp;&lt;artifactId&gt;${artifactId}&lt;/artifactId&gt;<br/>&nbsp;&nbsp;&lt;version&gt;${version}&lt;/version&gt;<br/>&lt;/dependency&gt;</pre>
-          </div>
-        </div>
-        <div>
-          <div class="page-header">
-            <h4>${$.i18n.prop('browse.artifact.other.details')}</h4>
-          </div>
-          <div>
-            <div class="row-fluid">
-              <div class="span9">
-                <table class="table">
-                  <tbody>
-                    {{if projectVersionMetadata.url}}
-                    <tr>
-                      <th>${$.i18n.prop('browse.artifact.url')}</th>
-                      <td><a href="${projectVersionMetadata.url}" target="_blank">${projectVersionMetadata.url}</a></td>
-                    </tr>
-                    {{/if}}
-                    {{if projectVersionMetadata.organization}}
-                    <tr>
-                      <th>${$.i18n.prop('browse.artifact.organization.name')}</th>
-                      {{if projectVersionMetadata.organization.url}}
-                        <td>
-                          <a href="${projectVersionMetadata.organization.url}" target="_blank">
-                            <img src="images/internet-web-browser.png" alt=""/>${projectVersionMetadata.organization.name}
-                          </a>
-                        </td>
-                      {{else}}
-                        <td>${projectVersionMetadata.organization.name}</td>
-                      {{/if}}
-                    </tr>
-                    {{/if}}
-                    {{each(i,license) projectVersionMetadata.licenses}}
-                    <tr>
-                      <th>${$.i18n.prop('browse.artifact.license')}</th>
-                      {{if license.url}}
-                        <td>
-                          <a href="${license.url}" target="_blank">
-                            <img src="images/internet-web-browser.png" alt=""/>${license.name}
-                          </a>
-                        </td>
-                      {{else}}
-                        <td>${license.name}</td>
-                      {{/if}}
-                      </tr>
-                    {{/each}}
-                    {{if projectVersionMetadata.issueManagement}}
-                    <tr>
-                      <th>${$.i18n.prop('browse.artifact.organization.issueManagement')}</th>
-                      <td>
-                        <a href="${projectVersionMetadata.issueManagement.url}" target="_blank">
-                          <img src="images/internet-web-browser.png" alt=""/>${projectVersionMetadata.issueManagement.system}
-                        </a>
-                      </td>
-                    </tr>
-                    {{/if}}
-                    {{if projectVersionMetadata.ciManagement}}
-                    <tr>
-                      <th>${$.i18n.prop('browse.artifact.organization.ciManagement')}</th>
-                      <td>
-                        <a href="${projectVersionMetadata.ciManagement.url}" target="_blank">
-                          <img src="images/internet-web-browser.png" alt=""/>${projectVersionMetadata.ciManagement.system}
-                        </a>
-                      </td>
-                    </tr>
-                    {{/if}}
-                  </tbody>
-                </table>
-              </div>
-            </div>
-          </div>
-        </div>
-        {{if projectVersionMetadata.scm}}
-        <div>
-          <div class="page-header">
-            <h4>${$.i18n.prop('browse.artifact.scm')}</h4>
-          </div>
-          <div>
-            <div class="row-fluid">
-              <div class="span12">
-                <table class="table">
-                  <tbody>
-                    <tr>
-                      <th>${$.i18n.prop('browse.artifact.scm.connection')}</th>
-                      <td>${projectVersionMetadata.scm.connection}</td>
-                    </tr>
-                    <tr>
-                      <th>${$.i18n.prop('browse.artifact.scm.devconnection')}</th>
-                      <td>${projectVersionMetadata.scm.developerConnection}</td>
-                    </tr>
-                    <tr>
-                      <th>${$.i18n.prop('browse.artifact.scm.viewer')}</th>
-                      <td>${projectVersionMetadata.scm.url}</td>
-                    </tr>
-                  </tbody>
-                </table>
-              </div>
-            </div>
-          </div>
-        </div>
-        {{/if}}
-         </div>
-
-
-         <div id="artifact-details-dependencies-content" class="tab-pane">
-        <table class="table">
-          <tbody>
-          {{if projectVersionMetadata.dependencies && projectVersionMetadata.dependencies.length>0}}
-          {{each(i,dependency) projectVersionMetadata.dependencies}}
-            <tr>
-              <th>${dependency.artifactId}</th>
-            </tr>
-            <tr>
-              <td>
-                {{var entries=dependency.crumbEntries()}}
-                {{each(j,crumbEntry) entries}}
-                  {{if j < entries.length - 2}}
-                    <a href="#" data-bind="click: function(){displayGroup(crumbEntry.groupId)}">${crumbEntry.displayValue}</a>
-                  {{else j == entries.length - 2}}
-                    <a href="#" data-bind="click: function(){displayArtifactDetailView(crumbEntry.groupId,crumbEntry.artifactId)}">${crumbEntry.displayValue}</a>
-                  {{else j == entries.length - 1}}
-                    &nbsp;|&nbsp;<b>${$.i18n.prop('browse.artifact.version')}:</b>&nbsp;
-                     <a href="#" data-bind="click: function(){displayArtifactVersionDetailViewModel(crumbEntry.groupId,crumbEntry.artifactId,crumbEntry.version)}">${dependency.version}</a>&nbsp;
-                  {{/if}}
-                  {{if j < entries.length - 2}}
-                     &nbsp;/&nbsp;
-                  {{/if}}
-                {{/each}}
-
-                {{if dependency.scope}}
-                  |&nbsp;<b>${$.i18n.prop('browse.artifact.scope')}:</b>&nbsp;${dependency.scope}
-                {{/if}}
-              </td>
-            </tr>
-          {{/each}}
-          {{else}}
-            ${$.i18n.prop('browse.artifact.dependencies.none')}
-          {{/if}}
-          </tbody>
-        </table>
-         </div>
-
-      <div id="artifact-details-dependency-tree-content" class="tab-pane">
-      </div>
-
-      <div id="artifact-details-used-by-content" class="tab-pane"></div>
-
-      <div id="artifact-details-mailing-list-content" class="tab-pane">
-        {{if projectVersionMetadata.mailingLists && projectVersionMetadata.mailingLists.length>0}}
-          <div id="accordion_mailing_lists" class="accordion">
-          {{each(i,mailingList) projectVersionMetadata.mailingLists}}
-            <div class="accordion-group">
-              <div class="accordion-heading">
-                <a class="accordion-toggle" href="#ml_collapse_${i}" data-parent="#accordion_mailing_lists" data-toggle="collapse">${mailingList.name}</a>
-              </div>
-              {{if i==0}}
-                <div id="ml_collapse_${i}" class="accordion-body collapse in">
-              {{else}}
-                <div id="ml_collapse_${i}" class="accordion-body collapse">
-              {{/if}}
-                <div class="accordion-inner">
-                  {{if mailingList.subscribeAddress}}
-                  <div>
-                    <b>${$.i18n.prop('browse.artifact.mailingList.subscribe')}</b>: <a href="mailto:${mailingList.subscribeAddress}">${mailingList.subscribeAddress}</a>
-                  </div>
-                  {{/if}}
-                  {{if mailingList.postAddress}}
-                  <div>
-                    <b>${$.i18n.prop('browse.artifact.mailingList.post')}</b>: <a href="mailto:${mailingList.postAddress}">${mailingList.postAddress}</a>
-                  </div>
-                  {{/if}}
-                  {{if mailingList.unsubscribeAddress}}
-                  <div>
-                    <b>${$.i18n.prop('browse.artifact.mailingList.unsubscribe')}</b>: <a href="mailto:${mailingList.unsubscribeAddress}">${mailingList.unsubscribeAddress}</a>
-                  </div>
-                  {{/if}}
-                  {{if mailingList.mainArchiveUrl}}
-                  <div>
-                    <b>${$.i18n.prop('browse.artifact.mailingList.mainArchiveUrl')}</b>: <a href="${mailingList.mainArchiveUrl}" target="_blank">${mailingList.mainArchiveUrl}</a>
-                  </div>
-                  {{/if}}
-                  {{if mailingList.otherArchives && mailingList.otherArchives.length>0}}
-                  <div>
-                    <b>${$.i18n.prop('browse.artifact.mailingList.otherArchivesUrls')}:</b>
-                    <ul>
-                    {{each(j,otherArchive) mailingList.otherArchives}}
-                      <li><b>${$.i18n.prop('browse.artifact.mailingList.otherArchiveUrl')}</b>: <a href="${otherArchive}" target="_blank">${otherArchive}</a></li>
-                    {{/each}}
-                    </ul>
-                  </div>
-                  {{/if}}
-                </div>
-              </div>
-            </div>
-          {{/each}}
-          </div>
-        {{else}}
-          ${$.i18n.prop('browse.artifact.mailingList.none')}
-        {{/if}}
-      </div>
-
-      <div id="artifact-details-metadatas-content" class="tab-pane">
-        <table class="table table-striped table-bordered" id="artifact-details-metadatas-content-table"
-               data-bind="simpleGrid: gridMetatadasViewModel,simpleGridTemplate:'artifact_metadata_properties_tmpl',pageLinksId:'artifactMetadata_Pagination'">
-
-        </table>
-        <div id="artifactMetadata_Pagination"></div>
-        {{if hasSavePropertyKarma()}}
-          <a href="#" class="btn btn-primary" data-bind="click: addProperty">${$.i18n.prop('browse.artifact.metadatas.add')}</a>
-        {{/if}}
-      </div>
-
-    </div>
-</script>
-
-<script id="dependency_tree_tmpl" type="text/html">
-  <ul>
-  {{each(i,treeEntry) treeEntries}}
-    <li>
-        {{var entries=treeEntry.artifact.crumbEntries()}}
-        {{each(j,crumbEntry) entries}}
-          {{if j < entries.length - 2}}
-            <a href="#" onclick="generalDisplayGroup(encodeURIComponent('${crumbEntry.groupId}'))">${crumbEntry.displayValue}</a>
-          {{else j == entries.length - 2}}
-            <a href="#" onclick="generalDisplayArtifactDetailView(encodeURIComponent('${crumbEntry.groupId}'),encodeURIComponent('${crumbEntry.artifactId}'))">${crumbEntry.displayValue}</a>
-          {{else j == entries.length - 1}}
-            &nbsp;|&nbsp;<b>${$.i18n.prop('browse.artifact.version')}:</b>&nbsp;
-             <a href="#" onclick="generalDisplayArtifactVersionDetailViewModel(encodeURIComponent('${crumbEntry.groupId}'),encodeURIComponent('${crumbEntry.artifactId}'),encodeURIComponent('${crumbEntry.version}'))">${crumbEntry.version}</a>&nbsp;
-          {{/if}}
-          {{if j < entries.length - 2}}
-             &nbsp;/&nbsp;
-          {{/if}}
-        {{/each}}
-    </li>
-    {{if treeEntry.childs.length>0}}
-      {{tmpl({treeEntries:treeEntry.childs}) "#dependency_tree_tmpl"}}
-    {{/if}}
-  {{/each}}
-  </ul>
-</script>
-
-<script id="dependees_tmpl" type="text/html">
-    <ul>
-    {{each(i,artifact) artifacts}}
-      <li>
-          {{var entries=artifact.crumbEntries()}}
-          {{each(j,crumbEntry) entries}}
-            {{if j < entries.length - 2}}
-              <a href="#" onclick="generalDisplayGroup(encodeURIComponent('${crumbEntry.groupId}'))">${crumbEntry.displayValue}</a>
-            {{else j == entries.length - 2}}
-              <a href="#" onclick="generalDisplayArtifactDetailView(encodeURIComponent('${crumbEntry.groupId}'),encodeURIComponent('${crumbEntry.artifactId}'))">${crumbEntry.displayValue}</a>
-            {{else j == entries.length - 1}}
-              &nbsp;|&nbsp;<b>${$.i18n.prop('browse.artifact.version')}:</b>&nbsp;
-               <a href="#" onclick="generalDisplayArtifactVersionDetailViewModel(encodeURIComponent('${crumbEntry.groupId}'),encodeURIComponent('${crumbEntry.artifactId}'),encodeURIComponent('${crumbEntry.version}'))">${crumbEntry.version}</a>&nbsp;
-            {{/if}}
-            {{if j < entries.length - 2}}
-               &nbsp;/&nbsp;
-            {{/if}}
-          {{/each}}
-      </li>
-    {{/each}}
-    </ul>
-</script>
-
-<script id="artifact_metadata_properties_tmpl" type="text/html">
-    <thead>
-      <tr>
-        <th title="${$.i18n.prop('browse.artifact.metadatas.key')}">${$.i18n.prop('browse.artifact.metadatas.key')}</th>
-        <th title="${$.i18n.prop('browse.artifact.metadatas.value')}">${$.i18n.prop('browse.artifact.metadatas.value')}</th>
-        <th title="${$.i18n.prop('browse.artifact.metadatas.delete')}">${$.i18n.prop('browse.artifact.metadatas.delete')}</th>
-        <th title="${$.i18n.prop('browse.artifact.metadatas.save')}">${$.i18n.prop('browse.artifact.metadatas.save')}</th>
-      </tr>
-
-    </thead>
-    <tbody>
-    {{each(i, row) itemsOnCurrentPage()}}
-      <tr>
-        {{if row.editable && hasSavePropertyKarma()}}
-          <td><input type="text" data-bind="value: row.key"/></td>
-        {{else}}
-          <td>${row.key}</td>
-        {{/if}}
-        <td>
-          {{if hasSavePropertyKarma()}}
-            <input type="text" data-bind="value: row.value"/>
-          {{else}}
-            ${row.value}
-          {{/if}}
-        </td>
-        <td>
-          {{if hasDeletePropertyKarma()}}
-          <a href="#" class="btn btn-danger" data-bind="click: function(){deleteProperty(row)}">${$.i18n.prop('browse.artifact.metadatas.delete')}</a>
-          {{/if}}
-        </td>
-        <td>
-          {{if row.modified && hasSavePropertyKarma()}}
-            <a href="#" class="btn btn-warning" data-bind="click: function(){saveProperty(row)}">${$.i18n.prop('browse.artifact.metadatas.save')}</a>
-          {{/if}}
-        </td>
-      </tr>
-    {{/each}}
-    </tbody>
-</script>
\ No newline at end of file
index 91ce0feb042d909e8302b5bb97a20e998746cbd1..e08ab110eb9d1447c0ed5e1c15b3d6eae24037cd 100644 (file)
  * specific language governing permissions and limitations
  * under the License.
  */
-define("redback-templates",["text!redback/templates/user-edit.html",
-          "text!redback/templates/user-grids.html",
-          "text!redback/templates/login.html",
-          "text!redback/templates/register-form.html",
-          "text!redback/templates/password-change-form.html",
-          "text!redback/templates/user-edit-form.html",
-          "text!redback/templates/roles-tmpl.html",
+define("redback-templates",["text!templates/redback/user-edit.html",
+          "text!templates/redback/user-grids.html",
+          "text!templates/redback/login.html",
+          "text!templates/redback/register-form.html",
+          "text!templates/redback/password-change-form.html",
+          "text!templates/redback/user-edit-form.html",
+          "text!templates/redback/roles-tmpl.html",
           "jquery_tmpl","utils"],
     function(useredit, usergrids, login,register,passwordchange,usereditform,roles) {
 
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/login.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/login.html
deleted file mode 100644 (file)
index 871d137..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one
-  ~ or more contributor license agreements.  See the NOTICE file
-  ~ distributed with this work for additional information
-  ~ regarding copyright ownership.  The ASF licenses this file
-  ~ to you under the Apache License, Version 2.0 (the
-  ~ "License"); you may not use this file except in compliance
-  ~ with the License.  You may obtain a copy of the License at
-  ~
-  ~   http://www.apache.org/licenses/LICENSE-2.0
-  ~
-  ~ Unless required by applicable law or agreed to in writing,
-  ~ software distributed under the License is distributed on an
-  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-  ~ KIND, either express or implied.  See the License for the
-  ~ specific language governing permissions and limitations
-  ~ under the License.
--->
-<div id="modal-login" class="modal hide fade">
-  <div class="modal-header">
-    <a href="#" class="close" data-dismiss="modal">&times;</a>
-    <h3>${$.i18n.prop('login.section.title')}</h3>
-  </div>
-  <div class="modal-body" id="modal-login-content">
-      <form id="user-login-form" class="form-horizontal">
-        <div id="modal-login-err-message" class="alert alert-error" style="display:none"></div>
-        <fieldset>
-          <div class="control-group">
-            <label class="control-label" for="user-login-form-username">${$.i18n.prop('username')}</label>
-            <div class="controls">
-              <input type="text" id="user-login-form-username" name="user-login-form-username" class="required" placeholder="${$.i18n.prop('login.username.placehoder')}"/>
-            </div>
-          </div>
-          <div class="control-group">
-            <label class="control-label" for="user-login-form-password">${$.i18n.prop('password')}</label>
-            <div class="controls">
-              <input type="password" id="user-login-form-password" name="user-login-form-password" class="required" placeholder="${$.i18n.prop('login.password.placehoder')}"/>
-            </div>
-          </div>
-        </fieldset>
-      </form>
-  </div>
-  <div class="modal-footer" id="modal-login-footer">
-    <button class="btn btn-primary" id="modal-login-ok">${$.i18n.prop('login')}</button>
-    <button class="btn btn-info" id="modal-login-password-reset">${$.i18n.prop('password.reset')}</button>
-  </div>
-</div>
-
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/password-change-form.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/password-change-form.html
deleted file mode 100644 (file)
index d682788..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one
-  ~ or more contributor license agreements.  See the NOTICE file
-  ~ distributed with this work for additional information
-  ~ regarding copyright ownership.  The ASF licenses this file
-  ~ to you under the Apache License, Version 2.0 (the
-  ~ "License"); you may not use this file except in compliance
-  ~ with the License.  You may obtain a copy of the License at
-  ~
-  ~   http://www.apache.org/licenses/LICENSE-2.0
-  ~
-  ~ Unless required by applicable law or agreed to in writing,
-  ~ software distributed under the License is distributed on an
-  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-  ~ KIND, either express or implied.  See the License for the
-  ~ specific language governing permissions and limitations
-  ~ under the License.
--->
-<div id="modal-password-change" class="modal hide fade">
-  <div class="modal-header">
-    <a href="#" class="close" data-dismiss="modal">&times;</a>
-    <h3>${$.i18n.prop('password.section.title')}</h3>
-  </div>
-  <div class="modal-body" id="modal-password-change-content">
-      <form id="password-change-form" class="form-horizontal">
-        <div id="modal-password-change-err-message" class="alert-message error" style="display:none"></div>
-        <fieldset>
-          <!-- part displayed only when a logged user want to change password will be hide when validate user registration -->
-          <div class="control-group" id="password-change-form-current-password-div">
-            <label class="control-label" for="password-change-form-current-password">${$.i18n.prop('password.existing')}</label>
-            <div class="controls">
-              <input type="password" id="password-change-form-current-password" name="password-change-form-current-password" class="required" value=""/>
-            </div>
-          </div>
-
-          <div class="control-group">
-            <label class="control-label" for="passwordChangeFormNewPassword">${$.i18n.prop('password.new')}</label>
-            <div class="controls">
-              <input type="password" id="passwordChangeFormNewPassword" name="passwordChangeFormNewPassword" class="required" value=""/>
-            </div>
-          </div>
-
-          <div class="control-group">
-            <label class="control-label"  for="passwordChangeFormNewPasswordConfirm">${$.i18n.prop('password.new.confirm')}</label>
-            <div class="controls">
-              <input type="password" id="passwordChangeFormNewPasswordConfirm" name="passwordChangeFormNewPasswordConfirm" class="required" value=""/>
-            </div>
-          </div>
-        </fieldset>
-      </form>
-  </div>
-  <div class="modal-footer" id="modal-password-change-footer">
-    <button class="btn btn-primary" onclick="return" id="modal-change-password-ok">${$.i18n.prop('ok')}</button>
-  </div>
-</div>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/register-form.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/register-form.html
deleted file mode 100644 (file)
index 931e72d..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one
-  ~ or more contributor license agreements.  See the NOTICE file
-  ~ distributed with this work for additional information
-  ~ regarding copyright ownership.  The ASF licenses this file
-  ~ to you under the Apache License, Version 2.0 (the
-  ~ "License"); you may not use this file except in compliance
-  ~ with the License.  You may obtain a copy of the License at
-  ~
-  ~   http://www.apache.org/licenses/LICENSE-2.0
-  ~
-  ~ Unless required by applicable law or agreed to in writing,
-  ~ software distributed under the License is distributed on an
-  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-  ~ KIND, either express or implied.  See the License for the
-  ~ specific language governing permissions and limitations
-  ~ under the License.
--->
-<div id="modal-register" class="modal hide fade">
-  <div class="modal-header">
-    <a href="#" class="close" data-dismiss="modal">&times;</a>
-    <h3>${$.i18n.prop('register.section.title')}</h3>
-  </div>
-  <div class="modal-body" id="modal-register-content">
-      <form id="user-register-form" class="form-horizontal">
-        <div id="modal-register-err-message" class="alert-message error" style="display:none"></div>
-        <fieldset>
-          <div class="control-group">
-            <label class="control-label" for="user-register-form-username">${$.i18n.prop('username')}</label>
-            <div class="controls">
-              <input type="text" id="user-register-form-username" name="user-register-form-username" class="required" />
-            </div>
-          </div>
-          <div class="control-group">
-            <label class="control-label" for="user-register-form-fullname">${$.i18n.prop('full.name')}</label>
-            <div class="controls">
-              <input type="text" id="user-register-form-fullname" name="user-register-form-fullname" class="required" />
-            </div>
-          </div>
-          <div class="control-group">
-            <label class="control-label" for="user-register-form-email">${$.i18n.prop('email')}</label>
-            <div class="controls">
-              <input type="text" id="user-register-form-email" name="user-register-form-email" class="required email" />
-            </div>
-          </div>
-
-        </fieldset>
-      </form>
-  </div>
-  <div class="modal-footer" id="modal-register-footer">
-      <button class="btn btn-primary" id="modal-register-ok">${$.i18n.prop('register')}</button>
-  </div>
-</div>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/roles-tmpl.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/roles-tmpl.html
deleted file mode 100644 (file)
index 7441949..0000000
+++ /dev/null
@@ -1,232 +0,0 @@
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one
-  ~ or more contributor license agreements.  See the NOTICE file
-  ~ distributed with this work for additional information
-  ~ regarding copyright ownership.  The ASF licenses this file
-  ~ to you under the Apache License, Version 2.0 (the
-  ~ "License"); you may not use this file except in compliance
-  ~ with the License.  You may obtain a copy of the License at
-  ~
-  ~   http://www.apache.org/licenses/LICENSE-2.0
-  ~
-  ~ Unless required by applicable law or agreed to in writing,
-  ~ software distributed under the License is distributed on an
-  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-  ~ KIND, either express or implied.  See the License for the
-  ~ specific language governing permissions and limitations
-  ~ under the License.
--->
-<script id="rolesTabs" type="text/html">
-  <div class="page-header">
-    <h2>${$.i18n.prop('roles.management.header')}</h2>
-  </div>
-
-  <ul id="roles-view-tabs" class="nav nav-tabs" data-target="roles-view-tabs-content">
-    <li class="active" id="roles-view-tabs-li-roles-grid">
-      <a data-toggle="tab" href="#roles-view" id="roles-view-tabs-a-roles-grid">${$.i18n.prop('roles.grid.tab.title')}</a>
-    </li>
-    <li id="roles-view-tabs-li-roles-edit">
-      <a data-toggle="tab" href="#role-edit">${$.i18n.prop('edit')}</a>
-    </li>
-  </ul>
-  <div id="roles-view-tabs-content" class="tab-content">
-    <div id="roles-view" class="tab-pane">
-        <div data-bind="style: { display: bulkSave() ? '' : 'none' }">
-          <a data-bind="click: updateModifiedRoles" class="btn btn-danger" href="#">${$.i18n.prop('save.all')}</a>
-          <br/>
-        </div>
-        <table class="table table-striped table-bordered" id="rolesTable"
-               data-bind="simpleGrid: gridViewModel,simpleGridTemplate:'ko_rolesGrid',pageLinksId:'rolesPagination'">
-        </table>
-        <div id="rolesPagination"></div>
-    </div>
-    <div id="role-edit" class="tab-pane" data-bind="template: {name:'editRoleTab',data: currentRole}"></div>
-  </div>
-
-</script>
-
-<script id="editRoleTab" type="text/html">
-  <div class="accordion" id="edit-role-accordion">
-    <div class="accordion-group">
-      <div class="accordion-heading">
-        <h3>
-          <a class="accordion-toggle" href="#role-collapse" data-parent="#edit-role-accordion" data-toggle="collapse">${$.i18n.prop('role')}</a>
-        </h3>
-      </div>
-      <div id="role-collapse" class="accordion-body collapse in">
-        <table class="table table-bordered" id="editRoleTable">
-          <tbody>
-            <tr>
-              <td>${$.i18n.prop('name')}:</td>
-              <td id="role-edit-name">${$data.name}</td>
-            </tr>
-            <tr>
-              <td>${$.i18n.prop('description')}:</td>
-              <td><input type="text" id="role-edit-description" data-bind="value: description"></td>
-            </tr>
-            <tr>
-              <td colspan="2">
-                <div class="pull-left">
-                  <button class="btn" id="role-edit-description-save" data-bind="click: saveRoleDescription">${$.i18n.prop('save')}</button>
-                </div>
-              </td>
-            </tr>
-          </tbody>
-        </table>
-
-        <div class="page-header">
-          <h3>${$.i18n.prop('role.model.parent.roles')}</h3>
-        </div>
-        {{if $data.parentRoleNames}}
-        <ul>
-          {{each $data.parentRoleNames}}
-            <li>${$value}</li>
-          {{/each}}
-        </ul>
-        {{/if}}
-
-        <div class="page-header">
-          <h3>${$.i18n.prop('role.model.child.roles')}</h3>
-        </div>
-        {{if $data.childRoleNames}}
-        <ul>
-          {{each $data.childRoleNames}}
-            <li>${$value}</li>
-          {{/each}}
-        </ul>
-        {{/if}}
-
-        <div class="page-header">
-          <h3>${$.i18n.prop('permissions')}</h3>
-        </div>
-        {{if $data.permissions}}
-          <table class="table table-striped table-bordered" id="rolePermissionsTable">
-            <thead>
-              <tr>
-                <th>${$.i18n.prop('name')}</th>
-                <th>${$.i18n.prop('role.operation')}</th>
-                <th>${$.i18n.prop('role.resource')}</th>
-              </tr>
-            </thead>
-            <tbody>
-              {{each permissions}}
-              <tr>
-                <td>${$value.name}</td>
-                {{if $value.operation }}
-                  <td>${$value.operation().name}</td>
-                {{else}}
-                  <td></td>
-                {{/if}}
-                {{if $value.resource }}
-                  <td>${$value.resource().identifier}</td>
-                {{else}}
-                  <td></td>
-                {{/if}}
-              </tr>
-             {{/each}}
-            </tbody>
-          </table>
-        {{/if}}
-      </div>
-    </div>
-    <div class="accordion-group>">
-      <div class="accordion-heading">
-        <h3>
-          <a class="accordion-toggle" href="#role-users-collapse" data-parent="#edit-role-accordion" data-toggle="collapse">${$.i18n.prop('role.edit.section.users')}</a>
-        </h3>
-      </div>
-      <div id="role-users-collapse" class="accordion-body collapse">
-        {{if $data.parentsRolesUsers}}
-        <div class="page-header">
-          <h3>${$.i18n.prop('role.edit.users.defined.in.parent.roles')}</h3>
-        </div>
-        <ul>
-        {{each $data.parentsRolesUsers}}
-          <li>${$value.fullName} - ( ${$value.username} - ${$value.email} ) </li>
-        {{/each}}
-        </ul>
-        {{/if}}
-
-        <ul id="role-edit-users-tabs" class="nav nav-tabs">
-          <li class="active" id="role-view-users-li">
-            <a data-toggle="tab" href="#role-view-users">${$.i18n.prop('role.edit.users.list')}</a>
-          </li>
-          <li id="role-edit-users-li">
-            <a data-toggle="tab" href="#role-edit-users">${$.i18n.prop('edit')}</a>
-          </li>
-        </ul>
-
-        <div class="pill-content" id="role-edit-users-tabs-content">
-          <div id="role-view-users" class="active pill-pane">
-            <div class="page-header">
-              <h3>${$.i18n.prop('role.edit.users.defined.in.current.role')}</h3>
-            </div>
-            <div id="role-list-users">
-              {{if users().length>0}}
-              <ul>
-                {{each(j, user) users()}}
-                <li>${user.fullName()} - ( ${user.username()} - ${user.email()} ) </li>
-                {{/each}}
-              </ul>
-              {{else}}
-                ${$.i18n.prop('role.edit.no.user.defined')}
-              {{/if}}
-            </div>
-          </div>
-
-          <div id="role-edit-users" class="clearfix ar-multiselect pill-pane">
-
-            <div class="ar-multiselect-column ar-multiselect-left">
-              <select data-bind="options: otherUsers ,optionsText: 'username',selectedOptions:selectedOtherUsers" multiple="true" id="role-edit-available-users"></select>
-            </div>
-            <div class="ar-multiselect-column ar-multiselect-center">
-              <ul style="list-style: none">
-                <li><input class="btn" id="role-edit-users-add-user" type="button" data-bind="click: addUser" value="&gt;"/></li>
-                <li><input class="btn" id="role-edit-users-remove-user" type="button" data-bind="click: removeUser" value="&lt;"/></li>
-              </ul>
-            </div>
-            <div class="ar-multiselect-column ar-multiselect-right">
-              <select data-bind="options: users ,optionsText: 'username',selectedOptions:selectedUsers" multiple="true" id="role-edit-affected-users"></select>
-            </div>
-            <button class="btn" id="role-edit-users-save" data-bind="click: saveUsers">${$.i18n.prop('save')}</button>
-          </div>
-        </div>
-      </div>
-    </div>
-  </div>
-</script>
-
-<script id='ko_rolesGrid' type='text/html'>
-  <thead>
-      <tr>
-        {{each(i, columnDefinition) columns}}
-          <th>${ columnDefinition.headerText }</th>
-        {{/each}}
-        <th>${$.i18n.prop('edit')}</th>
-        <th>${$.i18n.prop('save')}</th>
-      </tr>
-  </thead>
-  <tbody>
-      {{each(i, row) itemsOnCurrentPage()}}
-          <tr data-bind="css:{ 'modified': row.modified()||row.usersModified()}">
-              {{each(j, columnDefinition) columns}}
-              {{var val = (typeof columnDefinition.rowText == 'function' ? columnDefinition.rowText(row) : row[columnDefinition.rowText])}}
-              <td id="role-${columnDefinition.rowText}-${row.name()}">
-                ${val}
-              </td>
-              {{/each}}
-              <td>
-                <a id="edit-role-${row.name()}" href="#" data-bind="click: function(){ editRole(row) }">
-                  <img src="images/edit-find-22-22.png" title="${$.i18n.prop('edit')}">
-                </a>
-              </td>
-              <td>
-                {{if row.modified()}}
-                  <a href="#" class="btn btn-warning" data-bind="click: function(){ updateRole(row) }">${$.i18n.prop('save')}</a>
-                {{/if}}
-              </td>
-          </tr>
-      {{/each}}
-</script>
-
-
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/user-edit-form.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/user-edit-form.html
deleted file mode 100644 (file)
index 3df4d84..0000000
+++ /dev/null
@@ -1,72 +0,0 @@
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one
-  ~ or more contributor license agreements.  See the NOTICE file
-  ~ distributed with this work for additional information
-  ~ regarding copyright ownership.  The ASF licenses this file
-  ~ to you under the Apache License, Version 2.0 (the
-  ~ "License"); you may not use this file except in compliance
-  ~ with the License.  You may obtain a copy of the License at
-  ~
-  ~   http://www.apache.org/licenses/LICENSE-2.0
-  ~
-  ~ Unless required by applicable law or agreed to in writing,
-  ~ software distributed under the License is distributed on an
-  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-  ~ KIND, either express or implied.  See the License for the
-  ~ specific language governing permissions and limitations
-  ~ under the License.
--->
-<div id="modal-user-edit" class="modal hide fade">
-  <div class="modal-header">
-    <a href="#" class="close" data-dismiss="modal">&times;</a>
-    <h3>${$.i18n.prop('password.section.title')}</h3>
-  </div>
-  <div class="modal-body" id="modal-user-edit-content">
-      <form id="user-edit-form" class="form-horizontal">
-        <div id="modal-user-edit-err-message" class="alert-message error" style="display:none"></div>
-        <fieldset>
-          <div class="control-group">
-            <label class="control-label" for="username">${$.i18n.prop('username')}</label>
-            <div class="controls" id="username-div">
-              <span class="uneditable-input" id="username"></span>
-            </div>
-          </div>
-          <div class="control-group">
-            <label class="control-label" for="fullname">${$.i18n.prop('full.name')}</label>
-            <div class="controls">
-              <input type="text" id="fullname" name="fullname" size="30" class="required"/>
-            </div>
-          </div>
-          <div class="control-group">
-            <label class="control-label" for="email">${$.i18n.prop('email.address')}</label>
-            <div class="controls">
-              <input type="text" id="email" name="email" size="30" class="required email"/>
-            </div>
-          </div>
-          <div class="control-group" id="user-edit-form-current-password-div">
-            <label class="control-label" for="userEditFormCurrentPassword">${$.i18n.prop('password.existing')}</label>
-            <div class="controls">
-              <input type="password" id="userEditFormCurrentPassword" name="userEditFormCurrentPassword" class="required" value=""/>
-            </div>
-          </div>
-
-          <div class="control-group">
-            <label class="control-label" for="userEditFormNewPassword">${$.i18n.prop('password.new')}</label>
-            <div class="controls">
-              <input type="password" id="userEditFormNewPassword" name="userEditFormNewPassword" class="" value=""/>
-            </div>
-          </div>
-
-          <div class="control-group">
-            <label class="control-label" for="userEditFormNewPasswordConfirm">${$.i18n.prop('password.new.confirm')}</label>
-            <div class="controls">
-              <input type="password" id="userEditFormNewPasswordConfirm" name="userEditFormNewPasswordConfirm" class="" value=""/>
-            </div>
-          </div>
-        </fieldset>
-      </form>
-  </div>
-  <div class="modal-footer" id="modal-user-edit-footer">
-    <button class="btn primary" onclick="return" id="modal-user-edit-ok">${$.i18n.prop('ok')}</button>
-  </div>
-</div>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/user-edit.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/user-edit.html
deleted file mode 100644 (file)
index 674d297..0000000
+++ /dev/null
@@ -1,164 +0,0 @@
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one
-  ~ or more contributor license agreements.  See the NOTICE file
-  ~ distributed with this work for additional information
-  ~ regarding copyright ownership.  The ASF licenses this file
-  ~ to you under the Apache License, Version 2.0 (the
-  ~ "License"); you may not use this file except in compliance
-  ~ with the License.  You may obtain a copy of the License at
-  ~
-  ~   http://www.apache.org/licenses/LICENSE-2.0
-  ~
-  ~ Unless required by applicable law or agreed to in writing,
-  ~ software distributed under the License is distributed on an
-  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-  ~ KIND, either express or implied.  See the License for the
-  ~ specific language governing permissions and limitations
-  ~ under the License.
--->
-<script id='redback/user-edit-tmpl' type='text/html'>
-<div id="edit-user-details-pills">
-  <ul id="edit_user_details_pills_headers" class="nav nav-pills" data-target="#edit-user-details-pills-content">
-    <li class="active" id="user-view-detail-li">
-      <a data-toggle="tab" href="#user-create-div">${$.i18n.prop('edit')}</a>
-    </li>
-    <li id="user-edit-roles-edit-li">
-      <a data-toggle="tab" href="#user-edit-roles-edit">${$.i18n.prop('effective.roles.edit')}</a>
-    </li>
-  </ul>
-  <div class="pill-content" id="edit-user-details-pills-content">
-    <div id="user-create-div" class="active pill-pane">
-      <div class="row-fluid">
-        <div class="span8 columns">
-          <form id="user-create" class="well form-horizontal" data-bind="submit: save">
-            <fieldset id="user-create-fieldset">
-              <div class="control-group">
-                <label class="control-label" for="username">${$.i18n.prop('username')}</label>
-                <div class="controls" id="username-div">
-                  {{if $data.username.length>0}}
-                    <span class="uneditable-input">${$data.username}</span>
-                  {{else}}
-                    <input type="text" id="username" name="username" size="30" class="required" data-bind="value: username"/>
-                  {{/if}}
-                </div>
-              </div>
-              <div class="control-group">
-                <label class="control-label" for="fullname">${$.i18n.prop('full.name')}</label>
-                <div class="controls">
-                  <input type="text" id="fullname" name="fullname" size="30" class="required" data-bind="value: fullName"/>
-                </div>
-              </div>
-              <div class="control-group">
-                <label class="control-label" for="password">${$.i18n.prop('password')}</label>
-                <div class="controls">
-                  <input type="password" id="password" name="password" class="required" data-bind="value: password"/>
-                </div>
-              </div>
-              <div class="control-group">
-                <label class="control-label" for="confirmPassword">${$.i18n.prop('confirm.password')}</label>
-                <div class="controls">
-                  <input type="password" id="confirmPassword" name="confirmPassword" data-bind="value: confirmPassword"/>
-                </div>
-              </div>
-              <div class="control-group">
-                <label class="control-label" for="email">${$.i18n.prop('email.address')}</label>
-                <div class="controls">
-                  <input type="text" id="email" name="email" class="required email" data-bind="value: email"/>
-                </div>
-              </div>
-              <div class="control-group">
-                <label class="control-label" for="validated">${$.i18n.prop('validated')}</label>
-                <div class="controls">
-                  <input type="checkbox" id="validated" name="validated" data-bind="checked: validated"/>
-                </div>
-              </div>
-              <div class="control-group">
-                <label class="control-label" for="locked">${$.i18n.prop('locked')}</label>
-                <div class="controls">
-                  <input type="checkbox" id="locked" name="locked" data-bind="checked: locked"/>
-                </div>
-              </div>
-              <div class="control-group">
-                <label class="control-label" for="passwordChangeRequired">${$.i18n.prop('user.change.password.required')}</label>
-                <div class="controls">
-                  <input type="checkbox" id="passwordChangeRequired" name="passwordChangeRequired" data-bind="checked: passwordChangeRequired"/>
-                </div>
-              </div>
-            </fieldset>
-            <button data-bind="click: saveUser" class="btn" id="user-create-form-register-button">${$.i18n.prop('save')}</button>
-            <button class="btn" id="user-create-form-cancel-button">${$.i18n.prop('cancel')}</button>
-          </form>
-        </div>
-        <div class="span4 columns" id="user-edit-roles">
-          <div id="user-edit-roles-view"></div>
-        </div>
-      </div>
-    </div>
-
-    <div id="user-edit-roles-edit" class="pill-pane">
-      roles edit
-    </div>
-  </div>
-</div>
-</script>
-
-<script id="user_view_roles_list_tmpl" type="text/html">
-  <div class="page-header">
-    <h3>${$.i18n.prop('effective.roles')}</h3>
-  </div>
-  <div>
-    <ul>
-      {{each $data.user.assignedRoles}}
-        <li>${$value}</li>
-      {{/each}}
-    </ul>
-  </div>
-</script>
-
-<script id="user_edit_roles_tmpl" type="text/html">
-
-  <div>
-    {{each $data.applicationRoles}}
-      <div class="page-header">
-        <h3>${$value.name}</h3>
-      </div>
-      <blockquote>
-        <p>${$value.description}</p>
-      </blockquote>
-      <ul>
-      {{each $value.globalRoles}}
-        <li><input type="checkbox" value="${$value}" data-bind="checked: user.assignedRoles">&nbsp;${$value}</input></li>
-      {{/each}}
-      </ul>
-
-      {{if roleTemplates}}
-      <table class="bordered-table">
-        <thead>
-          <tr>
-            <th>&nbsp;</th>
-            {{each roleTemplates}}
-              <th>${$value.namePrefix}</th>
-            {{/each}}
-          </tr>
-        </thead>
-        <tbody>
-          {{each resources}}
-            {{var curResource = $value}}
-            <tr>
-              <td>${curResource}</td>
-              {{each roleTemplates}}
-                <td><input type="checkbox" value="${$value.namePrefix}${$value.delimiter}${curResource}" data-bind="checked: user.assignedRoles"/></td>
-              {{/each}}
-            </tr>
-          {{/each}}
-        </tbody>
-      </table>
-      {{/if}}
-
-    {{/each}}
-
-    <button class="btn" data-bind="click:updateUserRoles">${$.i18n.prop('update')}</button>
-
-  </div>
-</script>
-
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/user-grids.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/redback/templates/user-grids.html
deleted file mode 100644 (file)
index 0b50cda..0000000
+++ /dev/null
@@ -1,119 +0,0 @@
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one
-  ~ or more contributor license agreements.  See the NOTICE file
-  ~ distributed with this work for additional information
-  ~ regarding copyright ownership.  The ASF licenses this file
-  ~ to you under the Apache License, Version 2.0 (the
-  ~ "License"); you may not use this file except in compliance
-  ~ with the License.  You may obtain a copy of the License at
-  ~
-  ~   http://www.apache.org/licenses/LICENSE-2.0
-  ~
-  ~ Unless required by applicable law or agreed to in writing,
-  ~ software distributed under the License is distributed on an
-  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-  ~ KIND, either express or implied.  See the License for the
-  ~ specific language governing permissions and limitations
-  ~ under the License.
--->
-<script id='ko_usersGrid_grid' type='text/html'>
-  <thead>
-      <tr>
-        {{each(i, columnDefinition) columns}}
-          <th>${ columnDefinition.headerText }</th>
-        {{/each}}
-        <th>${$.i18n.prop('edit')}</th>
-        <th>${$.i18n.prop('delete')}</th>
-        <th>${$.i18n.prop('user.list.locked')}</th>
-        <th>${$.i18n.prop('user.change.password.required')}</th>
-      </tr>
-  </thead>
-  <tbody>
-      {{each(i, row) itemsOnCurrentPage()}}
-        <tr data-bind="css:{ 'modified': row.modified()}">
-          {{each(j, columnDefinition) columns}}
-          <td>${ typeof columnDefinition.rowText == 'function' ? columnDefinition.rowText(row) : row[columnDefinition.rowText] }</td>
-          {{/each}}
-          <td id="users-grid-user-id-${row.username()}">
-            <a href="#" data-bind="click: function(){ editUserBox(row) }">
-              <img src="images/edit-find-22-22.png" title="${$.i18n.prop('edit')}">
-            </a>
-          </td>
-          {{if row.username()=="admin" || row.username()=="guest"}}
-            <td></td>
-          {{else}}
-            <td>
-              <a href="#" data-bind="click: function(){ deleteUser(row) }" id="users-grid-delete-${row.username()}">
-                <img src="images/edit-cut-22-22.png" alt="${$.i18n.prop('delete')}"/>
-              </a>
-            </td>
-          {{/if}}
-          {{if row.username()=="admin"}}
-            <td></td>
-          {{else}}
-            {{if row.locked()==true}}
-              <td>
-                <a href="#" data-bind="click: function(){ unlock(row) }"><img src="images/system-lock-screen-22-22.png"/></a>
-              </td>
-            {{else}}
-              <td>
-                <a href="#" data-bind="click: function(){ lock(row) }"><img src="images/weather-clear-22-22.png"/></a>
-              </td>
-            {{/if}}
-          {{/if}}
-          {{if row.username()=="admin"}}
-            <td></td>
-          {{else}}
-            {{if row.passwordChangeRequired()==true}}
-              <td>
-                <a href="#" data-bind="click: function(){ passwordChangeRequire(row,false) }">
-                  <img src="images/dialog-error-22-22.png"/>
-                </a>
-              </td>
-            {{else}}
-            <td>
-              <a href="#" data-bind="click: function(){ passwordChangeRequire(row,true) }">
-                <img src="images/weather-clear-22-22.png"/>
-              </a>
-            </td>
-            {{/if}}
-          {{/if}}
-        </tr>
-      {{/each}}
-  </tbody>
-
-</script>
-
-<script id="usersGrid"  type="text/html">
-    <div class="page-header">
-      <h3><img src="images/system-users-32-32.png"/>${$.i18n.prop('users.list')}</h3>
-    </div>
-    <ul id="users-view-tabs" class="nav nav-tabs" data-target="#users-view-tabs-content">
-      <li class="active" id="users-view-tabs-li-users-grid">
-        <a data-toggle="tab" href="#users-view">${$.i18n.prop('users.grid.tab.title')}</a>
-      </li>
-      <li id="users-view-tabs-li-user-edit">
-        <a data-toggle="tab" href="#createUserForm" id="users-view-tabs-li-user-edit-a">${$.i18n.prop('add')}</a>
-      </li>
-    </ul>
-    <div id="users-view-tabs-content" class="tab-content">
-      <div id="users-view" class="tab-pane">
-        <button data-bind='click: sortByName'  class="btn">
-            ${$.i18n.prop('users.sort.byname')}
-        </button>
-        <table class="table table-striped table-bordered" id="usersTable"
-               data-bind="simpleGrid: gridViewModel,simpleGridTemplate:'ko_usersGrid_grid',pageLinksId:'usersPagination'">
-        </table>
-        <div id="usersPagination"></div>
-      </div>
-      <div id="createUserForm" class="tab-pane"></div>
-    </div>
-</script>
-
-<script id="user-delete-warning-tmpl" type='text/html'>
-    <div>
-      <span class="label label-warning">${$.i18n.prop('warning.not.undone.operation')}</span>
-    </div>
-</script>
-
-
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/general-admin.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/general-admin.html
new file mode 100644 (file)
index 0000000..ff5ea23
--- /dev/null
@@ -0,0 +1,509 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+-->
+<script id="legacy-artifact-path-main" type="text/html">
+ <div id="legacy-artifact-path-screen">
+     <div class="page-header">
+       <h2>${$.i18n.prop('legacy-artifact-paths.list')}</h2>
+     </div>
+
+     <ul id="legacy-artifact-paths-view-tabs" class="nav nav-tabs">
+       <li id="legacy-artifact-paths-view-tabs-li-grid">
+         <a data-toggle="tab" href="#legacy-artifact-paths-view" id="legacy-artifact-paths-view-tabs-a-grid">${$.i18n.prop('legacy-artifact-paths.grid.tab.title')}</a>
+       </li>
+       <li id="legacy-artifact-paths-view-tabs-li-edit">
+         <a data-toggle="tab" href="#legacy-artifact-paths-edit">${$.i18n.prop('add')}</a>
+       </li>
+     </ul>
+     <div id="legacy-artifact-paths-view-tabs-content" class="tab-content">
+       <div id="legacy-artifact-paths-view" class="tab-pane">
+           <table class="table table-striped table-bordered" id="legacy-artifact-paths-table"
+                  data-bind="simpleGrid: gridViewModel,simpleGridTemplate:'ko-legacy-artifact-paths-grid',pageLinksId:'legacy-artifact-pathsPagination'">
+           </table>
+           <div id="legacy-artifact-pathsPagination"></div>
+       </div>
+       <div id="legacy-artifact-paths-edit" class="tab-pane" data-bind='template: {name:"legacy-artifact-paths-edit-tmpl"}'></div>
+     </div>
+ </div>
+</script>
+
+<script id='ko-legacy-artifact-paths-grid' type='text/html'>
+    <thead>
+    <tr>
+        {{each(i, columnDefinition) columns}}
+        <th>${ columnDefinition.headerText }</th>
+        {{/each}}
+        <th>${$.i18n.prop('delete')}</th>
+    </tr>
+    </thead>
+    <tbody>
+    {{each(i, row) itemsOnCurrentPage()}}
+      <tr data-bind="css:{ 'modified': row.modified()}">
+        {{each(j, columnDefinition) columns}}
+        {{var val = (typeof columnDefinition.rowText == 'function' ? columnDefinition.rowText(row) : row[columnDefinition.rowText])}}
+          <td>
+              ${val}
+          </td>
+        {{/each}}
+          <td>
+            <a href="#" data-bind="click: function(){ removeLegacyArtifactPath(row) }">
+              <img src="images/edit-cut.png" title="${$.i18n.prop('delete')}"/>
+            </a>
+          </td>
+    </tr>
+    {{/each}}
+    </tbody>
+
+</script>
+
+<script id="legacy-artifact-paths-edit-tmpl" type="text/html">
+    <form id="legacy-artifact-paths-edit-form" class="well form-horizontal">
+      <fieldset id="legacy-artifact-paths-edit-fieldset">
+        <div class="control-group">
+          <label class="control-label" for="groupId">${$.i18n.prop('legacy-artifact-paths.groupId')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge required" id="groupId" name="groupId" size="8"
+                   data-bind="value: legacyArtifactPath.groupId"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="artifactId">${$.i18n.prop('legacy-artifact-paths.artifactId')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge required" id="artifactId" name="artifactId" size="8"
+                   data-bind="value: legacyArtifactPath.artifactId"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="version">${$.i18n.prop('legacy-artifact-paths.version')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge required" id="version" name="version" size="8"
+                   data-bind="value: legacyArtifactPath.version"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="classifier">${$.i18n.prop('legacy-artifact-paths.classifier')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge" id="classifier" name="classifier" size="8"
+                   data-bind="value: legacyArtifactPath.classifier"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="type">${$.i18n.prop('legacy-artifact-paths.type')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge required" id="type" name="type" size="8"
+                   data-bind="value: legacyArtifactPath.type"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="path">${$.i18n.prop('legacy-artifact-paths.path')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge required" id="path" name="path" size="8"
+                   data-bind="value: legacyArtifactPath.path"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="artifact">${$.i18n.prop('legacy-artifact-paths.artifact')}</label>
+          <div class="controls">
+            <span title="calculated from values" class="uneditable-input"
+                  id="artifact" data-bind="text: legacyArtifactPath.artifact"></span>
+          </div>
+        </div>
+
+      </fieldset>
+      <button id="network-proxy-btn-save" data-bind="click: save" class="btn">${$.i18n.prop('save')}</button>
+      <button id="network-proxy-btn-cancel" data-bind="click: displayGrid" class="btn">${$.i18n.prop('cancel')}</button>
+      <button id="network-proxy-btn-calculate-path" data-bind="click: calculatePath" class="btn btn-success">${$.i18n.prop('legacy-artifact-paths.calculatePath')}</button>
+    </form>
+</script>
+
+<script id="legacy-artifact-path-delete-warning-tmpl" type="text/html">
+    <div>
+      <span class="label label-warning">${$.i18n.prop('warning.not.undone.operation')}</span>
+    </div>
+</script>
+
+<script id="repository-scanning-main" type="text/html">
+  <div id="repository-scanning-screen">
+    <div class="page-header">
+      <h2>${$.i18n.prop('repository-scanning.head')}</h2>
+    </div>
+  </div>
+
+  <ul id="repositories-tabs" class="nav nav-tabs">
+    <li class="active">
+      <a data-toggle="tab" href="#file-types-content">${$.i18n.prop('repository-scanning.file-types.head')}</a>
+    </li>
+    <li>
+      <a data-toggle="tab" href="#consumers-content">${$.i18n.prop('repository-scanning.consumers.head')}</a>
+    </li>
+  </ul>
+
+  <div class="tab-content">
+    <div id="file-types-content" class="tab-pane active" data-bind='template: {name:"file-types-tmpl"}'>
+    </div>
+    <div id="consumers-content" class="tab-pane">
+      <div id="consumers-known-content" data-bind='template: {name:"consumers-known-content-tmpl"}'></div>
+      <div id="consumers-invalid-content" data-bind='template: {name:"consumers-invalid-content-tmpl"}'></div>
+    </div>
+  </div>
+
+</script>
+
+<script id="file-types-tmpl" type="text/html">
+<div class="accordion" id="accordion-file-types">
+  <div class="span4">
+  {{each(i, fileType) fileTypes}}
+  <div class="accordion-group">
+    <div class="accordion-heading">
+      <a class="accordion-toggle" href="#collapse-pattern-${fileType.id}"
+         data-parent="#accordion-file-types" data-toggle="collapse">${fileType.id}&nbsp;<i class="icon-resize-vertical"/></a>
+    </div>
+    <div id="collapse-pattern-${fileType.id}" class="accordion-body collapse">
+    <table class="table table-condensed">
+      {{each(j,pattern) fileType.patterns}}
+      <tr>
+        <td>${pattern}</td>
+        <td>
+          <a href="#" data-bind="click: function(){ removeFileTypePattern(fileType.id(),pattern) }">
+            <img src="images/edit-cut-22-22.png" title="${$.i18n.prop('delete')}"/>
+          </a>
+        </td>
+      </tr>
+      {{/each}}
+      <tr>
+        <td><input type="text" id="pattern-${fileType.id}"/></td>
+        <td>
+          <a href="#" data-bind="click: function(){addFileTypePattern(fileType.id())}">
+            <img src="images/list-add-22-22.png" title="${$.i18n.prop('add')}"/>
+          </a>
+        </td>
+      </tr>
+    </table>
+    </div>
+  </div>
+  {{/each}}
+  </div>
+</div>
+</script>
+
+<script id="consumers-known-content-tmpl" type="text/html">
+  <div class="page-header">
+    <h4>${$.i18n.prop('repository-scanning.consumers.know-content.head')}</h4>
+  </div>
+  <table class="table table-condensed">
+    <thead>
+      <tr>
+        <th>${$.i18n.prop('repository-scanning.consumers.grid.enabled')}</th>
+        <th>${$.i18n.prop('repository-scanning.consumers.grid.id')}</th>
+        <th>${$.i18n.prop('repository-scanning.consumers.grid.description')}</th>
+      </tr>
+    </thead>
+    <tbody>
+      {{each(i,knownAdminRepositoryConsumer) knownAdminRepositoryConsumers}}
+      <tr>
+        {{if knownAdminRepositoryConsumer.enabled()==true}}
+          <td>
+            <a href="#" data-bind="click: function(){ disableKnowContentConsumer(knownAdminRepositoryConsumer) }">
+              <img src="images/weather-clear-22-22.png"/>
+            </a>
+          </td>
+          {{else}}
+          <td>
+            <a href="#" data-bind="click: function(){ enableKnowContentConsumer(knownAdminRepositoryConsumer) }">
+              <img src="images/dialog-error-22-22.png"/>
+            </a>
+          </td>
+        {{/if}}
+
+        <td>${knownAdminRepositoryConsumer.id}</td>
+        <td>${knownAdminRepositoryConsumer.description}</td>
+      </tr>
+      {{/each}}
+    </tbody>
+  </table>
+</script>
+
+<script id="consumers-invalid-content-tmpl" type="text/html">
+  <div class="page-header">
+    <h4>${$.i18n.prop('repository-scanning.consumers.invalid-content.head')}</h4>
+  </div>
+  <table class="table table-condensed">
+    <thead>
+      <tr>
+        <th>${$.i18n.prop('repository-scanning.consumers.grid.enabled')}</th>
+        <th>${$.i18n.prop('repository-scanning.consumers.grid.id')}</th>
+        <th>${$.i18n.prop('repository-scanning.consumers.grid.description')}</th>
+      </tr>
+    </thead>
+    <tbody>
+      {{each(i,invalidAdminRepositoryConsumer) invalidAdminRepositoryConsumers}}
+      <tr>
+        {{if invalidAdminRepositoryConsumer.enabled()==true}}
+          <td>
+            <a href="#" data-bind="click: function(){ disableInvalidContentConsumer(invalidAdminRepositoryConsumer) }">
+              <img src="images/weather-clear-22-22.png"/>
+            </a>
+          </td>
+          {{else}}
+          <td>
+            <a href="#" data-bind="click: function(){ enableInvalidContentConsumer(invalidAdminRepositoryConsumer) }">
+              <img src="images/dialog-error-22-22.png"/>
+            </a>
+          </td>
+        {{/if}}
+        <td>${invalidAdminRepositoryConsumer.id}</td>
+        <td>${invalidAdminRepositoryConsumer.description}</td>
+      </tr>
+      {{/each}}
+    </tbody>
+  </table>
+</script>
+
+<script id="network-configuration-screen" type="text/html">
+  <div class="page-header">
+    <h3>${$.i18n.prop('network-configuration.header')}</h3>
+  </div>
+  <div id="network-configuration-form" data-bind='template: {name:"network-configuration-form-tmpl"}'></div>
+</script>
+
+<script id="network-configuration-form-tmpl" type="text/html">
+    <form id="network-proxy-edit-form" class="well form-horizontal">
+      <fieldset id="network-proxy-edit-fieldset">
+        <div class="control-group">
+          <label class="control-label" for="maxTotal">${$.i18n.prop('network-configuration.maxTotal')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge required digits" id="maxTotal" name="maxTotal" size="8"
+                   data-bind="value: networkConfiguration().maxTotal"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="maxTotal">${$.i18n.prop('network-configuration.maxTotalPerHost')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge required digits" id="maxTotalPerHost" name="maxTotalPerHost" size="8"
+                   data-bind="value: networkConfiguration().maxTotalPerHost"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="usePooling">${$.i18n.prop('network-configuration.usePooling')}</label>
+          <div class="controls">
+            <input type="checkbox" id="usePooling" name="usePooling" data-bind="checked: networkConfiguration().usePooling"/>
+          </div>
+        </div>
+      </fieldset>
+      <button id="network-configuration-btn-save" data-bind="click: save" class="btn">${$.i18n.prop('save')}</button>
+    </form>
+</script>
+
+<script id="system-status-main" type="text/html">
+
+  <div class="page-header">
+    <h3>${$.i18n.prop('system-status.header.main')}&nbsp;<a href="#" onclick="refreshSystemStatus()"><img src="images/view-refresh-22-22.png"/></a></h3>
+  </div>
+  <div class="page-header">
+    <h4>${$.i18n.prop('system-status.header.queues')}</h4>
+  </div>
+  <div id="status_queues">
+    <img src="images/small-spinner.gif"/>
+  </div>
+
+  <div class="page-header">
+    <h4>${$.i18n.prop('system-status.header.scanning')}&nbsp;<a href="#" onclick="displayScanningStats()"><img src="images/view-refresh.png"/></a></h4>
+  </div>
+  <div id="status_scanning">
+    <img src="images/small-spinner.gif"/>
+  </div>
+
+  <div class="page-header">
+    <h4>${$.i18n.prop('system-status.header.caches')}&nbsp;<a href="#" onclick="displayCacheEntries()"><img src="images/view-refresh.png"/></a></h4>
+  </div>
+  <div id="status_caches">
+      <img src="images/small-spinner.gif"/>
+  </div>
+
+  <div class="page-header">
+    <h4>${$.i18n.prop('system-status.header.memory')}&nbsp;<a href="#" onclick="displayMemoryUsage()"><img src="images/view-refresh.png"/></a></h4>
+  </div>
+  <div id="status_memory_info">
+    <img src="images/small-spinner.gif"/>
+  </div>
+
+  <div class="page-header">
+    <h4>${$.i18n.prop('system-status.header.current.time')}</h4>
+  </div>
+  <div id="status_current_time">
+    <img src="images/small-spinner.gif"/>
+  </div>
+
+  <div class="page-header">
+    <h4>${$.i18n.prop('system-status.header.version.info')}</h4>
+  </div>
+  <div id="status_version_info">
+    <img src="images/small-spinner.gif"/>
+  </div>
+
+</script>
+
+<script id="status_caches_tmpl" type="text/html">
+  <a href="#" class="btn btn-warning" onclick="flushAllCaches()">
+    ${$.i18n.prop('system-status.caches.flushAll')}
+  </a>
+  <table class="table table-condensed">
+    <thead>
+      <tr>
+        <th>${$.i18n.prop('system-status.caches.grid.header.key')}</th>
+        <th>${$.i18n.prop('system-status.caches.grid.header.size')}</th>
+        <th>${$.i18n.prop('system-status.caches.grid.header.cacheHits')}</th>
+        <th>${$.i18n.prop('system-status.caches.grid.header.cacheMiss')}</th>
+        <th>${$.i18n.prop('system-status.caches.grid.header.cacheHitRate')}</th>
+        <th>${$.i18n.prop('system-status.caches.grid.header.flush')}</th>
+      </tr>
+    </thead>
+    <tbody>
+    {{each(i,cacheEntry) cacheEntries}}
+      <tr>
+        <td>${cacheEntry.key}</td>
+        <td>${cacheEntry.size}</td>
+        <td>${cacheEntry.cacheHits}</td>
+        <td>${cacheEntry.cacheMiss}</td>
+        <td>${cacheEntry.cacheHitRate}</td>
+        <td>
+          <a href="#" onclick="flushCache('${cacheEntry.key}')">
+            {{if  cacheEntry.size > 0 }}
+              <img src="images/user-trash-full.png"/>
+            {{else}}
+              <img src="images/user-trash.png"/>
+            {{/if}}
+          </a>
+        </td>
+      </tr>
+    {{/each}}
+    </tbody>
+  </table>
+</script>
+
+
+<script id="status_queues_tmpl" type="text/html">
+  <table class="table table-condensed">
+    <thead>
+      <tr>
+        <th>${$.i18n.prop('system-status.queues.grid.header.key')}</th>
+        <th>${$.i18n.prop('system-status.queues.grid.header.size')}</th>
+      </tr>
+    </thead>
+    <tbody>
+    {{each(i,queueEntry) queueEntries}}
+      <tr>
+        <td>${queueEntry.key}</td>
+        <td>${queueEntry.entriesNumber}</td>
+      </tr>
+    {{/each}}
+    </tbody>
+  </table>
+</script>
+
+<script id="status_scanning_tmpl" type="text/html">
+  {{if repositoryScannerStatisticsList.length == 0}}
+    <h5>No scans in progress.</h5>
+  {{else}}
+    <table class="table table-condensed">
+      <thead>
+        <tr>
+          <th>${$.i18n.prop('system-status.scanning.grid.header.repository')}</th>
+          <th>${$.i18n.prop('system-status.scanning.grid.header.files.processed')}</th>
+          <th>${$.i18n.prop('system-status.scanning.grid.header.files.new')}</th>
+          <th>${$.i18n.prop('system-status.scanning.grid.header.stats')}</th>
+        </tr>
+      </thead>
+      <tbody>
+      {{each(i,repositoryScannerStatistics) repositoryScannerStatisticsList}}
+        <tr>
+          <td>${repositoryScannerStatistics.managedRepository.name()}</td>
+          <td>${repositoryScannerStatistics.totalFileCount}</td>
+          <td>${repositoryScannerStatistics.newFileCount}</td>
+          <td>
+            <blockquote>
+            <table>
+              <thead>
+                <tr>
+                  <th>${$.i18n.prop('system-status.scanning.consumers.grid.header.name')}</th>
+                  <th>${$.i18n.prop('system-status.scanning.consumers.grid.header.total')}</th>
+                  <th>${$.i18n.prop('system-status.scanning.consumers.grid.header.average')} ms</th>
+                  <th>${$.i18n.prop('system-status.scanning.consumers.grid.header.invocations.time')}</th>
+                </tr>
+              </thead>
+              <tbody>
+                {{each(j,consumerScanningStatistics) repositoryScannerStatistics.consumerScanningStatisticsList}}
+                <tr>
+                  <td>${consumerScanningStatistics.consumerKey}</td>
+                  <td>${consumerScanningStatistics.count}</td>
+                  <td>${consumerScanningStatistics.average}ms</td>
+                  <td>${consumerScanningStatistics.time}ms</td>
+                </tr>
+                {{/each}}
+              </tbody>
+            </table>
+            </blockquote>
+          </td>
+        </tr>
+      {{/each}}
+      </tbody>
+    </table>
+  {{/if}}
+</script>
+
+<script id="changeAppearance" type="text/html">
+    <div class="page-header">
+        <h2>${$.i18n.prop('appearance-configuration.title-page')}</h2>
+    </div>
+
+    <h2>${$.i18n.prop('appearance-configuration.organisation-details')}</h2>
+
+    <p>
+        ${$.i18n.prop('apperance-configuration.details-description')}
+    </p>
+    
+    <form id="appearance-configuration-form-id" class="well form-horizontal">
+        <fieldset id="appearance-configuration-fielset-id">
+            <div class="control-group">
+                <label class="control-label" for="name">${$.i18n.prop('appearance-configuration.name-label')}</label>
+                <div class="controls">
+                    <input type="text" class="xlarge required" id="name" name="name" size="50"
+                           data-bind="value: organisationInformation().name"/>
+                </div>
+            </div>
+            <div class="control-group">
+                <label class="control-label" for="name">${$.i18n.prop('appearance-configuration.url-label')}</label>
+                <div class="controls">
+                    <input type="text" class="xlarge required" id="url" name="url" size="50"
+                           data-bind="value: organisationInformation().url"/>
+                </div>
+            </div>
+            <div class="control-group">
+                <label class="control-label"
+                       for="name">${$.i18n.prop('appearance-configuration.logoLocation-label')}</label>
+                <div class="controls">
+                    <input type="text" class="xlarge" id="logoLocation" name="logoLocation" size="50"
+                           data-bind="value: organisationInformation().logoLocation"/>
+                </div>
+            </div>
+        </fieldset>
+        <button id="appearance-configuration-btn-save" data-bind="click: save" class="btn">${$.i18n.prop('save')}</button>
+    </form>
+</script>
+
+
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/grids-generics.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/grids-generics.html
new file mode 100644 (file)
index 0000000..0f94a83
--- /dev/null
@@ -0,0 +1,31 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+-->
+<script id="ko_simpleGrid_pageLinks" type="text/html">
+  <div class="pagination">
+      <ul>
+      {{each(i) ko.utils.range(1, maxPageIndex)}}
+          <li data-bind="css: { active: i == currentPageIndex() }">
+            <a href="#" data-bind="click: function() { currentPageIndex(i) }">
+              ${ i + 1 }
+            </a>
+          </li>
+      {{/each}}
+      </ul>
+  </div>
+</script>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/menu.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/menu.html
new file mode 100644 (file)
index 0000000..2d0b5f3
--- /dev/null
@@ -0,0 +1,122 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+-->
+<script type="text/html" id="main_menu_tmpl">
+  <div id="main-menu">
+
+    <ul class="nav nav-list">
+      <li class="nav-header">${$.i18n.prop('menu.artifacts')}</li>
+      <li>
+        <a href="#" id="menu-find-search-a" onclick="displaySearch(this)">${$.i18n.prop('menu.artifacts.search')}</a>
+      </li>
+      <li>
+        <a href="#" id="menu-find-browse-a" onclick="displayBrowse(true)">${$.i18n.prop('menu.artifacts.browse')}</a>
+      </li>
+    </ul>
+
+    <ul class="nav nav-list" redback-permissions="{permissions: ['archiva-manage-configuration']}">
+      <li class="nav-header">${$.i18n.prop('menu.administration')}</li>
+      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-configuration']}">
+        <a href="#" id="menu-repository-groups-list-a" onclick="displayRepositoryGroups()">${$.i18n.prop('menu.repository.groups')}</a>
+      </li>
+      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-configuration']}">
+        <a href="#" id="menu-repositories-list-a" onclick="displayRepositoriesGrid()">${$.i18n.prop('menu.repositories')}</a>
+      </li>
+      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-configuration']}">
+        <a href="#" id="menu-proxy-connectors-list-a" onclick="displayProxyConnectors()">${$.i18n.prop('menu.proxy-connectors')}</a>
+      </li>
+      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-configuration']}">
+        <a href="#" id="menu-network-proxies-list-a" onclick="displayNetworkProxies()">${$.i18n.prop('menu.network-proxies')}</a>
+      </li>
+      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-configuration']}">
+        <a href="#" id="menu-legacy-support-list-a" onclick="displayLegacyArtifactPathSupport()">${$.i18n.prop('menu.legacy-artifact-support')}</a>
+      </li>
+      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-configuration']}">
+        <a href="#" id="menu-repository-scanning-list-a" onclick="displayRepositoryScanning()">${$.i18n.prop('menu.repository-scanning')}</a>
+      </li>
+      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-configuration']}">
+        <a href="#" id="menu-network-configuration-list-a" onclick="displayNetworkConfiguration()">${$.i18n.prop('menu.network-configuration')}</a>
+      </li>
+      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-configuration']}">
+        <a href="#" id="menu-system-status-list-a" onclick="displaySystemStatus()">${$.i18n.prop('menu.system-status')}</a>
+      </li>
+      <li style="display:none" redback-permissions="{permissions: ['archiva-manage-configuration']}">
+        <a href="#" id="menu-appearance-list-a" onclick="displayAppearanceConfiguration()">${$.i18n.prop('menu.appearance-configuration')}</a>
+      </li>
+
+
+    </ul>
+
+    <ul class="nav nav-list" redback-permissions="{permissions: ['archiva-manage-users']}">
+      <li class="nav-header">${$.i18n.prop('menu.users')}</li>
+      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-users']}">
+        <a href="#" id="menu-users-list-a" onclick="displayUsersGrid(this)">${$.i18n.prop('menu.users.manage')}</a>
+      </li>
+      <li style="display: none" redback-permissions="{permissions: ['archiva-manage-users']}">
+        <a href="#" id="menu-roles-list-a" onclick="displayRolesGrid()">${$.i18n.prop('menu.users.roles')}</a>
+      </li>
+    </ul>
+
+  </div>
+</script>
+
+<script id="topbar_menu_tmpl" type="text/html">
+    <div id="topbar-menu">
+    <div class="navbar navbar-fixed-top">
+
+      <div style="max-height: 40px" class="navbar-inner">
+        <div class="container-fluid">
+          <div id="organisation-logo" class="pull-left"></div>
+          <ul class="nav pull-right">
+            <li id="create-admin-link" style="display: none">
+              <a href="#" onclick="adminCreateBox();" id="create-admin-link-a">
+                <span class="label label-important">${$.i18n.prop('create.admin.page.link')}</span>
+              </a>
+            </li>
+            <li id="login-link" style="display: none">
+              <a href="#" onclick="loginBox();" id="login-link-a">
+                <span class="label label-success force-upper-case">${$.i18n.prop('login')}</span>
+              </a>
+            </li>
+            <li id="change-password-link">
+              <a href="#" onclick="editUserDetailsBox();">${$.i18n.prop('edit.details')}</a>
+            </li>
+            <li id="logout-link" style="display: none">
+              <a href="#" onclick="logout(true);" id="logout-link-a">
+                <span class="label label-important force-upper-case">${$.i18n.prop('logout')}</span>
+              </a>
+            </li>
+            <li id="register-link" style="display: none">
+              <a href="#" onclick="registerBox();" id="register-link-a">
+                <span class="label label-info force-upper-case">${$.i18n.prop('register')}</span>
+              </a>
+            </li>
+            <li>
+              <div class="ui-widget navbar-search">
+
+                <input type="text" class="ui-autocomplete-input search-query" id="quick-search-autocomplete"
+                                   placeholder="${$.i18n.prop('menu.topbar.quicksearch')}" />
+              </div>
+            </li>
+          </ul>
+        </div>
+      </div>
+
+    </div>
+    </div>
+</script>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/message.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/message.html
new file mode 100644 (file)
index 0000000..44cf4da
--- /dev/null
@@ -0,0 +1,52 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+-->
+<script id='alert-message-success' type='text/html'>
+  <div class="alert fade in alert-success" data-alert="alert">
+    <a class="close" data-dismiss="alert" href="#" id='alert-message-success-close-a'>&#215;</a>
+    ${message}
+  </div>
+</script>
+<script id='alert-message-error' type='text/html'>
+  <div class="alert fade in alert-error" data-alert="alert">
+    <a class="close" data-dismiss="alert" href="#" id='alert-message-error-close-a'>&#215;</a>
+    ${message}
+  </div>
+</script>
+<script id='alert-message-warning' type='text/html'>
+  <div class="alert fade in alert-heading" data-alert="alert">
+    <a class="close" data-dismiss="alert" href="#" id='alert-message-warning-close-a'>&#215;</a>
+    ${message}
+  </div>
+</script>
+<script id='alert-message-info' type='text/html'>
+  <div class="alert fade in alert-info" data-alert="alert">
+    <a class="close" data-dismiss="alert" href="#" id='alert-message-info-close-a'>&#215;</a>
+    ${message}
+  </div>
+</script>
+
+<script id='footer-tmpl' type='text/html'>
+  <div class="pull-left">
+    <a target="_blank" href="http://archiva.apache.org/">Apache Archiva&nbsp;-&nbsp;${version}</a>
+  </div>
+  <div class="pull-right">
+    Copyright &#169;  ${copyrightRange}  <a target="_blank" href="http://www.apache.org/">The Apache Software Foundation</a>
+  </div>
+</script>
+
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/modal.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/modal.html
new file mode 100644 (file)
index 0000000..890d1ab
--- /dev/null
@@ -0,0 +1,31 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+-->
+<div id="dialog-confirm-modal" class="modal hide fade" style="display: block;">
+  <div class="modal-header">
+    <a class="close" href="#" data-dismiss="modal">&#215;</a>
+    <h3 id="dialog-confirm-modal-header-title"></h3>
+  </div>
+  <div class="modal-body">
+   <p id="dialog-confirm-modal-body-text"></p>
+  </div>
+  <div class="modal-footer">
+    <a class="btn secondary" id="dialog-confirm-modal-cancel" href="#">${$.i18n.prop('cancel')}</a>
+    <a class="btn primary" id="dialog-confirm-modal-ok" href="#">${$.i18n.prop('ok')}</a>
+  </div>
+</div>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/network-proxies.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/network-proxies.html
new file mode 100644 (file)
index 0000000..9c86057
--- /dev/null
@@ -0,0 +1,171 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+-->
+<script id="networkProxiesMain" type="text/html">
+  <div class="page-header">
+    <h2><img src="images/internet-web-browser-32-32.png"/>${$.i18n.prop('network-proxies.list')}</h2>
+  </div>
+
+  <ul id="network-proxies-view-tabs" class="nav nav-tabs">
+    <li id="network-proxies-view-tabs-li-grid">
+      <a data-toggle="tab" href="#network-proxies-view" id="network-proxies-view-tabs-a-network-proxies-grid">${$.i18n.prop('network-proxies.grid.tab.title')}</a>
+    </li>
+    <li id="network-proxies-view-tabs-li-edit">
+      <a data-toggle="tab" href="#network-proxies-edit">${$.i18n.prop('add')}</a>
+    </li>
+  </ul>
+  <div id="network-proxies-view-tabs-content" class="tab-content">
+    <div id="network-proxies-view" class="tab-pane">
+        <div id="network-proxies-bulk-save-btn" data-bind='template:{name:"network-proxies-bulk-save-tmpl"}'></div>
+        <table class="table table-striped table-bordered" id="networkProxiesTable"
+               data-bind="simpleGrid: gridViewModel,simpleGridTemplate:'ko-network-proxies-grid',pageLinksId:'network-proxiesPagination'">
+        </table>
+        <div id="network-proxiesPagination"></div>
+    </div>
+    <div id="network-proxies-edit" class="tab-pane" data-bind='template: {name:"network-proxy-edit-tmpl"}'></div>
+  </div>
+
+</script>
+
+<script id='ko-network-proxies-grid' type='text/html'>
+    <thead>
+    <tr>
+        {{each(i, columnDefinition) columns}}
+        <th>${ columnDefinition.headerText }</th>
+        {{/each}}
+        <th>${$.i18n.prop('password')}</th>
+        <th>${$.i18n.prop('network.proxy.useNtlm')}</th>
+        <th>${$.i18n.prop('edit')}</th>
+        <th>${$.i18n.prop('delete')}</th>
+        <th>${$.i18n.prop('modified')}</th>
+    </tr>
+    </thead>
+    <tbody>
+    {{each(i, row) itemsOnCurrentPage()}}
+      <tr data-bind="css:{ 'modified': row.modified()}">
+        {{each(j, columnDefinition) columns}}
+        {{var val = (typeof columnDefinition.rowText == 'function' ? columnDefinition.rowText(row) : row[columnDefinition.rowText])}}
+          <td>
+              ${val}
+          </td>
+        {{/each}}
+        {{if row.password()}}
+          <td>*****</td>
+        {{else}}
+          <td></td>
+        {{/if}}
+          <td>${row.useNtlm()}</td>
+          <td>
+            <a href="#" data-bind="click: function(){ editNetworkProxy(row) }">
+              <img src="images/edit-find-22-22.png" title="${$.i18n.prop('edit')}">
+            </a>
+          </td>
+          <td>
+            <a href="#" data-bind="click: function(){ removeNetworkProxy(row) }">
+              <img src="images/edit-cut.png" title="${$.i18n.prop('delete')}"/>
+            </a>
+          </td>
+        {{if row.modified()}}
+          <td>
+            <a href="#" data-bind="click: function(){ updateNetworkProxy(row) }" class="btn btn-warning">${$.i18n.prop('save')}</a>
+          </td>
+        {{else}}
+          <td></td>
+        {{/if}}
+
+    </tr>
+    {{/each}}
+    </tbody>
+
+</script>
+
+<script id="network-proxy-edit-tmpl" type='text/html'>
+    <form id="network-proxy-edit-form" class="well form-horizontal">
+      <fieldset id="network-proxy-edit-fieldset">
+        <div class="control-group">
+          <label class="control-label" for="id">${$.i18n.prop('id')}</label>
+          <div class="controls">
+            {{if update}}
+              <span class="uneditable-input">${$data.networkProxy.id}</span>
+            {{else}}
+              <input type="text" class="xlarge" id="id" name="id" size="10"
+                     data-bind="value: networkProxy.id,css:{'uneditable-input': update},readonly:update"/>
+            {{/if}}
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="protocol">${$.i18n.prop('protocol')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge required" id="protocol" name="protocol" size="8"
+                   data-bind="value: networkProxy.protocol"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="host">${$.i18n.prop('host')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge required" id="host" name="host" size="15"
+                   data-bind="value: networkProxy.host"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="port">${$.i18n.prop('port')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge required digits" id="port" name="port" size="6"
+                   data-bind="value: networkProxy.port"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="username">${$.i18n.prop('username')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge" id="username" name="username" size="50"
+                   data-bind="value: networkProxy.username"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="password">${$.i18n.prop('password')}</label>
+          <div class="controls">
+            <input type="password" class="xlarge" id="password" name="password" size="50"
+                   data-bind="value: networkProxy.password"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="useNtlm">${$.i18n.prop('network.proxy.useNtlm')}</label>
+          <div class="controls">
+            <input type="checkbox" id="useNtlm" name="useNtlm" data-bind="checked: networkProxy.useNtlm"/>
+          </div>
+        </div>
+
+      </fieldset>
+      <button id="network-proxy-btn-save" data-bind="click: save" class="btn">${$.i18n.prop('save')}</button>
+      {{if networkProxy.modified()}}
+       ${("#network-proxy-btn-save").button('reset')}
+      {{/if}}
+      <button data-bind="click: displayGrid" class="btn">${$.i18n.prop('cancel')}</button>
+    </form>
+</script>
+
+<script id="network-proxies-bulk-save-tmpl" type='text/html'>
+  {{if bulkSave()}}
+    <a data-bind="click: updateModifiedNetworkProxies" class="btn btn-danger" href="#">${$.i18n.prop('save.all')}</a>
+  {{/if}}
+</script>
+<script id="network-proxy-delete-warning-tmpl" type='text/html'>
+    <div>
+      <span class="label label-warning">${$.i18n.prop('warning.not.undone.operation')}</span>
+    </div>
+</script>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/proxy-connectors.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/proxy-connectors.html
new file mode 100644 (file)
index 0000000..c9d1920
--- /dev/null
@@ -0,0 +1,310 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+-->
+<script id="proxyConnectorsMain" type="text/html">
+  <div class="page-header">
+    <h2><img src="images/preferences-system-network-proxy-32-32.png"/>${$.i18n.prop('proxy-connectors.list')}</h2>
+  </div>
+
+  <ul id="proxy-connectors-view-tabs" class="nav nav-tabs">
+    <li id="proxy-connectors-view-tabs-li-grid" class="active">
+      <a data-toggle="tab" href="#proxy-connectors-view" id="proxy-connectors-view-tabs-a-network-proxies-grid">${$.i18n.prop('proxy-connectors.grid.tab.title')}</a>
+    </li>
+    <li id="proxy-connectors-view-tabs-li-edit">
+      <a data-toggle="tab" href="#proxy-connectors-edit" id="proxy-connectors-view-tabs-a-edit">${$.i18n.prop('add')}</a>
+    </li>
+    <li id="proxy-connectors-view-tabs-li-edit-order">
+      <a data-toggle="tab" href="#proxy-connectors-edit-order" id="proxy-connectors-view-tabs-a-edit-order">${$.i18n.prop('proxy-connectors.grid.tab.edit.order')}</a>
+    </li>
+  </ul>
+  <div id="proxy-connectors-view-tabs-content" class="tab-content">
+    <div id="proxy-connectors-view" class="tab-pane active">
+      <div id="proxy-connectors-bulk-save-btn" data-bind='template:{name:"proxy-connectors-bulk-save-tmpl"}'></div>
+      <table class="table table-striped table-bordered" id="proxyConnectorsTable"
+             data-bind="simpleGrid: gridViewModel,simpleGridTemplate:'ko-proxy-connectors-grid',pageLinksId:'proxy-connectorsPagination'">
+      </table>
+      <div id="proxy-connectorsPagination"></div>
+    </div>
+    <div id="proxy-connectors-edit" class="tab-pane"></div>
+    <div id="proxy-connector-edit-order" class="tab-pane span8">
+      <div id="proxy-connector-edit-order-managed-repository-div" data-bind='template:{name:"proxy-connector-edit-order-managed-repository-tmpl"}'></div>
+      <div id="proxy-connector-edit-order-div"
+         data-bind="sortable: { template: 'proxy-connector-edit-order-tmpl', data: proxyConnectors,afterMove: proxyConnectorMoved}">
+      </div>
+    </div>
+  </div>
+
+</script>
+
+<script id='ko-proxy-connectors-grid' type='text/html'>
+    <thead>
+      <tr>
+        <th title="${$.i18n.prop('proxy-connectors.grid.managedrepo.title')}">
+          ${$.i18n.prop('proxy-connectors.grid.managedrepo.grid.header')}
+        </th>
+        <th title="${$.i18n.prop('proxy-connectors.grid.remoterepo.title')}">
+          ${$.i18n.prop('proxy-connectors.grid.remoterepo.grid.header')}
+        </th>
+        <th>${$.i18n.prop('proxy-connectors.grid.remoterepo.settings.popover.title')}</th>
+        <th>${$.i18n.prop('edit')}</th>
+        <th>${$.i18n.prop('delete')}</th>
+        <th>${$.i18n.prop('save')}</th>
+        <th>${$.i18n.prop('proxy-connectors.grid.header.order')}</th>
+      </tr>
+    </thead>
+    <tbody>
+    {{each(i, row) itemsOnCurrentPage()}}
+    <tr data-bind="css:{ 'modified': row.modified()}">
+      <td>${row.sourceRepoId()}</td>
+      <td>${row.targetRepoId()}</td>
+      <td>
+          <img src="images/utilities-system-monitor-22-22.png" id="proxy-connectors-grid-remoterepo-settings-edit-${row.sourceRepoId()}-${row.targetRepoId()}"
+               data-original-title="${$.i18n.prop('proxy-connectors.grid.remoterepo.settings.popover.title')}"
+               data-bind="event: { mouseover: function(){ showSettings(row)},}">
+          <div id="proxy-connectors-grid-remoterepo-settings-content-${row.sourceRepoId()}-${row.targetRepoId()}"
+               style="display:none"></div>
+      </td>
+      <td>
+        <a data-bind="click: function(){ editProxyConnector(row)}" href="#">
+          <img src="images/edit-find-22-22.png" title="${$.i18n.prop('edit')}">
+        </a>
+      </td>
+      <td>
+        <a href="#" data-bind="click: function(){ deleteProxyConnector(row)}">
+          <img src="images/edit-cut-22-22.png" title="${$.i18n.prop('delete')}"/>
+        </a>
+      </td>
+      <td>
+        {{if row.modified()}}
+          <a href="#" class="btn btn-warning" data-bind="click: function(){ updateProxyConnector(row)}">
+              ${$.i18n.prop('save')}
+          </a>
+        {{/if}}
+      </td>
+      <td>
+        {{if orderChangeAware(row)}}
+          <a href="#" class="btn btn-info" data-bind="click: function(){ displayOrderEdit(row)}">
+              ${$.i18n.prop('proxy-connectors.order.edit')}
+          </a>
+          <span class="badge badge-info">${row.order()}</span>
+        {{/if}}
+      </td>
+    </tr>
+    {{/each}}
+    </tbody>
+    <div id="proxy-connectors-grid-remoterepo-settings-content-${val}-${targetRepoId}" style="display:none"></div>
+</script>
+
+<script id='proxy-connectors-remote-settings-popover-tmpl' type='text/html'>
+  <div>
+    {{if proxyId}}
+      ${$.i18n.prop('proxy-connectors.remoterepo.settings.networkproxy')}: ${proxyConnector.proxyId}
+    {{else}}
+      ${$.i18n.prop('proxy-connectors.remoterepo.settings.networkproxy')}: ${$.i18n.prop('none')}
+    {{/if}}
+    <table class="table">
+      <thead>
+        <th colspan="2">${$.i18n.prop('proxy-connector.policies')}</th>
+      </thead>
+      <tbody>
+        {{each(i, entry) proxyConnector.policiesEntries}}
+        {{var name = proxyConnectorsViewModel.findPolicyInformationName(entry.key)}}
+        <tr>
+          <td>${name}</td>
+          <td>${entry.value}</td>
+        </tr>
+        {{/each}}
+      </tbody>
+    </table>
+  </div>
+</script>
+
+<script id="proxy-connector-edit-form-tmpl" type='text/html'>
+
+    <form id="proxy-connector-edit-form" class="well form-horizontal">
+      <fieldset id="remote-repository-edit-fieldset">
+        <div class="control-group">
+          <label class="control-label" for="proxyId">${$.i18n.prop('proxy-connector.network-proxy.id')}</label>
+          <div class="controls">
+            <select id="proxyId"
+                    data-bind="options: proxyConnectorsViewModel.networkProxies, optionsText: 'id',optionsValue:'id',
+                     value: proxyConnector.proxyId, optionsCaption: 'direct connection'"></select>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="proxyId">${$.i18n.prop('proxy-connector.managed.repository.id')}</label>
+          <div class="controls">
+              <select id="sourceRepoId"
+                      data-bind="options: proxyConnectorsViewModel.managedRepositories, optionsText: 'id',optionsValue:'id',
+                      value: proxyConnector.sourceRepoId,attr: {disabled: isUpdate() }"></select>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="proxyId">${$.i18n.prop('proxy-connector.remote.repository.id')}</label>
+          <div class="controls">
+            <select id="targetRepoId"
+                    data-bind="options: proxyConnectorsViewModel.remoteRepositories, optionsText: 'id',optionsValue:'id',
+                     value: proxyConnector.targetRepoId,attr: {disabled: isUpdate() }"></select>
+          </div>
+        </div>
+        <div class="row">
+          <div class="control-group span6">
+            <table class="table">
+              <thead>
+                <th colspan="2">${$.i18n.prop('proxy-connector.policies')}</th>
+              </thead>
+              <tbody data-bind="foreach: proxyConnectorsViewModel.policyInformations()">
+                  <tr>
+                    <td data-bind="text: name"></td>
+                    <td>
+                      <select
+                              data-bind="options: getPolicyOptions(id()),value:getSelectedPolicyOption(id()),
+                              attr: { id: 'policy-'+id() },event: { change: function(){ changePolicyOption(id())},}"
+                              ></select>
+                    </td>
+                  </tr>
+              </tbody>
+            </table>
+          </div>
+        </div>
+        <div class="row">
+          <div class="control-group span6">
+            <h4>${$.i18n.prop('proxy-connector.properties')}</h4>
+            <table class="table">
+              <thead>
+                <th><input type="text" id="property-key"/></th>
+                <th><input type="text" id="property-value"/></th>
+                <th><a href="#" data-bind="click: function(){ addProperty() }">${$.i18n.prop('add')}</a></th>
+              </thead>
+              <tbody data-bind="foreach: proxyConnector.propertiesEntries">
+                <tr>
+                  <td data-bind="text: key"></td>
+                  <td data-bind="text: value"></td>
+                  <td><a href="#" data-bind="click: function(){ $parent.deleteProperty(key)}">${$.i18n.prop('delete')}</a></td>
+                </tr>
+              </tbody>
+            </table>
+          </div>
+        </div>
+        <div class="row">
+          <div class="control-group span6">
+            <h4>${$.i18n.prop('proxy-connector.blacklist')}</h4>
+            <table class="table">
+              <thead>
+                <th><input type="text" id="blacklist-value"/></th>
+                <th><a href="#" data-bind="click: function(){ addBlacklistPattern() }">${$.i18n.prop('add')}</a></th>
+              </thead>
+              <tbody data-bind="foreach: proxyConnector.blackListPatterns">
+                <tr>
+                  <td data-bind="text: $data"></td>
+                  <td><a href="#" data-bind="click: function(){removeBlacklistPattern($data)}">${$.i18n.prop('delete')}</a></td>
+                </tr>
+              </tbody>
+            </table>
+          </div>
+        </div>
+        <div class="row">
+          <div class="control-group span6">
+            <h4>${$.i18n.prop('proxy-connector.whitelist')}</h4>
+            <table class="table">
+              <thead>
+                <th><input type="text" id="whitelist-value"/></th>
+                <th><a href="#" data-bind="click: function(){ addWhitelistPattern() }">${$.i18n.prop('add')}</a></th>
+              </thead>
+              <tbody data-bind="foreach: proxyConnector.whiteListPatterns">
+                <tr>
+                  <td data-bind="text: $data"></td>
+                  <td><a href="#" data-bind="click: function(){removeWhitelistPattern($data)}">${$.i18n.prop('delete')}</a></td>
+                </tr>
+              </tbody>
+            </table>
+          </div>
+        </div>
+      </fieldset>
+
+      <button id="proxy-connector-btn-save" data-bind="click: save" class="btn">${$.i18n.prop('save')}</button>
+      {{if modified()}}
+       ${("#network-proxy-btn-save").button('reset')}
+      {{/if}}
+      <button data-bind="click: displayGrid" class="btn">${$.i18n.prop('cancel')}</button>
+
+    </form>
+
+</script>
+<script id="proxy-connectors-bulk-save-tmpl" type='text/html'>
+  {{if bulkSave()}}
+    <a data-bind="click: updateModifiedProxyConnectors" class="btn btn-danger" href="#">${$.i18n.prop('save.all')}</a>
+  {{/if}}
+</script>
+
+<script id="proxy-connector-edit-order-tmpl" type='text/html'>
+  <div class="well draggable-item network-proxy-remote-item">
+    {{var remoteRepository=$parent.findRemoteRepository(targetRepoId)}}
+    <div class="row-fluid">
+      <div class="span1">
+        <img src="images/system-software-update-32-32.png"/>
+          <br/>
+          <img src="images/utilities-system-monitor-22-22.png"
+               id="proxy-connectors-order-remoterepo-settings-edit-${sourceRepoId()}-${targetRepoId()}"
+               data-original-title="${$.i18n.prop('proxy-connectors.grid.remoterepo.settings.popover.title')}"
+               data-bind="event: { mouseover: function(){ displaySettings(sourceRepoId(),targetRepoId())},}">
+          <div id="proxy-connectors-order-remoterepo-settings-content-${sourceRepoId()}-${targetRepoId()}"
+               style="display:none"></div>
+      </div>
+      <div class="span6 pull-left">
+        <blockquote>
+            ${targetRepoId}
+            <br/>
+            ${remoteRepository.name()}&nbsp;(<a href="${remoteRepository.url()}" target="_blank">${remoteRepository.url()}</a>)
+        </blockquote>
+      </div>
+      <div class="span2">
+        <span class="badge badge-info">${order}</span>
+      </div>
+    </div>
+  </div>
+</script>
+
+<script id="proxy-connector-edit-order-managed-repository-tmpl" type="text/html">
+  <div class="well row-fluid">
+    <div class="span1">
+      <img src="images/applications-internet-32-32.png"/>
+    </div>
+    <div class="span6">
+      <blockquote>
+        ${managedRepository.id}
+        <br/>
+        ${managedRepository.name}
+      </blockquote>
+    </div>
+    <div class="span2">
+      {{if proxyConnectorsViewModel.bulkSave()}}
+        <p>
+          <a data-bind="click: function(){updateModifiedProxyConnectors()}"
+             href="#" class="btn btn-warning">${$.i18n.prop('save.all')}</a></p>
+      {{/if}}
+    </div>
+  </div>
+</script>
+
+<script id="proxy-connector-delete-warning-tmpl" type='text/html'>
+    <div>
+      <span class="label label-warning">${$.i18n.prop('warning.not.undone.operation')}</span>
+    </div>
+</script>
+
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/repositories.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/repositories.html
new file mode 100644 (file)
index 0000000..5cbec28
--- /dev/null
@@ -0,0 +1,483 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+-->
+<script id="repositoriesMain" type="text/html">
+    <div class="page-header">
+      <h2><img src="images/system-file-manager-32-32.png"/>${$.i18n.prop('administration.repositories')}</h2>
+    </div>
+
+      <ul id="repositories-tabs" class="nav nav-tabs">
+        <li class="active">
+          <a data-toggle="tab" href="#managed-repositories-content">${$.i18n.prop('managedrepositories.grid.head')}</a>
+        </li>  
+        <li>
+          <a data-toggle="tab" href="#remote-repositories-content">${$.i18n.prop('remoterepositories.grid.head')}</a>
+        </li>
+      </ul>  
+      <div class="tab-content">
+       <div id="managed-repositories-content" class="tab-pane active">
+            <ul id="managed-repositories-pills" class="nav nav-pills">
+              <li class="active" id="managed-repositories-view-li">
+                <a data-toggle="tab" href="#managed-repositories-view" id="managed-repositories-view-a">${$.i18n.prop('managedrepositories.grid.tab.title')}</a>
+              </li>
+              <li id="managed-repository-edit-li">
+                <a data-toggle="tab" href="#managed-repository-edit">${$.i18n.prop('add')}</a>
+              </li>
+            </ul>
+            <div id="managed-repositories-tabs-content" class="pill-content">
+              <div id="managed-repositories-view" class="pill-pane active">
+                <div id="managed-repositories-bulk-save-btn" data-bind='template:{name:"managed-repositories-bulk-save-tmpl"}'></div>
+                <table class="table table-striped table-bordered" id="managed-repositories-table"
+                       data-bind="simpleGrid: gridViewModel,simpleGridTemplate:'ko_managed-repositoriesGrid',pageLinksId:'managed-repositoriesPagination',data:'managedRepositories'">
+                </table>
+                <div id="managed-repositoriesPagination"></div>
+                <div id="managed-repositories-pom-snippet"></div>
+              </div>
+              <div id="managed-repository-edit" class="pill-pane" data-bind='template: {name:"managed-repository-edit-tmpl"}'>
+              </div>
+            </div>
+       </div>
+
+
+       <div id="remote-repositories-content" class="tab-pane">
+            <ul id="remote-repositories-pills" class="nav nav-pills">
+              <li class="active" id="remote-repositories-view-li">
+                <a data-toggle="tab" href="#remote-repositories-view" id="remote-repositories-view-a">${$.i18n.prop('remoterepositories.grid.tab.title')}</a>
+              </li>
+              <li id="remote-repository-edit-li">
+                <a data-toggle="tab" href="#remote-repository-edit">${$.i18n.prop('add')}</a>
+              </li>
+            </ul>
+            <div id="remote-repositories-tabs-content" class="pill-content">
+              <div id="remote-repositories-view" class="pill-pane active">
+                  <div id="remote-repositories-bulk-save-btn" data-bind='template:{name:"remote-repositories-bulk-save-tmpl"}'></div>
+                  <table class="table table-striped table-bordered" id="remote-repositories-table"
+                         data-bind="simpleGrid: gridViewModel,simpleGridTemplate:'ko_remote-repositoriesGrid',pageLinksId:'remote-repositoriesPagination',data:'remoteRepositories'">
+                  </table>
+                  <div id="remote-repositoriesPagination"></div>
+              </div>
+              <div id="remote-repository-edit" class="pill-pane" data-bind='template: {name:"remote-repository-edit-tmpl"}'>
+              </div>
+            </div>
+       </div>
+      </div>
+</script>
+
+<script id='ko_managed-repositoriesGrid' type='text/html'>
+  <thead>
+      <tr>
+        {{each(i, columnDefinition) columns}}
+          <th title="${ columnDefinition.title }">${ columnDefinition.headerText }</th>
+        {{/each}}
+        <th>Releases</th>
+        <th>Snapshots</th>
+        <th title="${$.i18n.prop('managedrepository.scan.index')}">${$.i18n.prop('managedrepository.scan.grid.header')}</th>
+        <th>${$.i18n.prop('edit')}</th>
+        <th>${$.i18n.prop('delete')}</th>
+        <th>${$.i18n.prop('modified')}</th>
+        <th>${$.i18n.prop('managedrepository.pomsnippet')}</th>
+        <th title="${$.i18n.prop('managedrepository.stats')}">${$.i18n.prop('managedrepository.stats.grid.header')}</th>
+        <th title="${$.i18n.prop('managedrepository.scan.directories')}">${$.i18n.prop('managedrepository.scan.directories.grid.header')}</th>
+      </tr>
+  </thead>
+  <tbody>
+      {{each(i, row) itemsOnCurrentPage()}}
+          <tr data-bind="css:{ 'modified': row.modified()}">
+            {{each(j, columnDefinition) columns}}
+              <td>${ typeof columnDefinition.rowText == 'function' ? columnDefinition.rowText(row) : row[columnDefinition.rowText] }</td>
+            {{/each}}
+            <td>
+            {{if row.releases() == true}}
+              <img src="images/weather-clear-22-22.png" title="${$.i18n.prop('release.included')}"/>
+            {{else}}
+              <img src="images/dialog-error-22-22.png" title="${$.i18n.prop('release.notincluded')}"/>
+            {{/if}}
+            </td>
+
+            <td>
+              {{if row.snapshots() == true}}
+                <img src="images/weather-clear-22-22.png" title="${$.i18n.prop('snapshots.included')}"/>
+              {{else}}
+                  <img src="images/dialog-error-22-22.png" title="${$.i18n.prop('snapshots.notincluded')}"/>
+              {{/if}}
+            </td>
+            <td>
+              <a href="#" data-bind="click: function(){ scanNow(row) }">
+                <img src="images/view-refresh-22-22.png" title="${$.i18n.prop('managedrepository.scan.now')}"/>
+              </a>
+            </td>
+            <td>
+              <a href="#" data-bind="click: function(){ editManagedRepository(row) }">
+                <img src="images/edit-find-22-22.png" title="${$.i18n.prop('edit')}">
+              </a>
+            </td>
+            <td>
+              <a href="#" data-bind="click: function(){ removeManagedRepository(row) }">
+                <img src="images/edit-cut-22-22.png" title="${$.i18n.prop('delete')}"/>
+              </a>
+            </td>
+            {{if row.modified()}}
+              <td>
+                <a href="#" class="btn btn-warning" data-bind="click: function(){ updateManagedRepository(row) }">${$.i18n.prop('save')}</a>
+              </td>
+            {{else}}
+              <td></td>
+            {{/if}}
+            <td><a href="#" data-bind="click: function(){ showPomSnippet(row) }">${$.i18n.prop('managedrepository.pomsnippet')}</a></td>
+            <td id="managedrepository-stats-${row.id()}">
+              <img src="images/utilities-system-monitor-22-22.png" data-original-title="${$.i18n.prop('managedrepository.stats')}"
+                   data-bind="event: { mouseover: function(){ showStats(row) }, mouseout: function(){ hideStats(row) },}"
+                   id="managedrepository-stats-img-${row.id()}"/>
+            </td>
+            <td>
+              <a href="#" data-bind="click: function(){directoriesScan(row)}" class="btn btn-warning">${$.i18n.prop('managedrepository.scan.directories.grid')}</a>
+            </td>
+          </tr>
+      {{/each}}
+  </tbody>
+
+</script>
+
+<script id="managed-repository-edit-tmpl" type='text/html'>
+    <form id="managed-repository-edit-form" class="well form-horizontal">
+      <fieldset id="managed-repository-edit-fieldset">
+        <div class="control-group">
+          <label class="control-label" for="id">${$.i18n.prop('id')}</label>
+          <div class="controls">
+            {{if update}}
+              <span class="uneditable-input">${$data.managedRepository.id}</span>
+            {{else}}
+              <input type="text" class="xlarge required" id="id" name="id" size="50"
+                     data-bind="value: managedRepository.id,css:{'uneditable-input': update},readonly:update"/>
+            {{/if}}
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="name">${$.i18n.prop('name')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge required" id="name" name="name" size="50"
+                   data-bind="value: managedRepository.name"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="location">${$.i18n.prop('directory')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge required" id="location" name="location" size="50" data-bind="value: managedRepository.location"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="indexDirectory">${$.i18n.prop('index.directory')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge" id="indexDirectory" name="indexDirectory" size="50" data-bind="value: managedRepository.indexDirectory"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="layout">${$.i18n.prop('type')}</label>
+          <div class="controls">
+            <select id="layout" data-bind="options: availableLayouts,optionsText: 'label',optionsValue:'type',value: managedRepository.layout"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="cronExpression">${$.i18n.prop('cronExpression')}</label>
+          <div class="controls">
+            <input type="text" id="cronExpression" class="required" name="cronExpression" size="40" data-bind="value: managedRepository.cronExpression"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="daysOlder">${$.i18n.prop('daysOlder')}</label>
+          <div class="controls">
+            <input type="text" id="daysOlder" class="digits" name="daysOlder" size="5" data-bind="value: managedRepository.daysOlder"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="retentionCount">${$.i18n.prop('retentionCount')}</label>
+          <div class="controls">
+            <input type="text" id="retentionCount" name="retentionCount" size="5" data-bind="value: managedRepository.retentionCount"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="releases">${$.i18n.prop('releases')}</label>
+          <div class="controls">
+            <input type="checkbox" id="releases" name="releases" size="5" data-bind="checked: managedRepository.releases"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="snapshots">${$.i18n.prop('snapshots')}</label>
+          <div class="controls">
+            <input type="checkbox" id="snapshots" name="snapshots" size="5" data-bind="checked: managedRepository.snapshots"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="blockRedeployments">${$.i18n.prop('blockRedeployments')}</label>
+          <div class="controls">
+            <input type="checkbox" id="blockRedeployments" name="blockRedeployments" size="5" data-bind="checked: managedRepository.blockRedeployments"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="scanned">${$.i18n.prop('scanned')}</label>
+          <div class="controls">
+            <input type="checkbox" id="scanned" name="scanned" size="5" data-bind="checked: managedRepository.scanned"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="deleteReleasedSnapshots">${$.i18n.prop('deleteReleasedSnapshots')}</label>
+          <div class="controls">
+            <input type="checkbox" id="deleteReleasedSnapshots" name="deleteReleasedSnapshots" size="5"
+                   data-bind="checked: managedRepository.deleteReleasedSnapshots"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="stageRepoNeeded">${$.i18n.prop('stageRepoNeeded')}</label>
+          <div class="controls">
+            <input type="checkbox" id="stageRepoNeeded" name="stageRepoNeeded" size="5"
+                   data-bind="checked: managedRepository.stageRepoNeeded"/>
+          </div>
+        </div>
+      </fieldset>
+      <button data-bind="click: save" class="btn">${$.i18n.prop('save')}</button>
+      <button data-bind="click: displayGrid" class="btn">${$.i18n.prop('cancel')}</button>
+    </form>
+</script>
+
+<script id="managed-repository-delete-warning-tmpl" type='text/html'>
+  <div>
+    <span class="label label-warning">${$.i18n.prop('warning.not.undone.operation')}</span>
+    <div>
+      <span><strong>${$.i18n.prop('managedrepository.delete.warning.message')}</strong>.</span>
+      <div>${$.i18n.prop('id')}: ${id()}</div>
+      <div>${$.i18n.prop('name')}: ${name()}</div>
+    </div>
+    <div>
+        ${$.i18n.prop('managedrepository.delete.content')}: <input type="checkbox" id="managedrepository-deletecontent">
+    </div>
+  </div>
+</script>
+
+<script type="text/html" id="remote-repository-delete-modal-tmpl">
+    <div>
+      <span class="label label-warning">${$.i18n.prop('warning.not.undone.operation')}</span>
+    </div>
+</script>
+
+<script id="managed-repository-location-warning-tmpl" type='text/html'>
+  <div>
+    <span class="label label-warning">${$.i18n.prop('managedrepository.location.already.exists')}</span>
+    <div>
+      <span><strong>${$.i18n.prop('managedrepository.location.already.exists.warning.message')}</strong>.</span>
+      <div>${$.i18n.prop('id')}: ${id()}</div>
+      <div>${$.i18n.prop('name')}: ${name()}</div>
+    </div>
+  </div>
+</script>
+<script id="managed-repository-scan-now-modal-tmpl" type='text/html'>
+  <div>
+    ${$.i18n.prop('managedrepository.scan.all')}: <input type="checkbox" id="managed-repository-scan-now-all">
+  </div>
+</script>
+<script id="managed-repository-stats-tmpl" type='text/html'>
+  <div id="managedrepository-stats-${managedRepository.id()}-popover" style="display:none">
+    <div>${$.i18n.prop('managedrepository.stats.endTime')}: ${lastScanDate()}</div>
+    <div>${$.i18n.prop('managedrepository.stats.duration')}: ${duration()}ms</div>
+    <div>${$.i18n.prop('managedrepository.stats.totalFileCount')}: ${totalFileCount()}</div>
+    <div>${$.i18n.prop('managedrepository.stats.newFileCount')}: ${newFileCount()}</div>
+  </div>
+</script>
+<script id="pom-snippet-tmpl" type='text/html'>
+  <div class="page-header">
+    <h2>POM Snippet</h2></div>
+  </div>
+  <div><a href="#" onclick="$('#managed-repositories-pom-snippet').effect('blind')">${$.i18n.prop('hide')}</a></div>
+  <pre>${$data}</pre>
+</script>
+
+<!-- remote part -->
+
+<script id='ko_remote-repositoriesGrid' type='text/html'>
+  <thead>
+      <tr>
+        {{each(i, columnDefinition) columns}}
+          <th title="${ columnDefinition.title }">${ columnDefinition.headerText }</th>
+        {{/each}}
+        <th>${$.i18n.prop('edit')}</th>
+        <th>${$.i18n.prop('delete')}</th>
+        <th>${$.i18n.prop('modified')}</th>
+        <th>${$.i18n.prop('remoterepository.downloadremoteindex')}</th>
+      </tr>
+  </thead>
+  <tbody>
+      {{each(i, row) itemsOnCurrentPage()}}
+          <tr data-bind="css:{ 'modified': row.modified()}">
+            {{each(j, columnDefinition) columns}}
+              <td>${ typeof columnDefinition.rowText == 'function' ? columnDefinition.rowText(row) : row[columnDefinition.rowText] }</td>
+            {{/each}}
+            <td>
+              <a href="#" data-bind="click: function(){ editRemoteRepository(row) }">
+                <img src="images/edit-find-22-22.png" title="${$.i18n.prop('edit')}">
+              </a>
+            </td>
+            <td>
+              <a href="#" data-bind="click: function(){ removeRemoteRepository(row) }">
+                <img src="images/edit-cut-22-22.png" title="${$.i18n.prop('delete')}"/>
+              </a>
+            </td>
+            {{if row.modified()}}
+              <td>
+                <a href="#" class="btn btn-warning" data-bind="click: function(){ updateRemoteRepository(row) }">${$.i18n.prop('save')}</a>
+              </td>
+            {{else}}
+              <td></td>
+            {{/if}}
+            <td>
+              <a href="#" data-bind="click: function(){ scheduleDownloadRemoteIndex(row) }">
+                <img src="images/view-refresh-22-22.png" title="${$.i18n.prop('remoterepository.downloadremoteindex.now')}"/>
+              </a>
+            </td>
+          </tr>
+      {{/each}}
+  </tbody>
+
+</script>
+
+
+<script id="remote-repository-edit-tmpl" type='text/html'>
+    <form id="remote-repository-edit-form" class="well form-horizontal">
+      <fieldset id="remote-repository-edit-fieldset">
+        <div class="control-group">
+          <label class="control-label" for="id">${$.i18n.prop('id')}</label>
+          <div class="controls">
+            {{if update}}
+              <span class="uneditable-input">${$data.remoteRepository.id}</span>
+            {{else}}
+              <input type="text" class="xlarge required" id="id" name="id" size="50"
+                     data-bind="value: remoteRepository.id,css:{'uneditable-input': update},readonly:update"/>
+            {{/if}}
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="name">${$.i18n.prop('name')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge required" id="name" name="name" size="50"
+                   data-bind="value: remoteRepository.name"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="url">${$.i18n.prop('url')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge required" id="url" name="location" size="50" data-bind="value: remoteRepository.url"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="userName">${$.i18n.prop('username')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge" id="userName" name="userName" size="50" data-bind="value: remoteRepository.indexDirectory"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="password">${$.i18n.prop('password')}</label>
+           <div class="controls">
+             <input type="password" class="xlarge" id="password" name="password" size="50" data-bind="value: remoteRepository.password"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="timeout">${$.i18n.prop('timeout')}</label>
+          <div class="controls">
+            <input type="text" id="timeout" class="digits" name="daysOlder" size="5" data-bind="value: remoteRepository.timeout"/>
+          </div>
+        </div>
+
+        <div class="control-group">
+          <label class="control-label" for="layout">${$.i18n.prop('type')}</label>
+          <div class="controls">
+            <select id="layout" data-bind="options: availableLayouts,optionsText: 'label',optionsValue:'type',value: remoteRepository.layout"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="downloadRemoteIndex">${$.i18n.prop('downloadRemoteIndex')}</label>
+          <div class="controls">
+            <input type="checkbox" id="downloadRemoteIndex" name="downloadRemoteIndex" size="5" data-bind="checked: remoteRepository.downloadRemoteIndex"/>
+          </div>
+        </div>
+
+        <div class="control-group">
+          <label class="control-label" for="remoteIndexUrl">${$.i18n.prop('remoteIndexUrl')}</label>
+          <div class="controls">
+            <input type="text" id="remoteIndexUrl" name="remoteIndexUrl" size="5" data-bind="value: remoteRepository.remoteIndexUrl"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="cronExpression">${$.i18n.prop('cronExpression')}</label>
+          <div class="controls">
+            <input type="text" id="cronExpression" name="cronExpression" size="40" data-bind="value: remoteRepository.cronExpression"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="indexDirectory">${$.i18n.prop('index.directory')}</label>
+          <div class="controls">
+            <input type="text" class="xlarge" id="indexDirectory" name="indexDirectory" size="50" data-bind="value: remoteRepository.indexDirectory"/>
+          </div>
+        </div>
+        <div class="control-group">
+          <label class="control-label" for="remoteDownloadTimeout">${$.i18n.prop('remoteDownloadTimeout')}</label>
+          <div class="controls">
+            <input type="text" id="remoteDownloadTimeout" class="digits" name="remoteDownloadTimeout" size="5"
+                   data-bind="value: remoteRepository.remoteDownloadTimeout"/>
+          </div>
+        </div>
+
+        <div class="control-group">
+          <label class="control-label" for="remoteDownloadNetworkProxyId">${$.i18n.prop('remoteDownloadNetworkProxyId')}</label>
+          <div class="controls">
+            <select id="remoteDownloadNetworkProxyId" data-bind="options: networkProxies, optionsText: 'id',optionsValue:'id', value: remoteRepository.remoteDownloadNetworkProxyId, optionsCaption: 'Choose...'"></select>
+          </div>
+        </div>
+
+
+        <div class="control-group">
+          <label class="control-label" for="downloadRemoteIndexOnStartup">${$.i18n.prop('downloadRemoteIndexOnStartup')}</label>
+          <div class="controls">
+            <input type="checkbox" id="downloadRemoteIndexOnStartup" name="downloadRemoteIndexOnStartup"
+                   data-bind="checked: remoteRepository.downloadRemoteIndexOnStartup"/>
+          </div>
+        </div>
+
+      </fieldset>
+      <button data-bind="click: save" class="btn">${$.i18n.prop('save')}</button>
+      <button data-bind="click: displayGrid" class="btn">${$.i18n.prop('cancel')}</button>
+    </form>
+</script>
+
+<script id="remote-repository-scan-modal-tmpl" type='text/html'>
+    <div>
+      ${$.i18n.prop('remoterepository.download.remote.now')}: <input type="checkbox" id="remoterepository-scan-now">
+    </div>
+    <div>
+      ${$.i18n.prop('remoterepository.download.remote.full')}: <input type="checkbox" id="remoterepository-scan-full">
+    </div>
+</script>
+
+<script id="managed-repositories-bulk-save-tmpl" type='text/html'>
+  {{if bulkSave()}}
+    <a data-bind="click: updateModifiedManagedRepositories" class="btn btn-danger" href="#">${$.i18n.prop('save.all')}</a>
+  {{/if}}
+</script>
+
+<script id="remote-repositories-bulk-save-tmpl" type='text/html'>
+  {{if bulkSave()}}
+    <a data-bind="click: updateModifiedRemoteRepositories" class="btn btn-danger" href="#">${$.i18n.prop('save.all')}</a>
+  {{/if}}
+</script>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/repository-groups.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/repository-groups.html
new file mode 100644 (file)
index 0000000..43685e5
--- /dev/null
@@ -0,0 +1,163 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+-->
+<script id="repositoryGroupsMain" type="text/html">
+  <div class="page-header">
+    <h2><img src="images/applications-internet-2-32-32.png"/>${$.i18n.prop('repository.groups.list')}</h2>
+  </div>
+  <ul id="repository-groups-view-tabs" class="nav nav-tabs">
+    <li id="repository-groups-view-tabs-li-grid" class="active">
+      <a data-toggle="tab" href="#repository-groups-view" id="repository-groups-view-tabs-a-network-proxies-grid">
+        ${$.i18n.prop('repository-groups.grid.tab.title')}
+      </a>
+    </li>
+    <li id="repository-groups-view-tabs-li-edit">
+      <a data-toggle="tab" href="#repository-groups-edit" id="repository-groups-view-tabs-a-edit">${$.i18n.prop('add')}</a>
+    </li>
+
+  </ul>
+  <div id="repository-groups-view-tabs-content" class="tab-content">
+        <div id="repository-groups-view" class="tab-pane active">
+          <div id="repository-groups-table" data-bind='template:{name:"repository-groups-table-tmpl"}'>
+          </div>
+        </div>
+        <div id="repository-groups-edit" class="tab-pane">
+              <div class="row-fluid">
+                <div class="span5 dotted">
+                  <div id="repository-groups-edit-div" data-bind='template:{name:"repository-group-edit-tmpl"}'></div>
+                  <div id="repository-groups-edit-order-div" style="min-height: 80px"
+                     data-bind="sortable: { template: 'repository-group-edit-order-tmpl',data:repositoryGroup.managedRepositories,afterMove:repositoryMoved}">
+                  </div>
+                </div>
+
+                <div class="span5 dotted">
+                  <h5>${$.i18n.prop('repository.groups.available.repositories')}</h5>
+                  <br/>
+                  <div id="repository-groups-edit-available-repositories" style="min-height: 80px"
+                       data-bind="sortable: { template: 'repository-group-edit-order-tmpl',data:availableRepositories,afterMove:repositoryMoved}">
+
+                  </div>
+                </div>
+
+              </div>
+
+        </div>
+
+  </div>
+</script>
+
+<script id="repository-groups-table-tmpl" type="text/html">
+  <table class="table table-striped table-bordered">
+    <thead>
+      <th>${$.i18n.prop('repository.groups.groups.grid.header')}</th>
+      <th>${$.i18n.prop('repository.groups.repositories.grid.header')}</th>
+      <th>${$.i18n.prop('edit')}</th>
+      <th>${$.i18n.prop('delete')}</th>
+      <th>${$.i18n.prop('save')}</th>
+    </thead>
+    <tbody>
+    {{each(i, repositoryGroup) repositoryGroups}}
+      <tr data-bind="css:{ 'modified': repositoryGroup.modified()}">
+        <td>${repositoryGroup.id}</td>
+        <td>
+          <ul>
+          {{each(j,id) repositoryGroup.repositories()}}
+            <li>${id}</li>
+          {{/each}}
+          </ul>
+        </td>
+        <td>
+          <a href="#" data-bind="click: function(){editRepositoryGroup(repositoryGroup)}">
+            <img src="images/edit-find-22-22.png" title="${$.i18n.prop('edit')}">
+          </a>
+        </td>
+        <td>
+          <a href="#" data-bind="click: function(){deleteRepositoryGroup(repositoryGroup)}">
+            <img src="images/edit-cut-22-22.png" title="${$.i18n.prop('delete')}"/>
+          </a>
+        </td>
+        <td>
+          {{if repositoryGroup.modified()}}
+            <a href="#" class="btn btn-warning" data-bind="click: function(){saveRepositoryGroup(repositoryGroup)}">
+              ${$.i18n.prop('save')}
+            </a>
+          {{/if}}
+        </td>
+      </tr>
+    {{/each}}
+    </tbody>
+  </table>
+</script>
+
+<script id="repository-group-edit-tmpl" type="text/html">
+  <div class="row-fluid">
+  {{if update}}
+    <div class="dotted span8">
+      <blockquote>
+        ${repositoryGroup.id}
+        <br/>
+        <a href="${window.archivaRuntimeInfo.baseUrl}/repository/${repositoryGroup.id()}" target="_blank">
+          ${window.archivaRuntimeInfo.baseUrl}/repository/${repositoryGroup.id()}
+        </a>
+      </blockquote>
+    </div>
+  {{else}}
+    <div class="dotted span8">
+      <form id="repository-group-edit-form" class="well">
+        <fieldset id="repository-group-edit-fieldset">
+          <div class="control-group">
+            <label class="control-label" for="id">${$.i18n.prop('id')}</label>
+            <div class="controls">
+              <input type="text" class="xlarge required" id="id" name="id" size="15"
+                   data-bind="value: repositoryGroup.id,css:{'uneditable-input': update},readonly:update"/>
+            </div>
+          </div>
+        </fieldset>
+      </form>
+    </div>
+  {{/if}}
+  {{if repositoryGroup.modified()}}
+    <div class="span3">
+      <a href="#" class="btn btn-warning" data-bind="click: function(){saveRepositoryGroup(repositoryGroup)}">${$.i18n.prop('save')}</a>
+    </div>
+    <br/>
+  {{/if}}
+  </div>
+</script>
+
+<script id="repository-group-edit-order-tmpl" type="text/html">
+  <div class="well draggable-item">
+    <blockquote>
+      ${$data.id()}
+      <br/>
+      ${$data.name()}
+      <br/>
+      <a href="${window.archivaRuntimeInfo.baseUrl}/repository/${$data.id()}" target="_blank">
+        ${window.archivaRuntimeInfo.baseUrl}/repository/${$data.id()}
+      </a>
+      <br/>
+    </blockquote>
+
+  </div>
+</script>
+
+<script id="repository-group-delete-warning-tmpl" type='text/html'>
+    <div>
+      <span class="label label-warning">${$.i18n.prop('warning.not.undone.operation')}</span>
+    </div>
+</script>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/search.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/archiva/search.html
new file mode 100644 (file)
index 0000000..c0fd778
--- /dev/null
@@ -0,0 +1,785 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+-->
+
+<script id="browse-tmpl" type="text/html">
+  <div>
+    <div class="page-header">
+      <div><b>${$.i18n.prop('browse.repository')}</b></div>
+      <div id="selected_repository"></div>
+    </div>
+  </div>
+  <div id="main_browse_result">
+    <div id="main_browse_result_content" class="well">
+      <div id="browse_breadcrumb" data-bind='template:{name:"browse-breadcrumb-tmpl"}'></div>
+      <div id="browse_result" class="well" data-bind='template:{name:"browse-groups-tmpl"}'></div>
+      <div id="browse_artifact" class="well" data-bind='template:{name:"browse-artifact-tmpl"}'></div>
+      <div id="browse_artifact_detail" class="well" data-bind='template:{name:"browse-artifact-detail-tmpl"}'></div>
+    </div>
+  </div>
+</script>
+
+<script id="browse-groups-div-tmpl" type="text/html">
+  <div id="browse-groups-div" data-bind='template:{name:"browse-groups-tmpl"}'>
+  </div>
+</script>
+
+<script id="browse-groups-tmpl" type="text/html">
+  <div>
+    <ul>
+      <!-- if null we are on root level -->
+      {{if $root.parentBrowseViewModel}}
+        <li class="browse-list" data-bind="click:function(){displayParentGroupId()}">
+          <a href="#">..</a>
+        </li>
+      {{/if}}
+      {{each(i,browseResultEntry) browseResultEntries}}
+        {{if browseResultEntry.project}}
+          <li class="browse-list-project" data-bind="click:function(){displayProjectEntry(browseResultEntry.name)}">
+            <a href="#">${displayEntry(browseResultEntry.name)}</a>
+        {{else}}
+          <li class="browse-list" data-bind="click:function(){displayGroupId(browseResultEntry.name)}">
+            <a href="#" title="folder ${displayEntry(browseResultEntry.name)}">${displayEntry(browseResultEntry.name)}</a>
+        {{/if}}          
+          </li>
+      {{/each}}
+    </ul>
+  </div>
+</script>
+
+<script id="browse-breadcrumb-tmpl" type="text/html">
+  <ul class="breadcrumb">
+    <li>
+      <a href="#" data-bind="click: function(){ browseRoot()}"><img src="images/go-home.png"/></a>&nbsp;<span class="divider">/</span>
+    </li>
+    {{var number=breadCrumbEntries().length}}
+    {{each(i,breadCrumbEntry) breadCrumbEntries}}
+      <li>
+        {{if i==(number-1)}}
+          ${breadCrumbEntry.displayValue}
+        {{else}}
+          {{if breadCrumbEntry.artifact}}
+            <a href="#" data-bind="click: function(){displayArtifactDetail(breadCrumbEntry.groupId,breadCrumbEntry.artifactId,null,null)}">${breadCrumbEntry.displayValue}</a>
+          {{else}}
+            <a href="#" data-bind="click: function(){displayGroupId(breadCrumbEntry.groupId)}">${breadCrumbEntry.displayValue}</a>
+          {{/if}}
+        {{/if}}
+        {{if i<(number-1)}}
+          <span class="divider">/</span>
+        {{/if}}
+      </li>
+    {{/each}}
+    <li>
+      {{if number>0}}
+        <span class="divider" id="browse-autocomplete-divider">/</span>
+      {{/if}}
+      <input type="text" class="form-search span4" size="50" id="browse-autocomplete"/>
+    </li>
+  </ul>
+
+</script>
+
+<script id="browse-artifact-tmpl" type="text/html">
+  <div class="row-fluid">
+    <div class="span6">
+      <div class="page-header">
+        <h4>${$.i18n.prop('browse.artifact.display.artifactInfo')}</h4>
+      </div>
+      <div id="artifact-info" class="alert alert-info">
+        <table class="table table-condensed">
+          <tbody>
+            <tr>
+              <th>${$.i18n.prop('browse.artifact.groupId')}</th>
+              <td>${groupId}</td>
+            </tr>
+            <tr>
+              <th>${$.i18n.prop('browse.artifact.artifactId')}</th>
+              <td>${artifactId}</td>
+            </tr>
+            <tr>
+              <th>${$.i18n.prop('browse.artifact.name')}</th>
+              <td>${projectVersionMetadata.name}</td>
+            </tr>
+            <tr>
+              <th>${$.i18n.prop('browse.artifact.description')}</th>
+              <td>${projectVersionMetadata.description}</td>
+            </tr>
+            {{if projectVersionMetadata.mavenFacet}}
+            <tr>
+              <th>${$.i18n.prop('browse.artifact.packaging')}</th>
+              <td>${projectVersionMetadata.mavenFacet.packaging}</td>
+            </tr>
+            {{/if}}
+            {{if projectVersionMetadata.organization}}
+            <tr>
+              <th>${$.i18n.prop('browse.artifact.organization.name')}</th>
+              {{if projectVersionMetadata.organization.url}}
+                <td>
+                  <a href="${projectVersionMetadata.organization.url}" target="_blank">
+                    <img src="images/internet-web-browser.png" alt=""/>${projectVersionMetadata.organization.name}
+                  </a>
+                </td>
+              {{else}}
+                <td>${projectVersionMetadata.organization.name}</td>
+              {{/if}}
+            </tr>
+            {{/if}}
+            {{if projectVersionMetadata.issueManagement}}
+            <tr>
+              <th>${$.i18n.prop('browse.artifact.organization.issueManagement')}</th>
+              <td>
+                <a href="${projectVersionMetadata.issueManagement.url}" target="_blank">
+                  <img src="images/internet-web-browser.png" alt=""/>${projectVersionMetadata.issueManagement.system}
+                </a>
+              </td>
+            </tr>
+            {{/if}}
+          </tbody>
+        </table>
+      </div>
+    </div>
+    <div class="span4">
+      <div class="page-header">
+        <h4>${$.i18n.prop('browse.artifact.versions')}</h4>
+      </div>
+      <div class="alert alert-success">
+        <table class="table table-condensed">
+        {{each(i,version) versions}}
+          <tr>
+            <th><a href="#" data-bind="click: function(){displayArtifactVersionDetail(version)}">${version}</a></th>
+          </tr>
+        {{/each}}
+        </table>
+      </div>
+    </div>
+  </div>
+</script>
+<script id="search-artifacts-div-tmpl" type="text/html">
+    <div id="search-artifacts-div" data-bind='template:{name:"search-artifacts-form-tmpl"}'>
+    </div>
+</script>
+
+<script id="search-artifacts-form-tmpl" type="text/html">
+
+  <div class="page-header">
+    <h3>${$.i18n.prop('search.artifact.header')}</h3>
+  </div>
+  <div id="search-artifacts-tabs">
+    <div class="tabbable tabs-below">
+      <ul class="nav nav-tabs">
+        <li class="active" id="search-form-collapse-li">
+          <a data-toggle="tab" href="#search-form-collapse">${$.i18n.prop('search.artifact.form.header')}</a>
+        </li>
+          <li id="search-results-li">
+            <a data-toggle="tab" href="#search-results">${$.i18n.prop('search.artifact.results.header')}</a>
+          </li>
+      </ul>
+      <div class="tab-content">
+
+      <div id="search-form-collapse" class="tab-pane active">
+        <div class="tabbable tabs-below">
+          <ul class="nav nav-pills">
+            <li class="active">
+              <a href="#search-basic-form-pane" data-toggle="tab">${$.i18n.prop('search.artifact.search.form.basic')}</a>
+            </li>
+            <li>
+              <a href="#search-advanced-form-pane" data-toggle="tab">${$.i18n.prop('search.artifact.search.form.advanced')}</a>
+            </li>
+            <li>
+              <a href="#search-osgi-form-pane" data-toggle="tab">${$.i18n.prop('search.artifact.search.form.osgi')}</a>
+            </li>
+          </ul>
+          <div class="pill-content">
+            <div class="pill-pane active" id="search-basic-form-pane">
+              <form class="well form-inline" id="search-basic-form">
+                <fieldset>
+                  <div class="control-group" id="search-basic-repositories">
+                    <select data-placeholder="${$.i18n.prop('search.artifact.search.form.query.repositories')}"
+                            id="search-basic-repostories-select" class="chzn-select"
+                            multiple style="width:350px;" tabindex="4">
+                      <option value="all">${$.i18n.prop('search.artifact.search.form.repositories.all')}</option>
+                      {{each(i,repoId) observableRepoIds}}
+                        <option value="${repoId}">${repoId}</option>
+                      {{/each}}
+                    </select>
+                  </div>
+                  <div class="control-group">
+                    <label class="control-label" for="search-terms"></label>
+                    <div class="controls">
+                      <input type="text" class="input-medium search-query" id="search-terms" name="search-terms" size="50"
+                             data-bind="value: searchRequest().queryTerms" placeholder="${$.i18n.prop('search.artifact.search.form.query.terms')}"/>
+                    </div>
+                  </div>
+                  <button type="submit" id="btn-basic-search" class="btn btn-primary"
+                          data-loading-text="${$.i18n.prop('search.artifact.searching')}" data-bind="click: basicSearch">${$.i18n.prop('search.artifact.search.form.btn.search')}</button>
+                </fieldset>
+              </form>
+            </div>
+            <div class="pill-pane" id="search-advanced-form-pane">
+                <form class="well form-horizontal" id="search-advanced-form">
+                  <fieldset>
+                    <div class="control-group">
+                      <label class="control-label" for="groupId">${$.i18n.prop('search.artifact.search.form.query.groupId')}</label>
+                      <div class="controls">
+                        <input type="text" class="input-medium search-query" id="groupId" name="groupId" size="50"
+                               data-bind="value: searchRequest().groupId"/>
+                      </div>
+                    </div>
+                    <div class="control-group">
+                      <label class="control-label" for="artifactId">${$.i18n.prop('search.artifact.search.form.query.artifactId')}</label>
+                      <div class="controls">
+                        <input type="text" class="input-medium search-query" id="artifactId" name="artifactId" size="50"
+                               data-bind="value: searchRequest().artifactId"/>
+                      </div>
+                    </div>
+                    <div class="control-group">
+                      <label class="control-label" for="artifactId">${$.i18n.prop('search.artifact.search.form.query.version')}</label>
+                      <div class="controls">
+                        <input type="text" class="input-medium search-query" id="version" name="version" size="50"
+                               data-bind="value: searchRequest().version"/>
+                      </div>
+                    </div>
+                    <div class="control-group">
+                      <label class="control-label" for="artifactId">${$.i18n.prop('search.artifact.search.form.query.classifier')}</label>
+                      <div class="controls">
+                        <input type="text" class="input-medium search-query" id="classifier" name="classifier" size="50"
+                               data-bind="value: searchRequest().classifier"/>
+                      </div>
+                    </div>
+                    <div class="control-group">
+                      <label class="control-label" for="artifactId">${$.i18n.prop('search.artifact.search.form.query.packaging')}</label>
+                      <div class="controls">
+                        <input type="text" class="input-medium search-query" id="packaging" name="packaging" size="50"
+                               data-bind="value: searchRequest().packaging"/>
+                      </div>
+                    </div>
+                    <div class="control-group">
+                      <label class="control-label" for="artifactId">${$.i18n.prop('search.artifact.search.form.query.className')}</label>
+                      <div class="controls">
+                        <input type="text" class="input-medium search-query" id="className" name="className" size="50"
+                               data-bind="value: searchRequest().className"/>
+                      </div>
+                    </div>
+
+                  </fieldset>
+                  <button type="submit" id="btn-advanced-search" class="btn btn-primary"
+                          data-bind="click: advancedSearch">${$.i18n.prop('search.artifact.search.form.btn.search')}</button>
+
+                </form>
+            </div>
+            <div class="pill-pane" id="search-osgi-form-pane">
+                <form class="well form-horizontal" id="search-osgi-form">
+                  <fieldset>
+                    <div class="control-group">
+                      <label class="control-label" for="groupId">${$.i18n.prop('search.artifact.search.form.query.bundleSymbolicName')}</label>
+                      <div class="controls">
+                        <input type="text" class="input-medium search-query" id="bundleSymbolicName" name="bundleSymbolicName" size="50"
+                               data-bind="value: searchRequest().bundleSymbolicName"/>
+                      </div>
+                    </div>
+                    <div class="control-group">
+                      <label class="control-label" for="groupId">${$.i18n.prop('search.artifact.search.form.query.bundleVersion')}</label>
+                      <div class="controls">
+                        <input type="text" class="input-medium search-query" id="bundleVersion" name="bundleVersion" size="50"
+                               data-bind="value: searchRequest().bundleVersion"/>
+                      </div>
+                    </div>
+                    <div class="control-group">
+                      <label class="control-label" for="groupId">${$.i18n.prop('search.artifact.search.form.query.bundleExportPackage')}</label>
+                      <div class="controls">
+                        <input type="text" class="input-medium search-query" id="bundleExportPackage" name="bundleExportPackage" size="50"
+                               data-bind="value: searchRequest().bundleExportPackage"/>
+                      </div>
+                    </div>
+                    <div class="control-group">
+                      <label class="control-label" for="groupId">${$.i18n.prop('search.artifact.search.form.query.bundleExportService')}</label>
+                      <div class="controls">
+                        <input type="text" class="input-medium search-query" id="bundleExportService" name="bundleExportService" size="50"
+                               data-bind="value: searchRequest().bundleExportService"/>
+                      </div>
+                    </div>
+                    <div class="control-group">
+                      <label class="control-label" for="groupId">${$.i18n.prop('search.artifact.search.form.query.bundleImportPackage')}</label>
+                      <div class="controls">
+                        <input type="text" class="input-medium search-query" id="bundleImportPackage" name="bundleImportPackage" size="50"
+                               data-bind="value: searchRequest().bundleImportPackage"/>
+                      </div>
+                    </div>
+                    <div class="control-group">
+                      <label class="control-label" for="groupId">${$.i18n.prop('search.artifact.search.form.query.bundleRequireBundle')}</label>
+                      <div class="controls">
+                        <input type="text" class="input-medium search-query" id="bundleRequireBundle" name="bundleRequireBundle" size="50"
+                               data-bind="value: searchRequest().bundleRequireBundle"/>
+                      </div>
+                    </div>
+                  </fieldset>
+                  <button type="submit" id="btn-osgi-search" class="btn btn-primary"
+                          data-bind="click: advancedSearch">${$.i18n.prop('search.artifact.search.form.btn.search')}</button>
+
+                </form>
+            </div>
+          </div>
+        </div>
+      </div>
+
+
+      <div id="search-results" class="tab-pane">
+        <div class="row">
+          <div class="span3">
+            <a href="#" class="btn btn-warning" data-bind="click: removeFilter" id="remove-filter-id">${$.i18n.prop('search.artifact.result.filter')}</a>
+          </div>
+          <div class="span4" id="search-result-number-div">
+
+          </div>
+        </div>
+        <table class="table table-striped table-bordered" id="search-results-grid">
+        </table>
+        <div id="search-results-view-grid-pagination"></div>
+      </div>
+
+      </div>
+    </div>
+  </div>
+
+</script>
+
+<script type="text/html" id="search-result-number-div-tmpl">
+  <blockquote>
+      ${$.i18n.prop('search.artifact.result.size')}:&nbsp;${resultViewModel.artifacts().length}
+  </blockquote>
+
+</script>
+
+<script id="search-results-view-grid-tmpl" type="text/html">
+    <thead>
+        <tr>
+
+            <th title="${$.i18n.prop('search.artifact.results.groupId')}">${$.i18n.prop('search.artifact.results.groupId')}</th>
+            <th title="${$.i18n.prop('search.artifact.results.artifactId')}">${$.i18n.prop('search.artifact.results.artifactId')}</th>
+            <th title="${$.i18n.prop('search.artifact.results.version')}">${$.i18n.prop('search.artifact.results.version')}</th>
+            <th title="${$.i18n.prop('search.artifact.results.classifier')}">${$.i18n.prop('search.artifact.results.classifier')}</th>
+        </tr>
+        <tr>
+
+            <th title="${$.i18n.prop('search.artifact.results.groupId')}">
+              <input type="text" class="form-search" id="search-filter-auto-groupId"
+                     placeholder="${$.i18n.prop('search.artifact.result.grid.filter')}"/>
+            </th>
+            <th title="${$.i18n.prop('search.artifact.results.artifactId')}">
+              <input type="text" class="form-search" id="search-filter-auto-artifactId"
+                     placeholder="${$.i18n.prop('search.artifact.result.grid.filter')}"/>
+            </th>
+            <th title="${$.i18n.prop('search.artifact.results.version')}">
+              <input type="text" class="form-search" id="search-filter-auto-version"
+                     placeholder="${$.i18n.prop('search.artifact.result.grid.filter')}"/>
+            </th>
+            <th title="${$.i18n.prop('search.artifact.results.classifier')}">
+              <input type="text" class="form-search" id="search-filter-auto-classifier"
+                     placeholder="${$.i18n.prop('search.artifact.result.grid.filter')}"/>
+            </th>
+
+        </tr>
+    </thead>
+    <tbody>
+    {{each(i, row) itemsOnCurrentPage()}}
+      <tr>
+        <td><a href="#" data-bind="click: function(){groupIdView(row)}">${row.groupId}</a></td>
+        <td><a href="#" data-bind="click: function(){artifactIdView(row)}">${row.artifactId}</a></td>
+        <td><a href="#" data-bind="click: function(){artifactDetailView(row)}">${row.version}</a></td>
+        <td>${row.classifier}</td>
+      </tr>
+    {{/each}}
+    </tbody>
+</script>
+
+
+<script id="selected_repository_tmpl" type="text/html">
+  <select id="select_browse_repository" onchange="changeBrowseRepository()">
+    <option value="">All</option>
+    {{each(i,repository) repositories}}
+      {{if selected && selected==repository.id}}
+        <option value="${repository.id}" selected>${repository.name}</option>
+      {{else}}
+        <option value="${repository.id}">${repository.name}</option>
+      {{/if}}
+    {{/each}}
+  </select>
+</script>
+
+<script id="browse-artifact-detail-tmpl" type="text/html">
+    <ul id="artifact-details-tabs" class="nav nav-tabs">
+      <li class="active">
+        <a data-toggle="tab" href="#artifact-details-info-content">${$.i18n.prop('artifact.detail.tab.header.info')}</a>
+      </li>
+      <li>
+        <a data-toggle="tab" href="#artifact-details-dependencies-content">${$.i18n.prop('artifact.detail.tab.header.dependencies')}</a>
+      </li>
+      <li>
+        <a data-toggle="tab" href="#artifact-details-dependency-tree-content">${$.i18n.prop('artifact.detail.tab.header.dependency.tree')}</a>
+      </li>
+      <li>
+        <a data-toggle="tab" href="#artifact-details-used-by-content">${$.i18n.prop('artifact.detail.tab.header.used.by')}</a>
+      </li>
+      <li>
+        <a data-toggle="tab" href="#artifact-details-mailing-list-content">${$.i18n.prop('artifact.detail.tab.header.mailing.list')}</a>
+      </li>
+      <li>
+        <a data-toggle="tab" href="#artifact-details-metadatas-content">${$.i18n.prop('artifact.detail.tab.header.metadatas')}</a>
+      </li>
+    </ul>
+    <div class="tab-content">
+         <div id="artifact-details-info-content" class="tab-pane active">
+        <blockquote>${projectVersionMetadata.description}</blockquote>
+        <div class="row-fluid">
+          <div class="span6">
+            <table class="table">
+              <tbody>
+                <tr>
+                  <th>${$.i18n.prop('browse.artifact.groupId')}</th>
+                  <td>${groupId}</td>
+                </tr>
+                <tr>
+                  <th>${$.i18n.prop('browse.artifact.artifactId')}</th>
+                  <td>${artifactId}</td>
+                </tr>
+                <tr>
+                  <th>${$.i18n.prop('browse.artifact.version')}</th>
+                  <td>${version}</td>
+                </tr>
+                <tr>
+                  <th>${$.i18n.prop('browse.artifact.packaging')}</th>
+                  <td>${projectVersionMetadata.mavenFacet.packaging}</td>
+                </tr>
+                {{if projectVersionMetadata.mavenFacet.parent }}
+                <tr>
+                  <th>${$.i18n.prop('browse.artifact.parent')}</th>
+                  <td>
+                    <a href="#" data-bind="click: displayParent">
+                    ${projectVersionMetadata.mavenFacet.parent.groupId}:${projectVersionMetadata.mavenFacet.parent.artifactId}:${projectVersionMetadata.mavenFacet.parent.version}
+                    </a>
+                  </td>
+                </tr>
+                {{/if}}
+              </tbody>
+            </table>
+          </div>
+          <div class="span6">
+            <h4>${$.i18n.prop('browse.artifact.pom.snippet')}</h4>
+              <pre class="prettyprint">&lt;dependency&gt;<br/>&nbsp;&nbsp;&lt;groupId&gt;${groupId}&lt;/groupId&gt;<br/>&nbsp;&nbsp;&lt;artifactId&gt;${artifactId}&lt;/artifactId&gt;<br/>&nbsp;&nbsp;&lt;version&gt;${version}&lt;/version&gt;<br/>&lt;/dependency&gt;</pre>
+          </div>
+        </div>
+        <div>
+          <div class="page-header">
+            <h4>${$.i18n.prop('browse.artifact.other.details')}</h4>
+          </div>
+          <div>
+            <div class="row-fluid">
+              <div class="span9">
+                <table class="table">
+                  <tbody>
+                    {{if projectVersionMetadata.url}}
+                    <tr>
+                      <th>${$.i18n.prop('browse.artifact.url')}</th>
+                      <td><a href="${projectVersionMetadata.url}" target="_blank">${projectVersionMetadata.url}</a></td>
+                    </tr>
+                    {{/if}}
+                    {{if projectVersionMetadata.organization}}
+                    <tr>
+                      <th>${$.i18n.prop('browse.artifact.organization.name')}</th>
+                      {{if projectVersionMetadata.organization.url}}
+                        <td>
+                          <a href="${projectVersionMetadata.organization.url}" target="_blank">
+                            <img src="images/internet-web-browser.png" alt=""/>${projectVersionMetadata.organization.name}
+                          </a>
+                        </td>
+                      {{else}}
+                        <td>${projectVersionMetadata.organization.name}</td>
+                      {{/if}}
+                    </tr>
+                    {{/if}}
+                    {{each(i,license) projectVersionMetadata.licenses}}
+                    <tr>
+                      <th>${$.i18n.prop('browse.artifact.license')}</th>
+                      {{if license.url}}
+                        <td>
+                          <a href="${license.url}" target="_blank">
+                            <img src="images/internet-web-browser.png" alt=""/>${license.name}
+                          </a>
+                        </td>
+                      {{else}}
+                        <td>${license.name}</td>
+                      {{/if}}
+                      </tr>
+                    {{/each}}
+                    {{if projectVersionMetadata.issueManagement}}
+                    <tr>
+                      <th>${$.i18n.prop('browse.artifact.organization.issueManagement')}</th>
+                      <td>
+                        <a href="${projectVersionMetadata.issueManagement.url}" target="_blank">
+                          <img src="images/internet-web-browser.png" alt=""/>${projectVersionMetadata.issueManagement.system}
+                        </a>
+                      </td>
+                    </tr>
+                    {{/if}}
+                    {{if projectVersionMetadata.ciManagement}}
+                    <tr>
+                      <th>${$.i18n.prop('browse.artifact.organization.ciManagement')}</th>
+                      <td>
+                        <a href="${projectVersionMetadata.ciManagement.url}" target="_blank">
+                          <img src="images/internet-web-browser.png" alt=""/>${projectVersionMetadata.ciManagement.system}
+                        </a>
+                      </td>
+                    </tr>
+                    {{/if}}
+                  </tbody>
+                </table>
+              </div>
+            </div>
+          </div>
+        </div>
+        {{if projectVersionMetadata.scm}}
+        <div>
+          <div class="page-header">
+            <h4>${$.i18n.prop('browse.artifact.scm')}</h4>
+          </div>
+          <div>
+            <div class="row-fluid">
+              <div class="span12">
+                <table class="table">
+                  <tbody>
+                    <tr>
+                      <th>${$.i18n.prop('browse.artifact.scm.connection')}</th>
+                      <td>${projectVersionMetadata.scm.connection}</td>
+                    </tr>
+                    <tr>
+                      <th>${$.i18n.prop('browse.artifact.scm.devconnection')}</th>
+                      <td>${projectVersionMetadata.scm.developerConnection}</td>
+                    </tr>
+                    <tr>
+                      <th>${$.i18n.prop('browse.artifact.scm.viewer')}</th>
+                      <td>${projectVersionMetadata.scm.url}</td>
+                    </tr>
+                  </tbody>
+                </table>
+              </div>
+            </div>
+          </div>
+        </div>
+        {{/if}}
+         </div>
+
+
+         <div id="artifact-details-dependencies-content" class="tab-pane">
+        <table class="table">
+          <tbody>
+          {{if projectVersionMetadata.dependencies && projectVersionMetadata.dependencies.length>0}}
+          {{each(i,dependency) projectVersionMetadata.dependencies}}
+            <tr>
+              <th>${dependency.artifactId}</th>
+            </tr>
+            <tr>
+              <td>
+                {{var entries=dependency.crumbEntries()}}
+                {{each(j,crumbEntry) entries}}
+                  {{if j < entries.length - 2}}
+                    <a href="#" data-bind="click: function(){displayGroup(crumbEntry.groupId)}">${crumbEntry.displayValue}</a>
+                  {{else j == entries.length - 2}}
+                    <a href="#" data-bind="click: function(){displayArtifactDetailView(crumbEntry.groupId,crumbEntry.artifactId)}">${crumbEntry.displayValue}</a>
+                  {{else j == entries.length - 1}}
+                    &nbsp;|&nbsp;<b>${$.i18n.prop('browse.artifact.version')}:</b>&nbsp;
+                     <a href="#" data-bind="click: function(){displayArtifactVersionDetailViewModel(crumbEntry.groupId,crumbEntry.artifactId,crumbEntry.version)}">${dependency.version}</a>&nbsp;
+                  {{/if}}
+                  {{if j < entries.length - 2}}
+                     &nbsp;/&nbsp;
+                  {{/if}}
+                {{/each}}
+
+                {{if dependency.scope}}
+                  |&nbsp;<b>${$.i18n.prop('browse.artifact.scope')}:</b>&nbsp;${dependency.scope}
+                {{/if}}
+              </td>
+            </tr>
+          {{/each}}
+          {{else}}
+            ${$.i18n.prop('browse.artifact.dependencies.none')}
+          {{/if}}
+          </tbody>
+        </table>
+         </div>
+
+      <div id="artifact-details-dependency-tree-content" class="tab-pane">
+      </div>
+
+      <div id="artifact-details-used-by-content" class="tab-pane"></div>
+
+      <div id="artifact-details-mailing-list-content" class="tab-pane">
+        {{if projectVersionMetadata.mailingLists && projectVersionMetadata.mailingLists.length>0}}
+          <div id="accordion_mailing_lists" class="accordion">
+          {{each(i,mailingList) projectVersionMetadata.mailingLists}}
+            <div class="accordion-group">
+              <div class="accordion-heading">
+                <a class="accordion-toggle" href="#ml_collapse_${i}" data-parent="#accordion_mailing_lists" data-toggle="collapse">${mailingList.name}</a>
+              </div>
+              {{if i==0}}
+                <div id="ml_collapse_${i}" class="accordion-body collapse in">
+              {{else}}
+                <div id="ml_collapse_${i}" class="accordion-body collapse">
+              {{/if}}
+                <div class="accordion-inner">
+                  {{if mailingList.subscribeAddress}}
+                  <div>
+                    <b>${$.i18n.prop('browse.artifact.mailingList.subscribe')}</b>: <a href="mailto:${mailingList.subscribeAddress}">${mailingList.subscribeAddress}</a>
+                  </div>
+                  {{/if}}
+                  {{if mailingList.postAddress}}
+                  <div>
+                    <b>${$.i18n.prop('browse.artifact.mailingList.post')}</b>: <a href="mailto:${mailingList.postAddress}">${mailingList.postAddress}</a>
+                  </div>
+                  {{/if}}
+                  {{if mailingList.unsubscribeAddress}}
+                  <div>
+                    <b>${$.i18n.prop('browse.artifact.mailingList.unsubscribe')}</b>: <a href="mailto:${mailingList.unsubscribeAddress}">${mailingList.unsubscribeAddress}</a>
+                  </div>
+                  {{/if}}
+                  {{if mailingList.mainArchiveUrl}}
+                  <div>
+                    <b>${$.i18n.prop('browse.artifact.mailingList.mainArchiveUrl')}</b>: <a href="${mailingList.mainArchiveUrl}" target="_blank">${mailingList.mainArchiveUrl}</a>
+                  </div>
+                  {{/if}}
+                  {{if mailingList.otherArchives && mailingList.otherArchives.length>0}}
+                  <div>
+                    <b>${$.i18n.prop('browse.artifact.mailingList.otherArchivesUrls')}:</b>
+                    <ul>
+                    {{each(j,otherArchive) mailingList.otherArchives}}
+                      <li><b>${$.i18n.prop('browse.artifact.mailingList.otherArchiveUrl')}</b>: <a href="${otherArchive}" target="_blank">${otherArchive}</a></li>
+                    {{/each}}
+                    </ul>
+                  </div>
+                  {{/if}}
+                </div>
+              </div>
+            </div>
+          {{/each}}
+          </div>
+        {{else}}
+          ${$.i18n.prop('browse.artifact.mailingList.none')}
+        {{/if}}
+      </div>
+
+      <div id="artifact-details-metadatas-content" class="tab-pane">
+        <table class="table table-striped table-bordered" id="artifact-details-metadatas-content-table"
+               data-bind="simpleGrid: gridMetatadasViewModel,simpleGridTemplate:'artifact_metadata_properties_tmpl',pageLinksId:'artifactMetadata_Pagination'">
+
+        </table>
+        <div id="artifactMetadata_Pagination"></div>
+        {{if hasSavePropertyKarma()}}
+          <a href="#" class="btn btn-primary" data-bind="click: addProperty">${$.i18n.prop('browse.artifact.metadatas.add')}</a>
+        {{/if}}
+      </div>
+
+    </div>
+</script>
+
+<script id="dependency_tree_tmpl" type="text/html">
+  <ul>
+  {{each(i,treeEntry) treeEntries}}
+    <li>
+        {{var entries=treeEntry.artifact.crumbEntries()}}
+        {{each(j,crumbEntry) entries}}
+          {{if j < entries.length - 2}}
+            <a href="#" onclick="generalDisplayGroup(encodeURIComponent('${crumbEntry.groupId}'))">${crumbEntry.displayValue}</a>
+          {{else j == entries.length - 2}}
+            <a href="#" onclick="generalDisplayArtifactDetailView(encodeURIComponent('${crumbEntry.groupId}'),encodeURIComponent('${crumbEntry.artifactId}'))">${crumbEntry.displayValue}</a>
+          {{else j == entries.length - 1}}
+            &nbsp;|&nbsp;<b>${$.i18n.prop('browse.artifact.version')}:</b>&nbsp;
+             <a href="#" onclick="generalDisplayArtifactVersionDetailViewModel(encodeURIComponent('${crumbEntry.groupId}'),encodeURIComponent('${crumbEntry.artifactId}'),encodeURIComponent('${crumbEntry.version}'))">${crumbEntry.version}</a>&nbsp;
+          {{/if}}
+          {{if j < entries.length - 2}}
+             &nbsp;/&nbsp;
+          {{/if}}
+        {{/each}}
+    </li>
+    {{if treeEntry.childs.length>0}}
+      {{tmpl({treeEntries:treeEntry.childs}) "#dependency_tree_tmpl"}}
+    {{/if}}
+  {{/each}}
+  </ul>
+</script>
+
+<script id="dependees_tmpl" type="text/html">
+    <ul>
+    {{each(i,artifact) artifacts}}
+      <li>
+          {{var entries=artifact.crumbEntries()}}
+          {{each(j,crumbEntry) entries}}
+            {{if j < entries.length - 2}}
+              <a href="#" onclick="generalDisplayGroup(encodeURIComponent('${crumbEntry.groupId}'))">${crumbEntry.displayValue}</a>
+            {{else j == entries.length - 2}}
+              <a href="#" onclick="generalDisplayArtifactDetailView(encodeURIComponent('${crumbEntry.groupId}'),encodeURIComponent('${crumbEntry.artifactId}'))">${crumbEntry.displayValue}</a>
+            {{else j == entries.length - 1}}
+              &nbsp;|&nbsp;<b>${$.i18n.prop('browse.artifact.version')}:</b>&nbsp;
+               <a href="#" onclick="generalDisplayArtifactVersionDetailViewModel(encodeURIComponent('${crumbEntry.groupId}'),encodeURIComponent('${crumbEntry.artifactId}'),encodeURIComponent('${crumbEntry.version}'))">${crumbEntry.version}</a>&nbsp;
+            {{/if}}
+            {{if j < entries.length - 2}}
+               &nbsp;/&nbsp;
+            {{/if}}
+          {{/each}}
+      </li>
+    {{/each}}
+    </ul>
+</script>
+
+<script id="artifact_metadata_properties_tmpl" type="text/html">
+    <thead>
+      <tr>
+        <th title="${$.i18n.prop('browse.artifact.metadatas.key')}">${$.i18n.prop('browse.artifact.metadatas.key')}</th>
+        <th title="${$.i18n.prop('browse.artifact.metadatas.value')}">${$.i18n.prop('browse.artifact.metadatas.value')}</th>
+        <th title="${$.i18n.prop('browse.artifact.metadatas.delete')}">${$.i18n.prop('browse.artifact.metadatas.delete')}</th>
+        <th title="${$.i18n.prop('browse.artifact.metadatas.save')}">${$.i18n.prop('browse.artifact.metadatas.save')}</th>
+      </tr>
+
+    </thead>
+    <tbody>
+    {{each(i, row) itemsOnCurrentPage()}}
+      <tr>
+        {{if row.editable && hasSavePropertyKarma()}}
+          <td><input type="text" data-bind="value: row.key"/></td>
+        {{else}}
+          <td>${row.key}</td>
+        {{/if}}
+        <td>
+          {{if hasSavePropertyKarma()}}
+            <input type="text" data-bind="value: row.value"/>
+          {{else}}
+            ${row.value}
+          {{/if}}
+        </td>
+        <td>
+          {{if hasDeletePropertyKarma()}}
+          <a href="#" class="btn btn-danger" data-bind="click: function(){deleteProperty(row)}">${$.i18n.prop('browse.artifact.metadatas.delete')}</a>
+          {{/if}}
+        </td>
+        <td>
+          {{if row.modified && hasSavePropertyKarma()}}
+            <a href="#" class="btn btn-warning" data-bind="click: function(){saveProperty(row)}">${$.i18n.prop('browse.artifact.metadatas.save')}</a>
+          {{/if}}
+        </td>
+      </tr>
+    {{/each}}
+    </tbody>
+</script>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/login.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/login.html
new file mode 100644 (file)
index 0000000..871d137
--- /dev/null
@@ -0,0 +1,48 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+-->
+<div id="modal-login" class="modal hide fade">
+  <div class="modal-header">
+    <a href="#" class="close" data-dismiss="modal">&times;</a>
+    <h3>${$.i18n.prop('login.section.title')}</h3>
+  </div>
+  <div class="modal-body" id="modal-login-content">
+      <form id="user-login-form" class="form-horizontal">
+        <div id="modal-login-err-message" class="alert alert-error" style="display:none"></div>
+        <fieldset>
+          <div class="control-group">
+            <label class="control-label" for="user-login-form-username">${$.i18n.prop('username')}</label>
+            <div class="controls">
+              <input type="text" id="user-login-form-username" name="user-login-form-username" class="required" placeholder="${$.i18n.prop('login.username.placehoder')}"/>
+            </div>
+          </div>
+          <div class="control-group">
+            <label class="control-label" for="user-login-form-password">${$.i18n.prop('password')}</label>
+            <div class="controls">
+              <input type="password" id="user-login-form-password" name="user-login-form-password" class="required" placeholder="${$.i18n.prop('login.password.placehoder')}"/>
+            </div>
+          </div>
+        </fieldset>
+      </form>
+  </div>
+  <div class="modal-footer" id="modal-login-footer">
+    <button class="btn btn-primary" id="modal-login-ok">${$.i18n.prop('login')}</button>
+    <button class="btn btn-info" id="modal-login-password-reset">${$.i18n.prop('password.reset')}</button>
+  </div>
+</div>
+
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/password-change-form.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/password-change-form.html
new file mode 100644 (file)
index 0000000..d682788
--- /dev/null
@@ -0,0 +1,55 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+-->
+<div id="modal-password-change" class="modal hide fade">
+  <div class="modal-header">
+    <a href="#" class="close" data-dismiss="modal">&times;</a>
+    <h3>${$.i18n.prop('password.section.title')}</h3>
+  </div>
+  <div class="modal-body" id="modal-password-change-content">
+      <form id="password-change-form" class="form-horizontal">
+        <div id="modal-password-change-err-message" class="alert-message error" style="display:none"></div>
+        <fieldset>
+          <!-- part displayed only when a logged user want to change password will be hide when validate user registration -->
+          <div class="control-group" id="password-change-form-current-password-div">
+            <label class="control-label" for="password-change-form-current-password">${$.i18n.prop('password.existing')}</label>
+            <div class="controls">
+              <input type="password" id="password-change-form-current-password" name="password-change-form-current-password" class="required" value=""/>
+            </div>
+          </div>
+
+          <div class="control-group">
+            <label class="control-label" for="passwordChangeFormNewPassword">${$.i18n.prop('password.new')}</label>
+            <div class="controls">
+              <input type="password" id="passwordChangeFormNewPassword" name="passwordChangeFormNewPassword" class="required" value=""/>
+            </div>
+          </div>
+
+          <div class="control-group">
+            <label class="control-label"  for="passwordChangeFormNewPasswordConfirm">${$.i18n.prop('password.new.confirm')}</label>
+            <div class="controls">
+              <input type="password" id="passwordChangeFormNewPasswordConfirm" name="passwordChangeFormNewPasswordConfirm" class="required" value=""/>
+            </div>
+          </div>
+        </fieldset>
+      </form>
+  </div>
+  <div class="modal-footer" id="modal-password-change-footer">
+    <button class="btn btn-primary" onclick="return" id="modal-change-password-ok">${$.i18n.prop('ok')}</button>
+  </div>
+</div>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/register-form.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/register-form.html
new file mode 100644 (file)
index 0000000..931e72d
--- /dev/null
@@ -0,0 +1,53 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+-->
+<div id="modal-register" class="modal hide fade">
+  <div class="modal-header">
+    <a href="#" class="close" data-dismiss="modal">&times;</a>
+    <h3>${$.i18n.prop('register.section.title')}</h3>
+  </div>
+  <div class="modal-body" id="modal-register-content">
+      <form id="user-register-form" class="form-horizontal">
+        <div id="modal-register-err-message" class="alert-message error" style="display:none"></div>
+        <fieldset>
+          <div class="control-group">
+            <label class="control-label" for="user-register-form-username">${$.i18n.prop('username')}</label>
+            <div class="controls">
+              <input type="text" id="user-register-form-username" name="user-register-form-username" class="required" />
+            </div>
+          </div>
+          <div class="control-group">
+            <label class="control-label" for="user-register-form-fullname">${$.i18n.prop('full.name')}</label>
+            <div class="controls">
+              <input type="text" id="user-register-form-fullname" name="user-register-form-fullname" class="required" />
+            </div>
+          </div>
+          <div class="control-group">
+            <label class="control-label" for="user-register-form-email">${$.i18n.prop('email')}</label>
+            <div class="controls">
+              <input type="text" id="user-register-form-email" name="user-register-form-email" class="required email" />
+            </div>
+          </div>
+
+        </fieldset>
+      </form>
+  </div>
+  <div class="modal-footer" id="modal-register-footer">
+      <button class="btn btn-primary" id="modal-register-ok">${$.i18n.prop('register')}</button>
+  </div>
+</div>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/roles-tmpl.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/roles-tmpl.html
new file mode 100644 (file)
index 0000000..7441949
--- /dev/null
@@ -0,0 +1,232 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+-->
+<script id="rolesTabs" type="text/html">
+  <div class="page-header">
+    <h2>${$.i18n.prop('roles.management.header')}</h2>
+  </div>
+
+  <ul id="roles-view-tabs" class="nav nav-tabs" data-target="roles-view-tabs-content">
+    <li class="active" id="roles-view-tabs-li-roles-grid">
+      <a data-toggle="tab" href="#roles-view" id="roles-view-tabs-a-roles-grid">${$.i18n.prop('roles.grid.tab.title')}</a>
+    </li>
+    <li id="roles-view-tabs-li-roles-edit">
+      <a data-toggle="tab" href="#role-edit">${$.i18n.prop('edit')}</a>
+    </li>
+  </ul>
+  <div id="roles-view-tabs-content" class="tab-content">
+    <div id="roles-view" class="tab-pane">
+        <div data-bind="style: { display: bulkSave() ? '' : 'none' }">
+          <a data-bind="click: updateModifiedRoles" class="btn btn-danger" href="#">${$.i18n.prop('save.all')}</a>
+          <br/>
+        </div>
+        <table class="table table-striped table-bordered" id="rolesTable"
+               data-bind="simpleGrid: gridViewModel,simpleGridTemplate:'ko_rolesGrid',pageLinksId:'rolesPagination'">
+        </table>
+        <div id="rolesPagination"></div>
+    </div>
+    <div id="role-edit" class="tab-pane" data-bind="template: {name:'editRoleTab',data: currentRole}"></div>
+  </div>
+
+</script>
+
+<script id="editRoleTab" type="text/html">
+  <div class="accordion" id="edit-role-accordion">
+    <div class="accordion-group">
+      <div class="accordion-heading">
+        <h3>
+          <a class="accordion-toggle" href="#role-collapse" data-parent="#edit-role-accordion" data-toggle="collapse">${$.i18n.prop('role')}</a>
+        </h3>
+      </div>
+      <div id="role-collapse" class="accordion-body collapse in">
+        <table class="table table-bordered" id="editRoleTable">
+          <tbody>
+            <tr>
+              <td>${$.i18n.prop('name')}:</td>
+              <td id="role-edit-name">${$data.name}</td>
+            </tr>
+            <tr>
+              <td>${$.i18n.prop('description')}:</td>
+              <td><input type="text" id="role-edit-description" data-bind="value: description"></td>
+            </tr>
+            <tr>
+              <td colspan="2">
+                <div class="pull-left">
+                  <button class="btn" id="role-edit-description-save" data-bind="click: saveRoleDescription">${$.i18n.prop('save')}</button>
+                </div>
+              </td>
+            </tr>
+          </tbody>
+        </table>
+
+        <div class="page-header">
+          <h3>${$.i18n.prop('role.model.parent.roles')}</h3>
+        </div>
+        {{if $data.parentRoleNames}}
+        <ul>
+          {{each $data.parentRoleNames}}
+            <li>${$value}</li>
+          {{/each}}
+        </ul>
+        {{/if}}
+
+        <div class="page-header">
+          <h3>${$.i18n.prop('role.model.child.roles')}</h3>
+        </div>
+        {{if $data.childRoleNames}}
+        <ul>
+          {{each $data.childRoleNames}}
+            <li>${$value}</li>
+          {{/each}}
+        </ul>
+        {{/if}}
+
+        <div class="page-header">
+          <h3>${$.i18n.prop('permissions')}</h3>
+        </div>
+        {{if $data.permissions}}
+          <table class="table table-striped table-bordered" id="rolePermissionsTable">
+            <thead>
+              <tr>
+                <th>${$.i18n.prop('name')}</th>
+                <th>${$.i18n.prop('role.operation')}</th>
+                <th>${$.i18n.prop('role.resource')}</th>
+              </tr>
+            </thead>
+            <tbody>
+              {{each permissions}}
+              <tr>
+                <td>${$value.name}</td>
+                {{if $value.operation }}
+                  <td>${$value.operation().name}</td>
+                {{else}}
+                  <td></td>
+                {{/if}}
+                {{if $value.resource }}
+                  <td>${$value.resource().identifier}</td>
+                {{else}}
+                  <td></td>
+                {{/if}}
+              </tr>
+             {{/each}}
+            </tbody>
+          </table>
+        {{/if}}
+      </div>
+    </div>
+    <div class="accordion-group>">
+      <div class="accordion-heading">
+        <h3>
+          <a class="accordion-toggle" href="#role-users-collapse" data-parent="#edit-role-accordion" data-toggle="collapse">${$.i18n.prop('role.edit.section.users')}</a>
+        </h3>
+      </div>
+      <div id="role-users-collapse" class="accordion-body collapse">
+        {{if $data.parentsRolesUsers}}
+        <div class="page-header">
+          <h3>${$.i18n.prop('role.edit.users.defined.in.parent.roles')}</h3>
+        </div>
+        <ul>
+        {{each $data.parentsRolesUsers}}
+          <li>${$value.fullName} - ( ${$value.username} - ${$value.email} ) </li>
+        {{/each}}
+        </ul>
+        {{/if}}
+
+        <ul id="role-edit-users-tabs" class="nav nav-tabs">
+          <li class="active" id="role-view-users-li">
+            <a data-toggle="tab" href="#role-view-users">${$.i18n.prop('role.edit.users.list')}</a>
+          </li>
+          <li id="role-edit-users-li">
+            <a data-toggle="tab" href="#role-edit-users">${$.i18n.prop('edit')}</a>
+          </li>
+        </ul>
+
+        <div class="pill-content" id="role-edit-users-tabs-content">
+          <div id="role-view-users" class="active pill-pane">
+            <div class="page-header">
+              <h3>${$.i18n.prop('role.edit.users.defined.in.current.role')}</h3>
+            </div>
+            <div id="role-list-users">
+              {{if users().length>0}}
+              <ul>
+                {{each(j, user) users()}}
+                <li>${user.fullName()} - ( ${user.username()} - ${user.email()} ) </li>
+                {{/each}}
+              </ul>
+              {{else}}
+                ${$.i18n.prop('role.edit.no.user.defined')}
+              {{/if}}
+            </div>
+          </div>
+
+          <div id="role-edit-users" class="clearfix ar-multiselect pill-pane">
+
+            <div class="ar-multiselect-column ar-multiselect-left">
+              <select data-bind="options: otherUsers ,optionsText: 'username',selectedOptions:selectedOtherUsers" multiple="true" id="role-edit-available-users"></select>
+            </div>
+            <div class="ar-multiselect-column ar-multiselect-center">
+              <ul style="list-style: none">
+                <li><input class="btn" id="role-edit-users-add-user" type="button" data-bind="click: addUser" value="&gt;"/></li>
+                <li><input class="btn" id="role-edit-users-remove-user" type="button" data-bind="click: removeUser" value="&lt;"/></li>
+              </ul>
+            </div>
+            <div class="ar-multiselect-column ar-multiselect-right">
+              <select data-bind="options: users ,optionsText: 'username',selectedOptions:selectedUsers" multiple="true" id="role-edit-affected-users"></select>
+            </div>
+            <button class="btn" id="role-edit-users-save" data-bind="click: saveUsers">${$.i18n.prop('save')}</button>
+          </div>
+        </div>
+      </div>
+    </div>
+  </div>
+</script>
+
+<script id='ko_rolesGrid' type='text/html'>
+  <thead>
+      <tr>
+        {{each(i, columnDefinition) columns}}
+          <th>${ columnDefinition.headerText }</th>
+        {{/each}}
+        <th>${$.i18n.prop('edit')}</th>
+        <th>${$.i18n.prop('save')}</th>
+      </tr>
+  </thead>
+  <tbody>
+      {{each(i, row) itemsOnCurrentPage()}}
+          <tr data-bind="css:{ 'modified': row.modified()||row.usersModified()}">
+              {{each(j, columnDefinition) columns}}
+              {{var val = (typeof columnDefinition.rowText == 'function' ? columnDefinition.rowText(row) : row[columnDefinition.rowText])}}
+              <td id="role-${columnDefinition.rowText}-${row.name()}">
+                ${val}
+              </td>
+              {{/each}}
+              <td>
+                <a id="edit-role-${row.name()}" href="#" data-bind="click: function(){ editRole(row) }">
+                  <img src="images/edit-find-22-22.png" title="${$.i18n.prop('edit')}">
+                </a>
+              </td>
+              <td>
+                {{if row.modified()}}
+                  <a href="#" class="btn btn-warning" data-bind="click: function(){ updateRole(row) }">${$.i18n.prop('save')}</a>
+                {{/if}}
+              </td>
+          </tr>
+      {{/each}}
+</script>
+
+
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/user-edit-form.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/user-edit-form.html
new file mode 100644 (file)
index 0000000..3df4d84
--- /dev/null
@@ -0,0 +1,72 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+-->
+<div id="modal-user-edit" class="modal hide fade">
+  <div class="modal-header">
+    <a href="#" class="close" data-dismiss="modal">&times;</a>
+    <h3>${$.i18n.prop('password.section.title')}</h3>
+  </div>
+  <div class="modal-body" id="modal-user-edit-content">
+      <form id="user-edit-form" class="form-horizontal">
+        <div id="modal-user-edit-err-message" class="alert-message error" style="display:none"></div>
+        <fieldset>
+          <div class="control-group">
+            <label class="control-label" for="username">${$.i18n.prop('username')}</label>
+            <div class="controls" id="username-div">
+              <span class="uneditable-input" id="username"></span>
+            </div>
+          </div>
+          <div class="control-group">
+            <label class="control-label" for="fullname">${$.i18n.prop('full.name')}</label>
+            <div class="controls">
+              <input type="text" id="fullname" name="fullname" size="30" class="required"/>
+            </div>
+          </div>
+          <div class="control-group">
+            <label class="control-label" for="email">${$.i18n.prop('email.address')}</label>
+            <div class="controls">
+              <input type="text" id="email" name="email" size="30" class="required email"/>
+            </div>
+          </div>
+          <div class="control-group" id="user-edit-form-current-password-div">
+            <label class="control-label" for="userEditFormCurrentPassword">${$.i18n.prop('password.existing')}</label>
+            <div class="controls">
+              <input type="password" id="userEditFormCurrentPassword" name="userEditFormCurrentPassword" class="required" value=""/>
+            </div>
+          </div>
+
+          <div class="control-group">
+            <label class="control-label" for="userEditFormNewPassword">${$.i18n.prop('password.new')}</label>
+            <div class="controls">
+              <input type="password" id="userEditFormNewPassword" name="userEditFormNewPassword" class="" value=""/>
+            </div>
+          </div>
+
+          <div class="control-group">
+            <label class="control-label" for="userEditFormNewPasswordConfirm">${$.i18n.prop('password.new.confirm')}</label>
+            <div class="controls">
+              <input type="password" id="userEditFormNewPasswordConfirm" name="userEditFormNewPasswordConfirm" class="" value=""/>
+            </div>
+          </div>
+        </fieldset>
+      </form>
+  </div>
+  <div class="modal-footer" id="modal-user-edit-footer">
+    <button class="btn primary" onclick="return" id="modal-user-edit-ok">${$.i18n.prop('ok')}</button>
+  </div>
+</div>
\ No newline at end of file
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/user-edit.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/user-edit.html
new file mode 100644 (file)
index 0000000..674d297
--- /dev/null
@@ -0,0 +1,164 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+-->
+<script id='redback/user-edit-tmpl' type='text/html'>
+<div id="edit-user-details-pills">
+  <ul id="edit_user_details_pills_headers" class="nav nav-pills" data-target="#edit-user-details-pills-content">
+    <li class="active" id="user-view-detail-li">
+      <a data-toggle="tab" href="#user-create-div">${$.i18n.prop('edit')}</a>
+    </li>
+    <li id="user-edit-roles-edit-li">
+      <a data-toggle="tab" href="#user-edit-roles-edit">${$.i18n.prop('effective.roles.edit')}</a>
+    </li>
+  </ul>
+  <div class="pill-content" id="edit-user-details-pills-content">
+    <div id="user-create-div" class="active pill-pane">
+      <div class="row-fluid">
+        <div class="span8 columns">
+          <form id="user-create" class="well form-horizontal" data-bind="submit: save">
+            <fieldset id="user-create-fieldset">
+              <div class="control-group">
+                <label class="control-label" for="username">${$.i18n.prop('username')}</label>
+                <div class="controls" id="username-div">
+                  {{if $data.username.length>0}}
+                    <span class="uneditable-input">${$data.username}</span>
+                  {{else}}
+                    <input type="text" id="username" name="username" size="30" class="required" data-bind="value: username"/>
+                  {{/if}}
+                </div>
+              </div>
+              <div class="control-group">
+                <label class="control-label" for="fullname">${$.i18n.prop('full.name')}</label>
+                <div class="controls">
+                  <input type="text" id="fullname" name="fullname" size="30" class="required" data-bind="value: fullName"/>
+                </div>
+              </div>
+              <div class="control-group">
+                <label class="control-label" for="password">${$.i18n.prop('password')}</label>
+                <div class="controls">
+                  <input type="password" id="password" name="password" class="required" data-bind="value: password"/>
+                </div>
+              </div>
+              <div class="control-group">
+                <label class="control-label" for="confirmPassword">${$.i18n.prop('confirm.password')}</label>
+                <div class="controls">
+                  <input type="password" id="confirmPassword" name="confirmPassword" data-bind="value: confirmPassword"/>
+                </div>
+              </div>
+              <div class="control-group">
+                <label class="control-label" for="email">${$.i18n.prop('email.address')}</label>
+                <div class="controls">
+                  <input type="text" id="email" name="email" class="required email" data-bind="value: email"/>
+                </div>
+              </div>
+              <div class="control-group">
+                <label class="control-label" for="validated">${$.i18n.prop('validated')}</label>
+                <div class="controls">
+                  <input type="checkbox" id="validated" name="validated" data-bind="checked: validated"/>
+                </div>
+              </div>
+              <div class="control-group">
+                <label class="control-label" for="locked">${$.i18n.prop('locked')}</label>
+                <div class="controls">
+                  <input type="checkbox" id="locked" name="locked" data-bind="checked: locked"/>
+                </div>
+              </div>
+              <div class="control-group">
+                <label class="control-label" for="passwordChangeRequired">${$.i18n.prop('user.change.password.required')}</label>
+                <div class="controls">
+                  <input type="checkbox" id="passwordChangeRequired" name="passwordChangeRequired" data-bind="checked: passwordChangeRequired"/>
+                </div>
+              </div>
+            </fieldset>
+            <button data-bind="click: saveUser" class="btn" id="user-create-form-register-button">${$.i18n.prop('save')}</button>
+            <button class="btn" id="user-create-form-cancel-button">${$.i18n.prop('cancel')}</button>
+          </form>
+        </div>
+        <div class="span4 columns" id="user-edit-roles">
+          <div id="user-edit-roles-view"></div>
+        </div>
+      </div>
+    </div>
+
+    <div id="user-edit-roles-edit" class="pill-pane">
+      roles edit
+    </div>
+  </div>
+</div>
+</script>
+
+<script id="user_view_roles_list_tmpl" type="text/html">
+  <div class="page-header">
+    <h3>${$.i18n.prop('effective.roles')}</h3>
+  </div>
+  <div>
+    <ul>
+      {{each $data.user.assignedRoles}}
+        <li>${$value}</li>
+      {{/each}}
+    </ul>
+  </div>
+</script>
+
+<script id="user_edit_roles_tmpl" type="text/html">
+
+  <div>
+    {{each $data.applicationRoles}}
+      <div class="page-header">
+        <h3>${$value.name}</h3>
+      </div>
+      <blockquote>
+        <p>${$value.description}</p>
+      </blockquote>
+      <ul>
+      {{each $value.globalRoles}}
+        <li><input type="checkbox" value="${$value}" data-bind="checked: user.assignedRoles">&nbsp;${$value}</input></li>
+      {{/each}}
+      </ul>
+
+      {{if roleTemplates}}
+      <table class="bordered-table">
+        <thead>
+          <tr>
+            <th>&nbsp;</th>
+            {{each roleTemplates}}
+              <th>${$value.namePrefix}</th>
+            {{/each}}
+          </tr>
+        </thead>
+        <tbody>
+          {{each resources}}
+            {{var curResource = $value}}
+            <tr>
+              <td>${curResource}</td>
+              {{each roleTemplates}}
+                <td><input type="checkbox" value="${$value.namePrefix}${$value.delimiter}${curResource}" data-bind="checked: user.assignedRoles"/></td>
+              {{/each}}
+            </tr>
+          {{/each}}
+        </tbody>
+      </table>
+      {{/if}}
+
+    {{/each}}
+
+    <button class="btn" data-bind="click:updateUserRoles">${$.i18n.prop('update')}</button>
+
+  </div>
+</script>
+
diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/user-grids.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/templates/redback/user-grids.html
new file mode 100644 (file)
index 0000000..0b50cda
--- /dev/null
@@ -0,0 +1,119 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+-->
+<script id='ko_usersGrid_grid' type='text/html'>
+  <thead>
+      <tr>
+        {{each(i, columnDefinition) columns}}
+          <th>${ columnDefinition.headerText }</th>
+        {{/each}}
+        <th>${$.i18n.prop('edit')}</th>
+        <th>${$.i18n.prop('delete')}</th>
+        <th>${$.i18n.prop('user.list.locked')}</th>
+        <th>${$.i18n.prop('user.change.password.required')}</th>
+      </tr>
+  </thead>
+  <tbody>
+      {{each(i, row) itemsOnCurrentPage()}}
+        <tr data-bind="css:{ 'modified': row.modified()}">
+          {{each(j, columnDefinition) columns}}
+          <td>${ typeof columnDefinition.rowText == 'function' ? columnDefinition.rowText(row) : row[columnDefinition.rowText] }</td>
+          {{/each}}
+          <td id="users-grid-user-id-${row.username()}">
+            <a href="#" data-bind="click: function(){ editUserBox(row) }">
+              <img src="images/edit-find-22-22.png" title="${$.i18n.prop('edit')}">
+            </a>
+          </td>
+          {{if row.username()=="admin" || row.username()=="guest"}}
+            <td></td>
+          {{else}}
+            <td>
+              <a href="#" data-bind="click: function(){ deleteUser(row) }" id="users-grid-delete-${row.username()}">
+                <img src="images/edit-cut-22-22.png" alt="${$.i18n.prop('delete')}"/>
+              </a>
+            </td>
+          {{/if}}
+          {{if row.username()=="admin"}}
+            <td></td>
+          {{else}}
+            {{if row.locked()==true}}
+              <td>
+                <a href="#" data-bind="click: function(){ unlock(row) }"><img src="images/system-lock-screen-22-22.png"/></a>
+              </td>
+            {{else}}
+              <td>
+                <a href="#" data-bind="click: function(){ lock(row) }"><img src="images/weather-clear-22-22.png"/></a>
+              </td>
+            {{/if}}
+          {{/if}}
+          {{if row.username()=="admin"}}
+            <td></td>
+          {{else}}
+            {{if row.passwordChangeRequired()==true}}
+              <td>
+                <a href="#" data-bind="click: function(){ passwordChangeRequire(row,false) }">
+                  <img src="images/dialog-error-22-22.png"/>
+                </a>
+              </td>
+            {{else}}
+            <td>
+              <a href="#" data-bind="click: function(){ passwordChangeRequire(row,true) }">
+                <img src="images/weather-clear-22-22.png"/>
+              </a>
+            </td>
+            {{/if}}
+          {{/if}}
+        </tr>
+      {{/each}}
+  </tbody>
+
+</script>
+
+<script id="usersGrid"  type="text/html">
+    <div class="page-header">
+      <h3><img src="images/system-users-32-32.png"/>${$.i18n.prop('users.list')}</h3>
+    </div>
+    <ul id="users-view-tabs" class="nav nav-tabs" data-target="#users-view-tabs-content">
+      <li class="active" id="users-view-tabs-li-users-grid">
+        <a data-toggle="tab" href="#users-view">${$.i18n.prop('users.grid.tab.title')}</a>
+      </li>
+      <li id="users-view-tabs-li-user-edit">
+        <a data-toggle="tab" href="#createUserForm" id="users-view-tabs-li-user-edit-a">${$.i18n.prop('add')}</a>
+      </li>
+    </ul>
+    <div id="users-view-tabs-content" class="tab-content">
+      <div id="users-view" class="tab-pane">
+        <button data-bind='click: sortByName'  class="btn">
+            ${$.i18n.prop('users.sort.byname')}
+        </button>
+        <table class="table table-striped table-bordered" id="usersTable"
+               data-bind="simpleGrid: gridViewModel,simpleGridTemplate:'ko_usersGrid_grid',pageLinksId:'usersPagination'">
+        </table>
+        <div id="usersPagination"></div>
+      </div>
+      <div id="createUserForm" class="tab-pane"></div>
+    </div>
+</script>
+
+<script id="user-delete-warning-tmpl" type='text/html'>
+    <div>
+      <span class="label label-warning">${$.i18n.prop('warning.not.undone.operation')}</span>
+    </div>
+</script>
+
+