annotate rhodecode/templates/files/files_add.html @ 3181:efe23d6c178c rhodecode-0.0.1.5.2

merged with beta
author Marcin Kuzminski <marcin@python-works.com>
date Mon, 21 Jan 2013 00:49:59 +0100
parents 79818f546538
children b4f401524060
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1483
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
1 <%inherit file="/base/base.html"/>
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
2
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
3 <%def name="title()">
2417
76d156bef5a2 Better i18n for page titles.
Vincent Duvert <vincent@duvert.net>
parents: 1888
diff changeset
4 ${_('%s Edit file') % c.repo_name} - ${c.rhodecode_name}
1483
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
5 </%def>
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
6
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
7 <%def name="js_extra()">
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
8 <script type="text/javascript" src="${h.url('/js/codemirror.js')}"></script>
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
9 </%def>
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
10 <%def name="css_extra()">
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
11 <link rel="stylesheet" type="text/css" href="${h.url('/css/codemirror.css')}"/>
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
12 </%def>
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
13
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
14 <%def name="breadcrumbs_links()">
2492
79818f546538 i18n 'Home' in breadcrumbs
Takumi IINO <trot.thunder@gmail.com>
parents: 2417
diff changeset
15 ${h.link_to(_(u'Home'),h.url('/'))}
1483
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
16 &raquo;
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
17 ${h.link_to(c.repo_name,h.url('summary_home',repo_name=c.repo_name))}
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
18 &raquo;
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
19 ${_('add file')} @ R${c.cs.revision}:${h.short_id(c.cs.raw_id)}
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
20 </%def>
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
21
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
22 <%def name="page_nav()">
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1756
diff changeset
23 ${self.menu('files')}
1483
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
24 </%def>
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
25 <%def name="main()">
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
26 <div class="box">
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
27 <!-- box / title -->
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
28 <div class="title">
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
29 ${self.breadcrumbs()}
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
30 <ul class="links">
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
31 <li>
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
32 <span style="text-transform: uppercase;">
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
33 <a href="#">${_('branch')}: ${c.cs.branch}</a></span>
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1756
diff changeset
34 </li>
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1756
diff changeset
35 </ul>
1483
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
36 </div>
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
37 <div class="table">
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
38 <div id="files_data">
1485
269905fac50a added uploading of files from web interface directly into repo
Marcin Kuzminski <marcin@python-works.com>
parents: 1484
diff changeset
39 ${h.form(h.url.current(),method='post',id='eform',enctype="multipart/form-data")}
1483
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
40 <h3>${_('Add new file')}</h3>
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
41 <div class="form">
1603
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
42 <div class="fields">
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
43 <div id="filename_container" class="field file">
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
44 <div class="label">
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
45 <label for="filename">${_('File Name')}:</label>
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
46 </div>
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
47 <div class="input">
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
48 <input type="text" value="" size="30" name="filename" id="filename">
1756
Marcin Kuzminski <marcin@python-works.com>
parents: 1720
diff changeset
49 ${_('or')} <span class="ui-btn" id="upload_file_enable">${_('Upload file')}</span>
1603
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
50 </div>
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1756
diff changeset
51 </div>
1603
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
52 <div id="upload_file_container" class="field" style="display:none">
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
53 <div class="label">
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
54 <label for="location">${_('Upload file')}</label>
1483
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
55 </div>
1603
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
56 <div class="file">
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
57 <input type="file" size="30" name="upload_file" id="upload_file">
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1756
diff changeset
58 ${_('or')} <span class="ui-btn" id="file_enable">${_('Create new file')}</span>
1603
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
59 </div>
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
60 </div>
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
61 <div class="field">
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
62 <div class="label">
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
63 <label for="location">${_('Location')}</label>
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
64 </div>
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
65 <div class="input">
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
66 <input type="text" value="${c.f_path}" size="30" name="location" id="location">
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
67 ${_('use / to separate directories')}
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
68 </div>
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1756
diff changeset
69 </div>
1603
53d076664e08 Changed order of add file form inputs.
Marcin Kuzminski <marcin@python-works.com>
parents: 1485
diff changeset
70 </div>
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1756
diff changeset
71 </div>
1483
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
72 <div id="body" class="codeblock">
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1756
diff changeset
73 <div id="editor_container">
1485
269905fac50a added uploading of files from web interface directly into repo
Marcin Kuzminski <marcin@python-works.com>
parents: 1484
diff changeset
74 <pre id="editor_pre"></pre>
269905fac50a added uploading of files from web interface directly into repo
Marcin Kuzminski <marcin@python-works.com>
parents: 1484
diff changeset
75 <textarea id="editor" name="content" style="display:none"></textarea>
269905fac50a added uploading of files from web interface directly into repo
Marcin Kuzminski <marcin@python-works.com>
parents: 1484
diff changeset
76 </div>
1484
1db451a44504 fixed small issues with adding new filenodes
Marcin Kuzminski <marcin@python-works.com>
parents: 1483
diff changeset
77 <div style="padding: 10px;color:#666666">${_('commit message')}</div>
1485
269905fac50a added uploading of files from web interface directly into repo
Marcin Kuzminski <marcin@python-works.com>
parents: 1484
diff changeset
78 <textarea id="commit" name="message" style="height: 100px;width: 99%;margin-left:4px"></textarea>
1483
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
79 </div>
1720
48840976caa8 button style fix on edit and add files
Marcin Kuzminski <marcin@python-works.com>
parents: 1699
diff changeset
80 <div style="text-align: l;padding-top: 5px">
1756
Marcin Kuzminski <marcin@python-works.com>
parents: 1720
diff changeset
81 ${h.submit('commit',_('Commit changes'),class_="ui-btn")}
Marcin Kuzminski <marcin@python-works.com>
parents: 1720
diff changeset
82 ${h.reset('reset',_('Reset'),class_="ui-btn")}
1483
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
83 </div>
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
84 ${h.end_form()}
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
85 <script type="text/javascript">
1699
623b228cf325 cleaned up JS files in files templates.
Marcin Kuzminski <marcin@python-works.com>
parents: 1603
diff changeset
86 var reset_url = "${h.url('files_home',repo_name=c.repo_name,revision=c.cs.raw_id,f_path=c.f_path)}";
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1756
diff changeset
87 initCodeMirror('editor',reset_url);
1483
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
88 </script>
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1756
diff changeset
89 </div>
1483
7b67b0dcad6d Added initial support for creating new nodes in repos
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
90 </div>
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1756
diff changeset
91 </div>
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1756
diff changeset
92 </%def>