]> source.dussan.org Git - archiva.git/blob
4dad3912117411abfa24765b98beb16ba4289570
[archiva.git] /
1 <!--
2   ~ Licensed to the Apache Software Foundation (ASF) under one
3   ~ or more contributor license agreements.  See the NOTICE file
4   ~ distributed with this work for additional information
5   ~ regarding copyright ownership.  The ASF licenses this file
6   ~ to you under the Apache License, Version 2.0 (the
7   ~ "License"); you may not use this file except in compliance
8   ~ with the License.  You may obtain a copy of the License at
9   ~
10   ~   http://www.apache.org/licenses/LICENSE-2.0
11   ~
12   ~ Unless required by applicable law or agreed to in writing,
13   ~ software distributed under the License is distributed on an
14   ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15   ~ KIND, either express or implied.  See the License for the
16   ~ specific language governing permissions and limitations
17   ~ under the License.
18 -->
19 <script id="repositoriesMain" type="text/x-jquery-tmpl">
20     <div class="page-header">
21       <h2>${$.i18n.prop('administration.repositories')}</h2>
22     </div>
23
24       <ul id="repositories-tabs" class="tabs">
25         <li class="active">
26           <a href="#managed-repositories-content">${$.i18n.prop('managedrepositories.grid.head')}</a>
27         </li>  
28         <li>
29           <a href="#remote-repositories-content">${$.i18n.prop('remoterepositories.grid.head')}</a>
30         </li>
31       </ul>  
32       <div class="tab-content">
33         <div id="managed-repositories-content" class="active">
34             <ul id="managed-repositories-pills" class="pills">
35               <li class="active" id="managed-repositories-view-li">
36                 <a href="#managed-repositories-view">${$.i18n.prop('managedrepositories.grid.tab.title')}</a>
37               </li>
38               <li id="managed-repository-edit-li">
39                 <a href="#managed-repository-edit">${$.i18n.prop('add')}</a>
40               </li>
41             </ul>
42             <div id="managed-repositories-tabs-content" class="pill-content">
43               <div id="managed-repositories-view" class="active">
44                   <table class="bordered-table zebra-striped" id="managed-repositories-table"
45                          data-bind="simpleGrid: gridViewModel,simpleGridTemplate:'ko_managed-repositoriesGrid',pageLinksId:'managed-repositoriesPagination',data:'managedRepositories'">
46                   </table>
47                   <div id="managed-repositoriesPagination"></div>
48               </div>
49               <div id="managed-repository-edit" data-bind='template: {name:"managed-repository-edit-tmpl"}'>
50               </div>
51             </div>
52         </div>
53
54
55         <div id="remote-repositories-content">
56                 grid to view edit remote repositories
57         </div>
58       </div>
59 </script>
60
61 <script id='ko_managed-repositoriesGrid' type='text/x-jquery-tmpl'>
62   <thead>
63       <tr>
64         {{each(i, columnDefinition) columns}}
65           <th title="${ columnDefinition.title }">${ columnDefinition.headerText }</th>
66         {{/each}}
67         <th>Releases</th>
68         <th>Snapshots</th>
69         <th>Scan</th>
70         <th>${$.i18n.prop('edit')}</th>
71         <th>${$.i18n.prop('delete')}</th>
72       </tr>
73   </thead>
74   <tbody>
75       {{each(i, row) itemsOnCurrentPage()}}
76           <tr>
77             {{each(j, columnDefinition) columns}}
78               <td>${ typeof columnDefinition.rowText == 'function' ? columnDefinition.rowText(row) : row[columnDefinition.rowText] }</td>
79             {{/each}}
80             <td>
81             {{if row.releases() == true}}
82               <img src="images/weather-clear.png" title="${$.i18n.prop('release.included')}"/>
83             {{else}}
84               <img src="images/dialog-error.png" title="${$.i18n.prop('release.notincluded')}"/>
85             {{/if}}
86             </td>
87
88             <td>
89               {{if row.snapshots() == true}}
90                 <img src="images/weather-clear.png" title="${$.i18n.prop('snapshots.included')}"/>
91               {{else}}
92                   <img src="images/dialog-error.png" title="${$.i18n.prop('snapshots.notincluded')}"/>
93               {{/if}}
94             </td>
95             <td>
96               <a href="#" data-bind="click: function(){ scanNow(row) }">
97                 <img src="images/view-refresh.png" title="${$.i18n.prop('managedrepository.scan.now')}"/>
98               </a>
99             </td>
100             <td><a href="#" data-bind="click: function(){ editManagedRepository(row) }">${$.i18n.prop('edit')}</a></td>
101             <td>
102               <a href="#" data-bind="click: function(){ removeManagedRepository(row) }">
103                 <img src="images/edit-cut.png" title="${$.i18n.prop('delete')}"/>
104               </a>
105             </td>
106           </tr>
107       {{/each}}
108   </tbody>
109
110 </script>
111
112 <script id="managed-repository-edit-tmpl" type='text/x-jquery-tmpl'>
113     <form id="managed-repository-edit-form">
114       <fieldset id="managed-repository-edit-fieldset">
115         <div class="clearfix">
116           <label for="name">${$.i18n.prop('id')}</label>
117           <div class="input">
118             {{if update}}
119               <span class="uneditable-input">${$data.managedRepository.id}</span>
120             {{else}}
121               <input type="text" class="xlarge required" id="id" name="id" size="50"
122                      data-bind="value: managedRepository.id,css:{'uneditable-input': update},readonly:update"/>
123             {{/if}}
124           </div>
125         </div>
126         <div class="clearfix">
127           <label for="name">${$.i18n.prop('name')}</label>
128           <div class="input">
129             <input type="text" class="xlarge required" id="name" name="name" size="50"
130                    data-bind="value: managedRepository.name"/>
131           </div>
132         </div>
133         <div class="clearfix">
134           <label for="location">${$.i18n.prop('directory')}</label>
135           <div class="input">
136             <input type="text" class="xlarge required" id="location" name="location" size="50" data-bind="value: managedRepository.location"/>
137           </div>
138         </div>
139         <div class="clearfix">
140           <label for="indexDirectory">${$.i18n.prop('index.directory')}</label>
141           <div class="input">
142             <input type="text" class="xlarge" id="indexDirectory" name="indexDirectory" size="50" data-bind="value: managedRepository.indexDirectory"/>
143           </div>
144         </div>
145           <div class="clearfix">
146             <label for="layout">${$.i18n.prop('type')}</label>
147             <div class="input">
148               <select id="layout" data-bind="options: availableLayouts,optionsText: 'label',optionsValue:'type',value: managedRepository.layout"/>
149             </div>
150           </div>
151         <div class="clearfix">
152           <label for="cronExpression">${$.i18n.prop('cronExpression')}</label>
153           <div class="input">
154             <input type="text" id="cronExpression" class="required" name="cronExpression" size="40" data-bind="value: managedRepository.cronExpression"/>
155           </div>
156         </div>
157         <div class="clearfix">
158           <label for="daysOlder">${$.i18n.prop('daysOlder')}</label>
159           <div class="input">
160             <input type="text" id="daysOlder" class="digits" name="daysOlder" size="5" data-bind="value: managedRepository.daysOlder"/>
161           </div>
162         </div>
163         <div class="clearfix">
164           <label for="retentionCount">${$.i18n.prop('retentionCount')}</label>
165           <div class="input">
166             <input type="text" id="retentionCount" name="retentionCount" size="5" data-bind="value: managedRepository.retentionCount"/>
167           </div>
168         </div>
169         <div class="clearfix">
170           <label for="releases">${$.i18n.prop('releases')}</label>
171           <div class="input">
172             <input type="checkbox" id="releases" name="releases" size="5" data-bind="checked: managedRepository.releases"/>
173           </div>
174         </div>
175         <div class="clearfix">
176           <label for="snapshots">${$.i18n.prop('snapshots')}</label>
177           <div class="input">
178             <input type="checkbox" id="snapshots" name="snapshots" size="5" data-bind="checked: managedRepository.snapshots"/>
179           </div>
180         </div>
181         <div class="clearfix">
182           <label for="blockRedeployments">${$.i18n.prop('blockRedeployments')}</label>
183           <div class="input">
184             <input type="checkbox" id="blockRedeployments" name="blockRedeployments" size="5" data-bind="checked: managedRepository.blockRedeployments"/>
185           </div>
186         </div>
187         <div class="clearfix">
188           <label for="scanned">${$.i18n.prop('scanned')}</label>
189           <div class="input">
190             <input type="checkbox" id="scanned" name="scanned" size="5" data-bind="checked: managedRepository.scanned"/>
191           </div>
192         </div>
193         <div class="clearfix">
194           <label for="deleteReleasedSnapshots">${$.i18n.prop('deleteReleasedSnapshots')}</label>
195           <div class="input">
196             <input type="checkbox" id="deleteReleasedSnapshots" name="deleteReleasedSnapshots" size="5"
197                    data-bind="checked: managedRepository.deleteReleasedSnapshots"/>
198           </div>
199         </div>
200         <div class="clearfix">
201           <label for="stageRepoNeeded">${$.i18n.prop('stageRepoNeeded')}</label>
202           <div class="input">
203             <input type="checkbox" id="stageRepoNeeded" name="stageRepoNeeded" size="5"
204                    data-bind="checked: managedRepository.stageRepoNeeded"/>
205           </div>
206         </div>
207       </fieldset>
208       <button data-bind="click: save" class="btn">${$.i18n.prop('save')}</button>
209       <button data-bind="click: displayGrid" class="btn">${$.i18n.prop('cancel')}</button>
210     </form>
211 </script>
212
213 <script id="managed-repository-delete-warning-tmpl" type='text/x-jquery-tmpl'>
214   <div>
215     <a class="close" href="#">&#215;</a>
216     <div class="alert-message warning">
217       <p>
218         <strong>${$.i18n.prop('warning.not.undone.operation')}</strong>
219       </p>
220     </div>
221     <div>
222       <span><strong>${$.i18n.prop('managedrepository.delete.warning.message')}</strong>.</span>
223       <div>${$.i18n.prop('id')}: ${id()}</div>
224       <div>${$.i18n.prop('name')}: ${name()}</div>
225     </div>
226     <div>
227         ${$.i18n.prop('managedrepository.delete.content')}: <input type="checkbox" id="managedrepository-deletecontent">
228     </div>
229   </div>
230 </script>
231 <script id="managed-repository-location-warning-tmpl" type='text/x-jquery-tmpl'>
232   <div>
233     <a class="close" href="#">&#215;</a>
234     <div class="alert-message warning">
235       <p>
236         <strong>${$.i18n.prop('managedrepository.location.already.exists')}</strong>
237       </p>
238     </div>
239     <div>
240       <span><strong>${$.i18n.prop('managedrepository.location.already.exists.warning.message')}</strong>.</span>
241       <div>${$.i18n.prop('id')}: ${id()}</div>
242       <div>${$.i18n.prop('name')}: ${name()}</div>
243     </div>
244   </div>
245 </script>
246 <script id="managed-repository-scan-now-modal-tmpl" type='text/x-jquery-tmpl'>
247       <div>
248         ${$.i18n.prop('managedrepository.scan.all')}: <input type="checkbox" id="managed-repository-scan-now-all">
249       </div>
250
251 </script>