]> source.dussan.org Git - archiva.git/blob
2eef3caff46835a17c1fc8d223cb051493857fb2
[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'">
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
51               </div>
52             </div>
53         </div>
54
55
56         <div id="remote-repositories-content">
57                 grid to view edit remote repositories
58         </div>
59       </div>
60 </script>
61
62 <script id='ko_managed-repositoriesGrid' type='text/x-jquery-tmpl'>
63   <thead>
64       <tr>
65         {{each(i, columnDefinition) columns}}
66           <th title="${ columnDefinition.title }">${ columnDefinition.headerText }</th>
67         {{/each}}
68         <th>${$.i18n.prop('release.included')}</th>
69         <th>${$.i18n.prop('snapshots.included')}</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"/>
83             {{else}}
84                 <img src="images/dialog-error.png"/>
85             {{/if}}
86             </td>
87
88             <td>
89               {{if row.snapshots() == true}}
90                 <img src="images/weather-clear.png"/>
91               {{else}}
92                   <img src="images/dialog-error.png"/>
93               {{/if}}
94             </td>
95             <td><a href="#" data-bind="click: function(){ editManagedRepository(row) }">${$.i18n.prop('edit')}</a></td>
96             <td>
97               <a href="#" data-bind="click: function(){ removeManagedRepository(row) }">
98                 <img src="images/delete.png" title="${$.i18n.prop('delete')}"/>
99               </a>
100             </td>
101           </tr>
102       {{/each}}
103   </tbody>
104
105 </script>
106
107 <script id="managed-repository-edit-tmpl" type='text/x-jquery-tmpl'>
108     <form id="managed-repository-edit-form">
109       <fieldset id="managed-repository-edit-fieldset">
110         <div class="clearfix">
111           <label for="name">${$.i18n.prop('id')}</label>
112           <div class="input">
113             {{if update}}
114               <span class="uneditable-input">${$data.managedRepository.id}</span>
115             {{else}}
116               <input type="text" class="xlarge required" id="id" name="id" size="50"
117                      data-bind="value: managedRepository.id,css:{'uneditable-input': update},readonly:update"/>
118             {{/if}}
119           </div>
120         </div>
121         <div class="clearfix">
122           <label for="name">${$.i18n.prop('name')}</label>
123           <div class="input">
124             <input type="text" class="xlarge required" id="name" name="name" size="50"
125                    data-bind="value: managedRepository.name"/>
126           </div>
127         </div>
128         <div class="clearfix">
129           <label for="location">${$.i18n.prop('directory')}</label>
130           <div class="input">
131             <input type="text" class="xlarge required" id="location" name="location" size="50" data-bind="value: managedRepository.location"/>
132           </div>
133         </div>
134         <div class="clearfix">
135           <label for="indexDirectory">${$.i18n.prop('index.directory')}</label>
136           <div class="input">
137             <input type="text" class="xlarge" id="indexDirectory" name="indexDirectory" size="50" data-bind="value: managedRepository.indexDirectory"/>
138           </div>
139         </div>
140           <div class="clearfix">
141             <label for="layout">${$.i18n.prop('type')}</label>
142             <div class="input">
143               <select id="layout" data-bind="options: availableLayouts,optionsText: 'label',optionsValue:'type',value: managedRepository.layout"/>
144             </div>
145           </div>
146         <div class="clearfix">
147           <label for="cronExpression">${$.i18n.prop('cronExpression')}</label>
148           <div class="input">
149             <input type="text" id="cronExpression" class="required" name="cronExpression" size="40" data-bind="value: managedRepository.cronExpression"/>
150           </div>
151         </div>
152         <div class="clearfix">
153           <label for="daysOlder">${$.i18n.prop('daysOlder')}</label>
154           <div class="input">
155             <input type="text" id="daysOlder" class="digits" name="daysOlder" size="5" data-bind="value: managedRepository.daysOlder"/>
156           </div>
157         </div>
158         <div class="clearfix">
159           <label for="retentionCount">${$.i18n.prop('retentionCount')}</label>
160           <div class="input">
161             <input type="text" id="retentionCount" name="retentionCount" size="5" data-bind="value: managedRepository.retentionCount"/>
162           </div>
163         </div>
164         <div class="clearfix">
165           <label for="releases">${$.i18n.prop('releases')}</label>
166           <div class="input">
167             <input type="checkbox" id="releases" name="releases" size="5" data-bind="checked: managedRepository.releases"/>
168           </div>
169         </div>
170         <div class="clearfix">
171           <label for="snapshots">${$.i18n.prop('snapshots')}</label>
172           <div class="input">
173             <input type="checkbox" id="snapshots" name="snapshots" size="5" data-bind="checked: managedRepository.snapshots"/>
174           </div>
175         </div>
176         <div class="clearfix">
177           <label for="blockRedeployments">${$.i18n.prop('blockRedeployments')}</label>
178           <div class="input">
179             <input type="checkbox" id="blockRedeployments" name="blockRedeployments" size="5" data-bind="checked: managedRepository.blockRedeployments"/>
180           </div>
181         </div>
182         <div class="clearfix">
183           <label for="scanned">${$.i18n.prop('scanned')}</label>
184           <div class="input">
185             <input type="checkbox" id="scanned" name="scanned" size="5" data-bind="checked: managedRepository.scanned"/>
186           </div>
187         </div>
188         <div class="clearfix">
189           <label for="deleteReleasedSnapshots">${$.i18n.prop('deleteReleasedSnapshots')}</label>
190           <div class="input">
191             <input type="checkbox" id="deleteReleasedSnapshots" name="deleteReleasedSnapshots" size="5"
192                    data-bind="checked: managedRepository.deleteReleasedSnapshots"/>
193           </div>
194         </div>
195         <div class="clearfix">
196           <label for="stageRepoNeeded">${$.i18n.prop('stageRepoNeeded')}</label>
197           <div class="input">
198             <input type="checkbox" id="stageRepoNeeded" name="stageRepoNeeded" size="5"
199                    data-bind="checked: managedRepository.stageRepoNeeded"/>
200           </div>
201         </div>
202       </fieldset>
203       <button data-bind="click: save" class="btn">${$.i18n.prop('save')}</button>
204       <button data-bind="click: displayGrid" class="btn">${$.i18n.prop('cancel')}</button>
205     </form>
206 </script>
207
208 <script id="managed-repository-delete-warning-tmpl" type='text/x-jquery-tmpl'>
209   <div>
210     <a class="close" href="#">&#215;</a>
211     <div class="alert-message warning">
212       <p>
213         <strong>${$.i18n.prop('warning.not.undone.operation')}</strong>
214       </p>
215     </div>
216     <div>
217       <span><strong>${$.i18n.prop('managedrepository.delete.warning.message')}</strong>.</span>
218       <div>${$.i18n.prop('id')}: ${id()}</div>
219       <div>${$.i18n.prop('name')}: ${name()}</div>
220     </div>
221     <div>
222         ${$.i18n.prop('managedrepository.delete.content')}: <input type="checkbox" id="managedrepository-deletecontent">
223     </div>
224   </div>
225 </script>
226 <script id="managed-repository-location-warning-tmpl" type='text/x-jquery-tmpl'>
227   <div>
228     <a class="close" href="#">&#215;</a>
229     <div class="alert-message warning">
230       <p>
231         <strong>${$.i18n.prop('managedrepository.location.already.exists')}</strong>
232       </p>
233     </div>
234     <div>
235       <span><strong>${$.i18n.prop('managedrepository.location.already.exists.warning.message')}</strong>.</span>
236       <div>${$.i18n.prop('id')}: ${id()}</div>
237       <div>${$.i18n.prop('name')}: ${name()}</div>
238     </div>
239   </div>
240 </script>