Show More
@@ -1,374 +1,382 b'' | |||||
1 | ## -*- coding: utf-8 -*- |
|
1 | ## -*- coding: utf-8 -*- | |
|
2 | ## | |||
|
3 | ## See also repo_settings.html | |||
|
4 | ## | |||
2 | <%inherit file="/base/base.html"/> |
|
5 | <%inherit file="/base/base.html"/> | |
3 |
|
6 | |||
4 | <%def name="title()"> |
|
7 | <%def name="title()"> | |
5 | ${_('Edit repository')} ${c.repo_info.repo_name} · ${c.rhodecode_name} |
|
8 | ${_('Edit repository')} ${c.repo_info.repo_name} · ${c.rhodecode_name} | |
6 | </%def> |
|
9 | </%def> | |
7 |
|
10 | |||
8 | <%def name="breadcrumbs_links()"> |
|
11 | <%def name="breadcrumbs_links()"> | |
9 | ${h.link_to(_(u'Home'),h.url('/'))} |
|
12 | ${h.link_to(_(u'Home'),h.url('/'))} | |
10 | » |
|
13 | » | |
11 | ${h.link_to(c.repo_info.repo_name,h.url('summary_home',repo_name=c.repo_info.repo_name))} |
|
14 | ${h.link_to(c.repo_info.repo_name,h.url('summary_home',repo_name=c.repo_info.repo_name))} | |
12 | » |
|
15 | » | |
13 | ${_('Settings')} |
|
16 | ${_('Settings')} | |
14 | </%def> |
|
17 | </%def> | |
15 |
|
18 | |||
16 | <%def name="page_nav()"> |
|
19 | <%def name="page_nav()"> | |
17 | ${self.menu('options')} |
|
20 | ${self.menu('options')} | |
18 | </%def> |
|
21 | </%def> | |
19 |
|
22 | |||
20 | <%def name="main()"> |
|
23 | <%def name="main()"> | |
21 | ${self.context_bar('options')} |
|
24 | ${self.context_bar('options')} | |
22 | <div class="box box-left"> |
|
25 | <div class="box box-left"> | |
23 | <!-- box / title --> |
|
26 | <!-- box / title --> | |
24 | <div class="title"> |
|
27 | <div class="title"> | |
25 | ${self.breadcrumbs()} |
|
28 | ${self.breadcrumbs()} | |
26 | </div> |
|
29 | </div> | |
27 | ${h.form(url('repo', repo_name=c.repo_info.repo_name),method='put')} |
|
30 | ${h.form(url('repo', repo_name=c.repo_info.repo_name),method='put')} | |
28 | <div class="form"> |
|
31 | <div class="form"> | |
29 | <!-- fields --> |
|
32 | <!-- fields --> | |
30 | <div class="fields"> |
|
33 | <div class="fields"> | |
31 | <div class="field"> |
|
34 | <div class="field"> | |
32 | <div class="label"> |
|
35 | <div class="label"> | |
33 | <label for="repo_name">${_('Name')}:</label> |
|
36 | <label for="repo_name">${_('Name')}:</label> | |
34 | </div> |
|
37 | </div> | |
35 | <div class="input"> |
|
38 | <div class="input"> | |
36 | ${h.text('repo_name',class_="medium")} |
|
39 | ${h.text('repo_name',class_="medium")} | |
37 | </div> |
|
40 | </div> | |
38 | </div> |
|
41 | </div> | |
39 | <div class="field"> |
|
42 | <div class="field"> | |
40 | <div class="label"> |
|
43 | <div class="label"> | |
41 | <label for="clone_uri">${_('Clone uri')}:</label> |
|
44 | <label for="clone_uri">${_('Clone uri')}:</label> | |
42 | </div> |
|
45 | </div> | |
43 | <div class="input"> |
|
46 | <div class="input"> | |
44 | ${h.text('clone_uri',class_="medium")} |
|
47 | ${h.text('clone_uri',class_="medium")} | |
45 | <span class="help-block">${_('Optional http[s] url from which repository should be cloned.')}</span> |
|
48 | <span class="help-block">${_('Optional http[s] url from which repository should be cloned.')}</span> | |
46 | </div> |
|
49 | </div> | |
47 | </div> |
|
50 | </div> | |
48 | <div class="field"> |
|
51 | <div class="field"> | |
49 | <div class="label"> |
|
52 | <div class="label"> | |
50 | <label for="repo_group">${_('Repository group')}:</label> |
|
53 | <label for="repo_group">${_('Repository group')}:</label> | |
51 | </div> |
|
54 | </div> | |
52 | <div class="input"> |
|
55 | <div class="input"> | |
53 | ${h.select('repo_group','',c.repo_groups,class_="medium")} |
|
56 | ${h.select('repo_group','',c.repo_groups,class_="medium")} | |
54 | <span class="help-block">${_('Optional select a group to put this repository into.')}</span> |
|
57 | <span class="help-block">${_('Optional select a group to put this repository into.')}</span> | |
55 | </div> |
|
58 | </div> | |
56 | </div> |
|
59 | </div> | |
57 | <div class="field"> |
|
60 | <div class="field"> | |
58 | <div class="label"> |
|
61 | <div class="label"> | |
59 | <label for="repo_type">${_('Type')}:</label> |
|
62 | <label for="repo_type">${_('Type')}:</label> | |
60 | </div> |
|
63 | </div> | |
61 | <div class="input"> |
|
64 | <div class="input"> | |
62 | ${h.select('repo_type','hg',c.backends,class_="medium")} |
|
65 | ${h.select('repo_type','hg',c.backends,class_="medium")} | |
63 | </div> |
|
66 | </div> | |
64 | </div> |
|
67 | </div> | |
65 | <div class="field"> |
|
68 | <div class="field"> | |
66 | <div class="label"> |
|
69 | <div class="label"> | |
67 | <label for="repo_landing_rev">${_('Landing revision')}:</label> |
|
70 | <label for="repo_landing_rev">${_('Landing revision')}:</label> | |
68 | </div> |
|
71 | </div> | |
69 | <div class="input"> |
|
72 | <div class="input"> | |
70 | ${h.select('repo_landing_rev','',c.landing_revs,class_="medium")} |
|
73 | ${h.select('repo_landing_rev','',c.landing_revs,class_="medium")} | |
71 | <span class="help-block">${_('Default revision for files page, downloads, whoosh and readme')}</span> |
|
74 | <span class="help-block">${_('Default revision for files page, downloads, whoosh and readme')}</span> | |
72 | </div> |
|
75 | </div> | |
73 | </div> |
|
76 | </div> | |
74 | <div class="field"> |
|
77 | <div class="field"> | |
75 | <div class="label label-textarea"> |
|
78 | <div class="label label-textarea"> | |
76 | <label for="repo_description">${_('Description')}:</label> |
|
79 | <label for="repo_description">${_('Description')}:</label> | |
77 | </div> |
|
80 | </div> | |
78 | <div class="textarea text-area editor"> |
|
81 | <div class="textarea text-area editor"> | |
79 | ${h.textarea('repo_description')} |
|
82 | ${h.textarea('repo_description')} | |
80 | <span class="help-block">${_('Keep it short and to the point. Use a README file for longer descriptions.')}</span> |
|
83 | <span class="help-block">${_('Keep it short and to the point. Use a README file for longer descriptions.')}</span> | |
81 | </div> |
|
84 | </div> | |
82 | </div> |
|
85 | </div> | |
83 |
|
86 | |||
84 | <div class="field"> |
|
87 | <div class="field"> | |
85 | <div class="label label-checkbox"> |
|
88 | <div class="label label-checkbox"> | |
86 | <label for="repo_private">${_('Private repository')}:</label> |
|
89 | <label for="repo_private">${_('Private repository')}:</label> | |
87 | </div> |
|
90 | </div> | |
88 | <div class="checkboxes"> |
|
91 | <div class="checkboxes"> | |
89 | ${h.checkbox('repo_private',value="True")} |
|
92 | ${h.checkbox('repo_private',value="True")} | |
90 | <span class="help-block">${_('Private repositories are only visible to people explicitly added as collaborators.')}</span> |
|
93 | <span class="help-block">${_('Private repositories are only visible to people explicitly added as collaborators.')}</span> | |
91 | </div> |
|
94 | </div> | |
92 | </div> |
|
95 | </div> | |
93 | <div class="field"> |
|
96 | <div class="field"> | |
94 | <div class="label label-checkbox"> |
|
97 | <div class="label label-checkbox"> | |
95 | <label for="repo_enable_statistics">${_('Enable statistics')}:</label> |
|
98 | <label for="repo_enable_statistics">${_('Enable statistics')}:</label> | |
96 | </div> |
|
99 | </div> | |
97 | <div class="checkboxes"> |
|
100 | <div class="checkboxes"> | |
98 | ${h.checkbox('repo_enable_statistics',value="True")} |
|
101 | ${h.checkbox('repo_enable_statistics',value="True")} | |
99 | <span class="help-block">${_('Enable statistics window on summary page.')}</span> |
|
102 | <span class="help-block">${_('Enable statistics window on summary page.')}</span> | |
100 | </div> |
|
103 | </div> | |
101 | </div> |
|
104 | </div> | |
102 | <div class="field"> |
|
105 | <div class="field"> | |
103 | <div class="label label-checkbox"> |
|
106 | <div class="label label-checkbox"> | |
104 | <label for="repo_enable_downloads">${_('Enable downloads')}:</label> |
|
107 | <label for="repo_enable_downloads">${_('Enable downloads')}:</label> | |
105 | </div> |
|
108 | </div> | |
106 | <div class="checkboxes"> |
|
109 | <div class="checkboxes"> | |
107 | ${h.checkbox('repo_enable_downloads',value="True")} |
|
110 | ${h.checkbox('repo_enable_downloads',value="True")} | |
108 | <span class="help-block">${_('Enable download menu on summary page.')}</span> |
|
111 | <span class="help-block">${_('Enable download menu on summary page.')}</span> | |
109 | </div> |
|
112 | </div> | |
110 | </div> |
|
113 | </div> | |
111 | <div class="field"> |
|
114 | <div class="field"> | |
112 | <div class="label label-checkbox"> |
|
115 | <div class="label label-checkbox"> | |
113 | <label for="repo_enable_locking">${_('Enable locking')}:</label> |
|
116 | <label for="repo_enable_locking">${_('Enable locking')}:</label> | |
114 | </div> |
|
117 | </div> | |
115 | <div class="checkboxes"> |
|
118 | <div class="checkboxes"> | |
116 | ${h.checkbox('repo_enable_locking',value="True")} |
|
119 | ${h.checkbox('repo_enable_locking',value="True")} | |
117 | <span class="help-block">${_('Enable lock-by-pulling on repository.')}</span> |
|
120 | <span class="help-block">${_('Enable lock-by-pulling on repository.')}</span> | |
118 | </div> |
|
121 | </div> | |
119 | </div> |
|
122 | </div> | |
120 | <div class="field"> |
|
123 | <div class="field"> | |
121 | <div class="label"> |
|
124 | <div class="label"> | |
122 | <label for="user">${_('Owner')}:</label> |
|
125 | <label for="user">${_('Owner')}:</label> | |
123 | </div> |
|
126 | </div> | |
124 | <div class="input input-medium ac"> |
|
127 | <div class="input input-medium ac"> | |
125 | <div class="perm_ac"> |
|
128 | <div class="perm_ac"> | |
126 | ${h.text('user',class_='yui-ac-input')} |
|
129 | ${h.text('user',class_='yui-ac-input')} | |
127 | <span class="help-block">${_('Change owner of this repository.')}</span> |
|
130 | <span class="help-block">${_('Change owner of this repository.')}</span> | |
128 | <div id="owner_container"></div> |
|
131 | <div id="owner_container"></div> | |
129 | </div> |
|
132 | </div> | |
130 | </div> |
|
133 | </div> | |
131 | </div> |
|
134 | </div> | |
132 | %if c.visual.repository_fields: |
|
135 | %if c.visual.repository_fields: | |
133 | ## EXTRA FIELDS |
|
136 | ## EXTRA FIELDS | |
134 | %for field in c.repo_fields: |
|
137 | %for field in c.repo_fields: | |
135 | <div class="field"> |
|
138 | <div class="field"> | |
136 | <div class="label"> |
|
139 | <div class="label"> | |
137 | <label for="${field.field_key_prefixed}">${field.field_label} (${field.field_key}):</label> |
|
140 | <label for="${field.field_key_prefixed}">${field.field_label} (${field.field_key}):</label> | |
138 | </div> |
|
141 | </div> | |
139 | <div class="input input-medium"> |
|
142 | <div class="input input-medium"> | |
140 | ${h.text(field.field_key_prefixed, field.field_value, class_='medium')} |
|
143 | ${h.text(field.field_key_prefixed, field.field_value, class_='medium')} | |
141 | %if field.field_desc: |
|
144 | %if field.field_desc: | |
142 | <span class="help-block">${field.field_desc}</span> |
|
145 | <span class="help-block">${field.field_desc}</span> | |
143 | %endif |
|
146 | %endif | |
144 | </div> |
|
147 | </div> | |
145 | </div> |
|
148 | </div> | |
146 | %endfor |
|
149 | %endfor | |
147 | %endif |
|
150 | %endif | |
148 | <div class="field"> |
|
151 | <div class="field"> | |
149 | <div class="label"> |
|
152 | <div class="label"> | |
150 | <label for="input">${_('Permissions')}:</label> |
|
153 | <label for="input">${_('Permissions')}:</label> | |
151 | </div> |
|
154 | </div> | |
152 | <div class="input"> |
|
155 | <div class="input"> | |
153 | <%include file="repo_edit_perms.html"/> |
|
156 | <%include file="repo_edit_perms.html"/> | |
154 | </div> |
|
157 | </div> | |
|
158 | </div> | |||
155 |
|
159 | |||
156 |
|
|
160 | <div class="buttons"> | |
157 |
|
|
161 | ${h.submit('save',_('Save'),class_="ui-btn large")} | |
158 |
|
|
162 | ${h.reset('reset',_('Reset'),class_="ui-btn large")} | |
159 | </div> |
|
|||
160 | </div> |
|
163 | </div> | |
161 | </div> |
|
164 | </div> | |
162 | </div> |
|
165 | </div> | |
163 | ${h.end_form()} |
|
166 | ${h.end_form()} | |
164 | </div> |
|
167 | </div> | |
165 |
|
168 | |||
166 | <div class="box box-right"> |
|
169 | <div class="box box-right"> | |
167 | <div class="title"> |
|
170 | <div class="title"> | |
168 | <h5>${_('Advanced settings')}</h5> |
|
171 | <h5>${_('Advanced settings')}</h5> | |
169 | </div> |
|
172 | </div> | |
170 |
|
173 | |||
171 |
|
|
174 | <h3>${_('Statistics')}</h3> | |
172 |
|
|
175 | ${h.form(url('repo_stats', repo_name=c.repo_info.repo_name),method='delete')} | |
173 |
|
|
176 | <div class="form"> | |
174 |
|
|
177 | <div class="fields"> | |
175 |
|
|
178 | ${h.submit('reset_stats_%s' % c.repo_info.repo_name,_('Reset current statistics'),class_="ui-btn",onclick="return confirm('"+_('Confirm to remove current statistics')+"');")} | |
176 | <div class="field" style="border:none;color:#888"> |
|
|||
177 | <ul> |
|
|||
178 | <li>${_('Fetched to rev')}: ${c.stats_revision}/${c.repo_last_rev}</li> |
|
|||
179 | <li>${_('Stats gathered')}: ${c.stats_percentage}%</li> |
|
|||
180 | </ul> |
|
|||
181 | </div> |
|
|||
182 | </div> |
|
|||
183 | </div> |
|
|||
184 | ${h.end_form()} |
|
|||
185 |
|
||||
186 | %if c.repo_info.clone_uri: |
|
|||
187 | <h3>${_('Remote')}</h3> |
|
|||
188 | ${h.form(url('repo_pull', repo_name=c.repo_info.repo_name),method='put')} |
|
|||
189 | <div class="form"> |
|
|||
190 | <div class="fields"> |
|
|||
191 | ${h.submit('remote_pull_%s' % c.repo_info.repo_name,_('Pull changes from remote location'),class_="ui-btn",onclick="return confirm('"+_('Confirm to pull changes from remote side')+"');")} |
|
|||
192 | <div class="field" style="border:none"> |
|
|||
193 | <ul> |
|
|||
194 | <li><a href="${c.repo_info.clone_uri}">${c.repo_info.clone_uri}</a></li> |
|
|||
195 | </ul> |
|
|||
196 | </div> |
|
|||
197 | </div> |
|
|||
198 | </div> |
|
|||
199 | ${h.end_form()} |
|
|||
200 | %endif |
|
|||
201 |
|
||||
202 | <h3>${_('Cache')}</h3> |
|
|||
203 | ${h.form(url('repo_cache', repo_name=c.repo_info.repo_name),method='delete')} |
|
|||
204 | <div class="form"> |
|
|||
205 | <div class="fields"> |
|
|||
206 | ${h.submit('reset_cache_%s' % c.repo_info.repo_name,_('Invalidate repository cache'),class_="ui-btn",onclick="return confirm('"+_('Confirm to invalidate repository cache')+"');")} |
|
|||
207 | <div class="field" style="border:none;color:#888"> |
|
|||
208 | <ul> |
|
|||
209 | <li>${_('Manually invalidate cache for this repository. On first access repository will be cached again')} |
|
|||
210 | </li> |
|
|||
211 | </ul> |
|
|||
212 | </div> |
|
|||
213 | <div class="field" style="border:none;"> |
|
|||
214 | ${_('List of cached values')} |
|
|||
215 | <table> |
|
|||
216 | <tr> |
|
|||
217 | <th>${_('Prefix')}</th> |
|
|||
218 | <th>${_('Key')}</th> |
|
|||
219 | <th>${_('Active')}</th> |
|
|||
220 | </tr> |
|
|||
221 | %for cache in c.repo_info.cache_keys: |
|
|||
222 | <tr> |
|
|||
223 | <td>${cache.prefix or '-'}</td> |
|
|||
224 | <td>${cache.cache_key}</td> |
|
|||
225 | <td>${h.bool2icon(cache.cache_active)}</td> |
|
|||
226 | </tr> |
|
|||
227 | %endfor |
|
|||
228 | </table> |
|
|||
229 | </div> |
|
|||
230 | </div> |
|
|||
231 | </div> |
|
|||
232 | ${h.end_form()} |
|
|||
233 |
|
||||
234 | <h3>${_('Public journal')}</h3> |
|
|||
235 | ${h.form(url('repo_public_journal', repo_name=c.repo_info.repo_name),method='put')} |
|
|||
236 | <div class="form"> |
|
|||
237 | ${h.hidden('auth_token',str(h.get_token()))} |
|
|||
238 | <div class="field"> |
|
|||
239 | %if c.in_public_journal: |
|
|||
240 | ${h.submit('set_public_%s' % c.repo_info.repo_name,_('Remove from public journal'),class_="ui-btn")} |
|
|||
241 | %else: |
|
|||
242 | ${h.submit('set_public_%s' % c.repo_info.repo_name,_('Add to public journal'),class_="ui-btn")} |
|
|||
243 | %endif |
|
|||
244 | </div> |
|
|||
245 | <div class="field" style="border:none;color:#888"> |
|
|||
246 | <ul> |
|
|||
247 | <li>${_('All actions made on this repository will be accessible to everyone in public journal')} |
|
|||
248 | </li> |
|
|||
249 | </ul> |
|
|||
250 | </div> |
|
|||
251 | </div> |
|
|||
252 | ${h.end_form()} |
|
|||
253 |
|
||||
254 | <h3>${_('Locking')}</h3> |
|
|||
255 | ${h.form(url('repo_locking', repo_name=c.repo_info.repo_name),method='put')} |
|
|||
256 | <div class="form"> |
|
|||
257 | <div class="fields"> |
|
|||
258 | %if c.repo_info.locked[0]: |
|
|||
259 | ${h.submit('set_unlock' ,_('Unlock locked repo'),class_="ui-btn",onclick="return confirm('"+_('Confirm to unlock repository')+"');")} |
|
|||
260 | ${'Locked by %s on %s' % (h.person_by_id(c.repo_info.locked[0]),h.fmt_date(h.time_to_datetime(c.repo_info.locked[1])))} |
|
|||
261 | %else: |
|
|||
262 | ${h.submit('set_lock',_('lock repo'),class_="ui-btn",onclick="return confirm('"+_('Confirm to lock repository')+"');")} |
|
|||
263 | ${_('Repository is not locked')} |
|
|||
264 | %endif |
|
|||
265 | </div> |
|
|||
266 | <div class="field" style="border:none;color:#888"> |
|
179 | <div class="field" style="border:none;color:#888"> | |
267 | <ul> |
|
180 | <ul> | |
268 | <li>${_('Force locking on repository. Works only when anonymous access is disabled')} |
|
181 | <li>${_('Fetched to rev')}: ${c.stats_revision}/${c.repo_last_rev}</li> | |
269 | </li> |
|
182 | <li>${_('Stats gathered')}: ${c.stats_percentage}%</li> | |
|
183 | </ul> | |||
|
184 | </div> | |||
|
185 | </div> | |||
|
186 | </div> | |||
|
187 | ${h.end_form()} | |||
|
188 | ||||
|
189 | %if c.repo_info.clone_uri: | |||
|
190 | <h3>${_('Remote')}</h3> | |||
|
191 | ${h.form(url('repo_pull', repo_name=c.repo_info.repo_name),method='put')} | |||
|
192 | <div class="form"> | |||
|
193 | <div class="fields"> | |||
|
194 | ${h.submit('remote_pull_%s' % c.repo_info.repo_name,_('Pull changes from remote location'),class_="ui-btn",onclick="return confirm('"+_('Confirm to pull changes from remote side')+"');")} | |||
|
195 | <div class="field" style="border:none"> | |||
|
196 | <ul> | |||
|
197 | <li><a href="${c.repo_info.clone_uri}">${c.repo_info.clone_uri}</a></li> | |||
270 | </ul> |
|
198 | </ul> | |
271 | </div> |
|
199 | </div> | |
272 |
|
|
200 | </div> | |
273 | ${h.end_form()} |
|
201 | </div> | |
|
202 | ${h.end_form()} | |||
|
203 | %endif | |||
|
204 | ||||
|
205 | <h3>${_('Cache')}</h3> | |||
|
206 | ${h.form(url('repo_cache', repo_name=c.repo_info.repo_name),method='delete')} | |||
|
207 | <div class="form"> | |||
|
208 | <div class="fields"> | |||
|
209 | ${h.submit('reset_cache_%s' % c.repo_info.repo_name,_('Invalidate repository cache'),class_="ui-btn",onclick="return confirm('"+_('Confirm to invalidate repository cache')+"');")} | |||
|
210 | <div class="field" style="border:none;color:#888"> | |||
|
211 | <ul> | |||
|
212 | <li>${_('Manually invalidate cache for this repository. On first access repository will be cached again')} | |||
|
213 | </li> | |||
|
214 | </ul> | |||
|
215 | </div> | |||
|
216 | <div class="field" style="border:none;"> | |||
|
217 | ${_('List of cached values')} | |||
|
218 | <table> | |||
|
219 | <tr> | |||
|
220 | <th>${_('Prefix')}</th> | |||
|
221 | <th>${_('Key')}</th> | |||
|
222 | <th>${_('Active')}</th> | |||
|
223 | </tr> | |||
|
224 | %for cache in c.repo_info.cache_keys: | |||
|
225 | <tr> | |||
|
226 | <td>${cache.prefix or '-'}</td> | |||
|
227 | <td>${cache.cache_key}</td> | |||
|
228 | <td>${h.bool2icon(cache.cache_active)}</td> | |||
|
229 | </tr> | |||
|
230 | %endfor | |||
|
231 | </table> | |||
|
232 | </div> | |||
|
233 | </div> | |||
|
234 | </div> | |||
|
235 | ${h.end_form()} | |||
274 |
|
236 | |||
275 |
|
|
237 | <h3>${_('Public journal')}</h3> | |
276 |
|
|
238 | ${h.form(url('repo_public_journal', repo_name=c.repo_info.repo_name),method='put')} | |
277 |
|
|
239 | <div class="form"> | |
278 | <div class="fields"> |
|
240 | ${h.hidden('auth_token',str(h.get_token()))} | |
279 | ${h.select('id_fork_of','',c.repos_list,class_="medium")} |
|
241 | <div class="field"> | |
280 | ${h.submit('set_as_fork_%s' % c.repo_info.repo_name,_('set'),class_="ui-btn",)} |
|
242 | %if c.in_public_journal: | |
281 | </div> |
|
243 | ${h.submit('set_public_%s' % c.repo_info.repo_name,_('Remove from public journal'),class_="ui-btn")} | |
282 | <div class="field" style="border:none;color:#888"> |
|
244 | %else: | |
283 | <ul> |
|
245 | ${h.submit('set_public_%s' % c.repo_info.repo_name,_('Add to public journal'),class_="ui-btn")} | |
284 | <li>${_('''Manually set this repository as a fork of another from the list''')}</li> |
|
246 | %endif | |
285 | </ul> |
|
247 | </div> | |
286 | </div> |
|
248 | <div class="field" style="border:none;color:#888"> | |
287 |
|
|
249 | <ul> | |
288 | ${h.end_form()} |
|
250 | <li>${_('All actions made on this repository will be accessible to everyone in public journal')} | |
|
251 | </li> | |||
|
252 | </ul> | |||
|
253 | </div> | |||
|
254 | </div> | |||
|
255 | ${h.end_form()} | |||
289 |
|
256 | |||
290 |
|
|
257 | <h3>${_('Locking')}</h3> | |
291 |
|
|
258 | ${h.form(url('repo_locking', repo_name=c.repo_info.repo_name),method='put')} | |
292 |
|
|
259 | <div class="form"> | |
293 |
|
|
260 | <div class="fields"> | |
294 | ${h.submit('remove_%s' % c.repo_info.repo_name,_('Remove this repository'),class_="ui-btn red",onclick="return confirm('"+_('Confirm to delete this repository')+"');")} |
|
261 | %if c.repo_info.locked[0]: | |
295 | %if c.repo_info.forks.count(): |
|
262 | ${h.submit('set_unlock' ,_('Unlock locked repo'),class_="ui-btn",onclick="return confirm('"+_('Confirm to unlock repository')+"');")} | |
296 | - ${ungettext('this repository has %s fork', 'this repository has %s forks', c.repo_info.forks.count()) % c.repo_info.forks.count()} |
|
263 | ${'Locked by %s on %s' % (h.person_by_id(c.repo_info.locked[0]),h.fmt_date(h.time_to_datetime(c.repo_info.locked[1])))} | |
297 | <input type="radio" name="forks" value="detach_forks" checked="checked"/> <label for="forks">${_('Detach forks')}</label> |
|
264 | %else: | |
298 | <input type="radio" name="forks" value="delete_forks" /> <label for="forks">${_('Delete forks')}</label> |
|
265 | ${h.submit('set_lock',_('lock repo'),class_="ui-btn",onclick="return confirm('"+_('Confirm to lock repository')+"');")} | |
299 | %endif |
|
266 | ${_('Repository is not locked')} | |
300 |
|
|
267 | %endif | |
|
268 | </div> | |||
|
269 | <div class="field" style="border:none;color:#888"> | |||
|
270 | <ul> | |||
|
271 | <li>${_('Force locking on repository. Works only when anonymous access is disabled')} | |||
|
272 | </li> | |||
|
273 | </ul> | |||
|
274 | </div> | |||
|
275 | </div> | |||
|
276 | ${h.end_form()} | |||
|
277 | ||||
|
278 | <h3>${_('Set as fork of')}</h3> | |||
|
279 | ${h.form(url('repo_as_fork', repo_name=c.repo_info.repo_name),method='put')} | |||
|
280 | <div class="form"> | |||
|
281 | <div class="fields"> | |||
|
282 | ${h.select('id_fork_of','',c.repos_list,class_="medium")} | |||
|
283 | ${h.submit('set_as_fork_%s' % c.repo_info.repo_name,_('set'),class_="ui-btn",)} | |||
|
284 | </div> | |||
301 | <div class="field" style="border:none;color:#888"> |
|
285 | <div class="field" style="border:none;color:#888"> | |
302 | <ul> |
|
286 | <ul> | |
303 | <li>${_('This repository will be renamed in a special way in order to be unaccesible for RhodeCode and VCS systems. If you need to fully delete it from file system please do it manually')}</li> |
|
287 | <li>${_('''Manually set this repository as a fork of another from the list''')}</li> | |
304 | </ul> |
|
288 | </ul> | |
305 | </div> |
|
289 | </div> | |
|
290 | </div> | |||
|
291 | ${h.end_form()} | |||
|
292 | ||||
|
293 | <h3>${_('Delete')}</h3> | |||
|
294 | ${h.form(url('repo', repo_name=c.repo_info.repo_name),method='delete')} | |||
|
295 | <div class="form"> | |||
|
296 | <div class="fields"> | |||
|
297 | <div class="field" style="border:none;color:#888"> | |||
|
298 | ## <div class="label"> | |||
|
299 | ## <label for="">${_('Remove repository')}:</label> | |||
|
300 | ## </div> | |||
|
301 | <div class="checkboxes"> | |||
|
302 | ${h.submit('remove_%s' % c.repo_info.repo_name,_('Remove this repository'),class_="ui-btn red",onclick="return confirm('"+_('Confirm to delete this repository')+"');")} | |||
|
303 | %if c.repo_info.forks.count(): | |||
|
304 | - ${ungettext('this repository has %s fork', 'this repository has %s forks', c.repo_info.forks.count()) % c.repo_info.forks.count()} | |||
|
305 | <input type="radio" name="forks" value="detach_forks" checked="checked"/> <label for="forks">${_('Detach forks')}</label> | |||
|
306 | <input type="radio" name="forks" value="delete_forks" /> <label for="forks">${_('Delete forks')}</label> | |||
|
307 | %endif | |||
|
308 | <ul> | |||
|
309 | <li>${_('This repository will be renamed in a special way in order to be unaccesible for RhodeCode and VCS systems. If you need to fully delete it from file system please do it manually')}</li> | |||
|
310 | </ul> | |||
|
311 | </div> | |||
|
312 | </div> | |||
306 | </div> |
|
313 | </div> | |
307 | ${h.end_form()} |
|
314 | </div> | |
|
315 | ${h.end_form()} | |||
308 | </div> |
|
316 | </div> | |
309 |
|
317 | |||
310 | ##TODO: this should be controlled by the VISUAL setting |
|
318 | ##TODO: this should be controlled by the VISUAL setting | |
311 | %if c.visual.repository_fields: |
|
319 | %if c.visual.repository_fields: | |
312 | <div class="box box-left" style="clear:left"> |
|
320 | <div class="box box-left" style="clear:left"> | |
313 | <!-- box / title --> |
|
321 | <!-- box / title --> | |
314 | <div class="title"> |
|
322 | <div class="title"> | |
315 | <h5>${_('Extra fields')}</h5> |
|
323 | <h5>${_('Extra fields')}</h5> | |
316 | </div> |
|
324 | </div> | |
317 |
|
325 | |||
318 | <div class="emails_wrap"> |
|
326 | <div class="emails_wrap"> | |
319 | <table class="noborder"> |
|
327 | <table class="noborder"> | |
320 | %for field in c.repo_fields: |
|
328 | %for field in c.repo_fields: | |
321 | <tr> |
|
329 | <tr> | |
322 | <td>${field.field_label} (${field.field_key})</td> |
|
330 | <td>${field.field_label} (${field.field_key})</td> | |
323 | <td>${field.field_type}</td> |
|
331 | <td>${field.field_type}</td> | |
324 | <td> |
|
332 | <td> | |
325 | ${h.form(url('delete_repo_fields', repo_name=c.repo_info.repo_name, field_id=field.repo_field_id),method='delete')} |
|
333 | ${h.form(url('delete_repo_fields', repo_name=c.repo_info.repo_name, field_id=field.repo_field_id),method='delete')} | |
326 | ${h.submit('remove_%s' % field.repo_field_id, _('delete'), id="remove_field_%s" % field.repo_field_id, |
|
334 | ${h.submit('remove_%s' % field.repo_field_id, _('delete'), id="remove_field_%s" % field.repo_field_id, | |
327 | class_="delete_icon action_button", onclick="return confirm('"+_('Confirm to delete this field: %s') % field.field_key+"');")} |
|
335 | class_="delete_icon action_button", onclick="return confirm('"+_('Confirm to delete this field: %s') % field.field_key+"');")} | |
328 | ${h.end_form()} |
|
336 | ${h.end_form()} | |
329 | </td> |
|
337 | </td> | |
330 | </tr> |
|
338 | </tr> | |
331 | %endfor |
|
339 | %endfor | |
332 | </table> |
|
340 | </table> | |
333 | </div> |
|
341 | </div> | |
334 |
|
342 | |||
335 | ${h.form(url('create_repo_fields', repo_name=c.repo_info.repo_name),method='put')} |
|
343 | ${h.form(url('create_repo_fields', repo_name=c.repo_info.repo_name),method='put')} | |
336 | <div class="form"> |
|
344 | <div class="form"> | |
337 | <!-- fields --> |
|
345 | <!-- fields --> | |
338 | <div class="fields"> |
|
346 | <div class="fields"> | |
339 | <div class="field"> |
|
347 | <div class="field"> | |
340 | <div class="label"> |
|
348 | <div class="label"> | |
341 | <label for="new_field_key">${_('New field key')}:</label> |
|
349 | <label for="new_field_key">${_('New field key')}:</label> | |
342 | </div> |
|
350 | </div> | |
343 | <div class="input"> |
|
351 | <div class="input"> | |
344 | ${h.text('new_field_key', class_='small')} |
|
352 | ${h.text('new_field_key', class_='small')} | |
345 | </div> |
|
353 | </div> | |
346 | </div> |
|
354 | </div> | |
347 | <div class="field"> |
|
355 | <div class="field"> | |
348 | <div class="label"> |
|
356 | <div class="label"> | |
349 | <label for="new_field_label">${_('New field label')}:</label> |
|
357 | <label for="new_field_label">${_('New field label')}:</label> | |
350 | </div> |
|
358 | </div> | |
351 | <div class="input"> |
|
359 | <div class="input"> | |
352 | ${h.text('new_field_label', class_='small', placeholder=_('Enter short label'))} |
|
360 | ${h.text('new_field_label', class_='small', placeholder=_('Enter short label'))} | |
353 | </div> |
|
361 | </div> | |
354 | </div> |
|
362 | </div> | |
355 |
|
363 | |||
356 | <div class="field"> |
|
364 | <div class="field"> | |
357 | <div class="label"> |
|
365 | <div class="label"> | |
358 | <label for="new_field_desc">${_('New field description')}:</label> |
|
366 | <label for="new_field_desc">${_('New field description')}:</label> | |
359 | </div> |
|
367 | </div> | |
360 | <div class="input"> |
|
368 | <div class="input"> | |
361 | ${h.text('new_field_desc', class_='small', placeholder=_('Enter description of a field'))} |
|
369 | ${h.text('new_field_desc', class_='small', placeholder=_('Enter description of a field'))} | |
362 | </div> |
|
370 | </div> | |
363 | </div> |
|
371 | </div> | |
364 |
|
372 | |||
365 | <div class="buttons"> |
|
373 | <div class="buttons"> | |
366 | ${h.submit('save',_('Add'),class_="ui-btn large")} |
|
374 | ${h.submit('save',_('Add'),class_="ui-btn large")} | |
367 | ${h.reset('reset',_('Reset'),class_="ui-btn large")} |
|
375 | ${h.reset('reset',_('Reset'),class_="ui-btn large")} | |
368 | </div> |
|
376 | </div> | |
369 | </div> |
|
377 | </div> | |
370 | </div> |
|
378 | </div> | |
371 | ${h.end_form()} |
|
379 | ${h.end_form()} | |
372 | </div> |
|
380 | </div> | |
373 | %endif |
|
381 | %endif | |
374 | </%def> |
|
382 | </%def> |
@@ -1,146 +1,140 b'' | |||||
1 | ## -*- coding: utf-8 -*- |
|
1 | ## -*- coding: utf-8 -*- | |
|
2 | ## | |||
|
3 | ## See also repo_edit.html | |||
|
4 | ## | |||
2 | <%inherit file="/base/base.html"/> |
|
5 | <%inherit file="/base/base.html"/> | |
3 |
|
6 | |||
4 | <%def name="title()"> |
|
7 | <%def name="title()"> | |
5 | ${_('%s Settings') % c.repo_name} · ${c.rhodecode_name} |
|
8 | ${_('%s Settings') % c.repo_name} · ${c.rhodecode_name} | |
6 | </%def> |
|
9 | </%def> | |
7 |
|
10 | |||
8 | <%def name="breadcrumbs_links()"> |
|
11 | <%def name="breadcrumbs_links()"> | |
9 | ${h.link_to(_(u'Home'),h.url('/'))} |
|
12 | ${h.link_to(_(u'Home'),h.url('/'))} | |
10 | » |
|
13 | » | |
11 | ${h.link_to(c.repo_info.repo_name,h.url('summary_home',repo_name=c.repo_info.repo_name))} |
|
14 | ${h.link_to(c.repo_info.repo_name,h.url('summary_home',repo_name=c.repo_info.repo_name))} | |
12 | » |
|
15 | » | |
13 | ${_('Settings')} |
|
16 | ${_('Settings')} | |
14 | </%def> |
|
17 | </%def> | |
15 |
|
18 | |||
16 | <%def name="page_nav()"> |
|
19 | <%def name="page_nav()"> | |
17 | ${self.menu('settings')} |
|
20 | ${self.menu('settings')} | |
18 | </%def> |
|
21 | </%def> | |
19 | <%def name="main()"> |
|
22 | <%def name="main()"> | |
20 | <div class="box"> |
|
23 | <div class="box"> | |
21 | <!-- box / title --> |
|
24 | <!-- box / title --> | |
22 | <div class="title"> |
|
25 | <div class="title"> | |
23 | ${self.breadcrumbs()} |
|
26 | ${self.breadcrumbs()} | |
24 | </div> |
|
27 | </div> | |
25 | ${h.form(url('repo_settings_update', repo_name=c.repo_info.repo_name),method='put')} |
|
28 | ${h.form(url('repo_settings_update', repo_name=c.repo_info.repo_name),method='put')} | |
26 | <div class="form"> |
|
29 | <div class="form"> | |
27 | <!-- fields --> |
|
30 | <!-- fields --> | |
28 | <div class="fields"> |
|
31 | <div class="fields"> | |
29 | <div class="field"> |
|
32 | <div class="field"> | |
30 | <div class="label"> |
|
33 | <div class="label"> | |
31 | <label for="repo_name">${_('Name')}:</label> |
|
34 | <label for="repo_name">${_('Name')}:</label> | |
32 | </div> |
|
35 | </div> | |
33 |
<div class="input |
|
36 | <div class="input"> | |
34 |
${h.text('repo_name',class_=" |
|
37 | ${h.text('repo_name',class_="medium")} | |
35 | </div> |
|
38 | </div> | |
36 |
|
|
39 | </div> | |
37 | <div class="field"> |
|
40 | <div class="field"> | |
38 | <div class="label"> |
|
41 | <div class="label"> | |
39 | <label for="clone_uri">${_('Clone uri')}:</label> |
|
42 | <label for="clone_uri">${_('Clone uri')}:</label> | |
40 | </div> |
|
43 | </div> | |
41 | <div class="input"> |
|
44 | <div class="input"> | |
42 | ${h.text('clone_uri',class_="medium")} |
|
45 | ${h.text('clone_uri',class_="medium")} | |
43 | <span class="help-block">${_('Optional http[s] url from which repository should be cloned.')}</span> |
|
46 | <span class="help-block">${_('Optional http[s] url from which repository should be cloned.')}</span> | |
44 | </div> |
|
47 | </div> | |
45 | </div> |
|
48 | </div> | |
46 | <div class="field"> |
|
49 | <div class="field"> | |
47 | <div class="label"> |
|
50 | <div class="label"> | |
48 | <label for="repo_group">${_('Repository group')}:</label> |
|
51 | <label for="repo_group">${_('Repository group')}:</label> | |
49 | </div> |
|
52 | </div> | |
50 | <div class="input"> |
|
53 | <div class="input"> | |
51 | ${h.select('repo_group','',c.repo_groups,class_="medium")} |
|
54 | ${h.select('repo_group','',c.repo_groups,class_="medium")} | |
52 | <span class="help-block">${_('Optional select a group to put this repository into.')}</span> |
|
55 | <span class="help-block">${_('Optional select a group to put this repository into.')}</span> | |
53 | </div> |
|
56 | </div> | |
54 | </div> |
|
57 | </div> | |
55 | <div class="field"> |
|
58 | <div class="field"> | |
56 | <div class="label"> |
|
59 | <div class="label"> | |
57 | <label for="landing_rev">${_('Landing revision')}:</label> |
|
60 | <label for="landing_rev">${_('Landing revision')}:</label> | |
58 | </div> |
|
61 | </div> | |
59 | <div class="input"> |
|
62 | <div class="input"> | |
60 | ${h.select('repo_landing_rev','',c.landing_revs,class_="medium")} |
|
63 | ${h.select('repo_landing_rev','',c.landing_revs,class_="medium")} | |
61 | <span class="help-block">${_('Default revision for files page, downloads, whoosh and readme')}</span> |
|
64 | <span class="help-block">${_('Default revision for files page, downloads, whoosh and readme')}</span> | |
62 | </div> |
|
65 | </div> | |
63 | </div> |
|
66 | </div> | |
64 | <div class="field"> |
|
67 | <div class="field"> | |
65 | <div class="label label-textarea"> |
|
68 | <div class="label label-textarea"> | |
66 | <label for="repo_description">${_('Description')}:</label> |
|
69 | <label for="repo_description">${_('Description')}:</label> | |
67 | </div> |
|
70 | </div> | |
68 | <div class="textarea text-area editor"> |
|
71 | <div class="textarea text-area editor"> | |
69 | ${h.textarea('repo_description')} |
|
72 | ${h.textarea('repo_description')} | |
70 | <span class="help-block">${_('Keep it short and to the point. Use a README file for longer descriptions.')}</span> |
|
73 | <span class="help-block">${_('Keep it short and to the point. Use a README file for longer descriptions.')}</span> | |
71 | </div> |
|
74 | </div> | |
72 | </div> |
|
75 | </div> | |
73 |
|
76 | |||
74 | <div class="field"> |
|
77 | <div class="field"> | |
75 | <div class="label label-checkbox"> |
|
78 | <div class="label label-checkbox"> | |
76 | <label for="repo_private">${_('Private repository')}:</label> |
|
79 | <label for="repo_private">${_('Private repository')}:</label> | |
77 | </div> |
|
80 | </div> | |
78 | <div class="checkboxes"> |
|
81 | <div class="checkboxes"> | |
79 | ${h.checkbox('repo_private',value="True")} |
|
82 | ${h.checkbox('repo_private',value="True")} | |
80 | <span class="help-block">${_('Private repositories are only visible to people explicitly added as collaborators.')}</span> |
|
83 | <span class="help-block">${_('Private repositories are only visible to people explicitly added as collaborators.')}</span> | |
81 | </div> |
|
84 | </div> | |
82 | </div> |
|
85 | </div> | |
83 | %if c.visual.repository_fields: |
|
86 | %if c.visual.repository_fields: | |
84 | ## EXTRA FIELDS |
|
87 | ## EXTRA FIELDS | |
85 | %for field in c.repo_fields: |
|
88 | %for field in c.repo_fields: | |
86 | <div class="field"> |
|
89 | <div class="field"> | |
87 | <div class="label"> |
|
90 | <div class="label"> | |
88 | <label for="${field.field_key_prefixed}">${field.field_label} (${field.field_key}):</label> |
|
91 | <label for="${field.field_key_prefixed}">${field.field_label} (${field.field_key}):</label> | |
89 | </div> |
|
92 | </div> | |
90 | <div class="input input-medium"> |
|
93 | <div class="input input-medium"> | |
91 | ${h.text(field.field_key_prefixed, field.field_value, class_='medium')} |
|
94 | ${h.text(field.field_key_prefixed, field.field_value, class_='medium')} | |
92 | %if field.field_desc: |
|
95 | %if field.field_desc: | |
93 | <span class="help-block">${field.field_desc}</span> |
|
96 | <span class="help-block">${field.field_desc}</span> | |
94 | %endif |
|
97 | %endif | |
95 | </div> |
|
98 | </div> | |
96 | </div> |
|
99 | </div> | |
97 | %endfor |
|
100 | %endfor | |
98 | %endif |
|
101 | %endif | |
99 |
|
102 | <div class="field"> | ||
100 | <div class="field"> |
|
|||
101 | <div class="label"> |
|
103 | <div class="label"> | |
102 | <label for="">${_('Permissions')}:</label> |
|
104 | <label for="input">${_('Permissions')}:</label> | |
103 | </div> |
|
105 | </div> | |
104 | <div class="input"> |
|
106 | <div class="input"> | |
105 | <%include file="../admin/repos/repo_edit_perms.html"/> |
|
107 | <%include file="../admin/repos/repo_edit_perms.html"/> | |
106 | </div> |
|
108 | </div> | |
107 | </div> |
|
109 | </div> | |
108 |
|
110 | |||
109 | <div class="buttons"> |
|
111 | <div class="buttons"> | |
110 | ${h.submit('save',_('Save'),class_="ui-btn large")} |
|
112 | ${h.submit('save',_('Save'),class_="ui-btn large")} | |
111 | ${h.reset('reset',_('Reset'),class_="ui-btn large")} |
|
113 | ${h.reset('reset',_('Reset'),class_="ui-btn large")} | |
112 | </div> |
|
114 | </div> | |
113 |
|
115 | |||
|
116 | </div> | |||
|
117 | </div> | |||
|
118 | ${h.end_form()} | |||
|
119 | ||||
|
120 | <h3>${_('Delete')}</h3> | |||
|
121 | ${h.form(url('repo_settings_delete', repo_name=c.repo_info.repo_name),method='delete')} | |||
|
122 | <div class="form"> | |||
|
123 | <div class="fields"> | |||
|
124 | <div class="field" style="border:none;color:#888"> | |||
|
125 | <div class="label"> | |||
|
126 | <label for="">${_('Remove repository')}:</label> | |||
|
127 | </div> | |||
|
128 | <div class="checkboxes"> | |||
|
129 | ${h.submit('remove_%s' % c.repo_info.repo_name,_('Remove this repository'),class_="ui-btn red",onclick="return confirm('"+_('Confirm to delete this repository')+"');")} | |||
|
130 | <ul> | |||
|
131 | <li>${_('This repository will be renamed in a special way in order to be unaccesible for RhodeCode and VCS systems. If you need to fully delete it from file system please do it manually')}</li> | |||
|
132 | </ul> | |||
|
133 | </div> | |||
|
134 | </div> | |||
|
135 | </div> | |||
114 | </div> |
|
136 | </div> | |
115 | ${h.end_form()} |
|
137 | ${h.end_form()} | |
116 | </div> |
|
|||
117 |
|
||||
118 | <h3>${_('Delete repository')}</h3> |
|
|||
119 | <div class="form"> |
|
|||
120 | <!-- fields --> |
|
|||
121 | <div class="fields"> |
|
|||
122 |
|
||||
123 | <div class="field"> |
|
|||
124 | <div class="label"> |
|
|||
125 | <label for="">${_('Remove repo')}:</label> |
|
|||
126 | </div> |
|
|||
127 | <div class="checkboxes"> |
|
|||
128 | ${h.form(url('repo_settings_delete', repo_name=c.repo_info.repo_name),method='delete')} |
|
|||
129 | <div class=""> |
|
|||
130 | <div class="fields"> |
|
|||
131 | ${h.submit('remove_%s' % c.repo_info.repo_name,_('Remove this repository'),class_="ui-btn red",onclick="return confirm('"+_('Confirm to delete this repository')+"');")} |
|
|||
132 | </div> |
|
|||
133 | <div class="field" style="border:none;color:#888"> |
|
|||
134 | <ul> |
|
|||
135 | <li>${_('This repository will be renamed in a special way in order to be unaccesible for RhodeCode and VCS systems. If you need fully delete it from file system please do it manually')}</li> |
|
|||
136 | </ul> |
|
|||
137 | </div> |
|
|||
138 | </div> |
|
|||
139 | ${h.end_form()} |
|
|||
140 | </div> |
|
|||
141 | </div> |
|
|||
142 | </div> |
|
|||
143 | </div> |
|
|||
144 |
|
138 | |||
145 | </div> |
|
139 | </div> | |
146 | </%def> |
|
140 | </%def> |
General Comments 0
You need to be logged in to leave comments.
Login now