Mercurial > kallithea
annotate rhodecode/templates/pullrequests/pullrequest.html @ 2492:79818f546538 beta
i18n 'Home' in breadcrumbs
author | Takumi IINO <trot.thunder@gmail.com> |
---|---|
date | Wed, 20 Jun 2012 11:56:14 +0000 |
parents | f29469677319 |
children | 1c2ba03c42b4 |
rev | line source |
---|---|
2244
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
1 <%inherit file="/base/base.html"/> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
2 |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
3 <%def name="title()"> |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
4 ${c.repo_name} ${_('New pull request')} |
2244
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
5 </%def> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
6 |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
7 <%def name="breadcrumbs_links()"> |
2492
79818f546538
i18n 'Home' in breadcrumbs
Takumi IINO <trot.thunder@gmail.com>
parents:
2434
diff
changeset
|
8 ${h.link_to(_(u'Home'),h.url('/'))} |
2244
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
9 » |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
10 ${h.link_to(c.repo_name,h.url('changelog_home',repo_name=c.repo_name))} |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
11 » |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
12 ${_('New pull request')} |
2244
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
13 </%def> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
14 |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
15 <%def name="main()"> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
16 |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
17 <div class="box"> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
18 <!-- box / title --> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
19 <div class="title"> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
20 ${self.breadcrumbs()} |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
21 </div> |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
22 ${h.form(url('pullrequest', repo_name=c.repo_name), method='post', id='pull_request_form')} |
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
23 <div style="float:left;padding:0px 30px 30px 30px"> |
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
24 <div style="padding:0px 5px 5px 5px"> |
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
25 <span> |
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
26 <a id="refresh" href="#"> |
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
27 <img class="icon" title="${_('Refresh')}" alt="${_('Refresh')}" src="${h.url('/images/icons/arrow_refresh.png')}"/> |
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
28 ${_('refresh overview')} |
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
29 </a> |
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
30 </span> |
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
31 </div> |
2244
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
32 ##ORG |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
33 <div style="float:left"> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
34 <div class="fork_user"> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
35 <div class="gravatar"> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
36 <img alt="gravatar" src="${h.gravatar_url(c.rhodecode_db_repo.user.email,24)}"/> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
37 </div> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
38 <span style="font-size: 20px"> |
2395
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
39 ${h.select('org_repo','',c.org_repos,class_='refs')}:${h.select('org_ref','',c.org_refs,class_='refs')} |
2244
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
40 </span> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
41 <div style="padding:5px 3px 3px 42px;">${c.rhodecode_db_repo.description}</div> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
42 </div> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
43 <div style="clear:both;padding-top: 10px"></div> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
44 </div> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
45 <div style="float:left;font-size:24px;padding:0px 20px"> |
2395
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
46 <img height=32 width=32 src="${h.url('/images/arrow_right_64.png')}"/> |
2244
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
47 </div> |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
48 |
2244
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
49 ##OTHER, most Probably the PARENT OF THIS FORK |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
50 <div style="float:left"> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
51 <div class="fork_user"> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
52 <div class="gravatar"> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
53 <img alt="gravatar" src="${h.gravatar_url(c.rhodecode_db_repo.user.email,24)}"/> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
54 </div> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
55 <span style="font-size: 20px"> |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
56 ${h.select('other_repo',c.default_pull_request ,c.other_repos,class_='refs')}:${h.select('other_ref','',c.other_refs,class_='refs')} |
2244
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
57 </span> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
58 <div style="padding:5px 3px 3px 42px;">${c.rhodecode_db_repo.description}</div> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
59 </div> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
60 <div style="clear:both;padding-top: 10px"></div> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
61 </div> |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
62 <div style="clear:both;padding-top: 10px"></div> |
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
63 ## overview pulled by ajax |
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
64 <div style="float:left" id="pull_request_overview"></div> |
2396
51e3d60fed2f
added link for detailed overview in pull-request form
Marcin Kuzminski <marcin@python-works.com>
parents:
2395
diff
changeset
|
65 <div style="float:left;clear:both;padding:10px 10px 10px 0px;display:none"> |
51e3d60fed2f
added link for detailed overview in pull-request form
Marcin Kuzminski <marcin@python-works.com>
parents:
2395
diff
changeset
|
66 <a id="pull_request_overview_url" href="#">${_('Detailed compare view')}</a> |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
67 </div> |
2244
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
68 </div> |
2395
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
69 <div style="float:left; border-left:1px dashed #eee"> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
70 <h4>${_('Pull request reviewers')}</h4> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
71 <div id="reviewers" style="padding:0px 0px 0px 15px"> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
72 ##TODO: make this nicer :) |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
73 <table class="table noborder"> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
74 <tr> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
75 <td> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
76 <div> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
77 <div style="float:left"> |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
78 <div class="text" style="padding: 0px 0px 6px;">${_('Chosen reviewers')}</div> |
2395
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
79 ${h.select('review_members',[x[0] for x in c.review_members],c.review_members,multiple=True,size=8,style="min-width:210px")} |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
80 <div id="remove_all_elements" style="cursor:pointer;text-align:center"> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
81 ${_('Remove all elements')} |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
82 <img alt="remove" style="vertical-align:text-bottom" src="${h.url('/images/icons/arrow_right.png')}"/> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
83 </div> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
84 </div> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
85 <div style="float:left;width:20px;padding-top:50px"> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
86 <img alt="add" id="add_element" |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
87 style="padding:2px;cursor:pointer" |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
88 src="${h.url('/images/icons/arrow_left.png')}"/> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
89 <br /> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
90 <img alt="remove" id="remove_element" |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
91 style="padding:2px;cursor:pointer" |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
92 src="${h.url('/images/icons/arrow_right.png')}"/> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
93 </div> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
94 <div style="float:left"> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
95 <div class="text" style="padding: 0px 0px 6px;">${_('Available reviewers')}</div> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
96 ${h.select('available_members',[],c.available_members,multiple=True,size=8,style="min-width:210px")} |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
97 <div id="add_all_elements" style="cursor:pointer;text-align:center"> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
98 <img alt="add" style="vertical-align:text-bottom" src="${h.url('/images/icons/arrow_left.png')}"/> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
99 ${_('Add all elements')} |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
100 </div> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
101 </div> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
102 </div> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
103 </td> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
104 </tr> |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
105 </table> |
2395
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
106 </div> |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
107 </div> |
2395
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
108 <h3>${_('Create new pull request')}</h3> |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
109 |
2244
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
110 <div class="form"> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
111 <!-- fields --> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
112 |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
113 <div class="fields"> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
114 |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
115 <div class="field"> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
116 <div class="label"> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
117 <label for="pullrequest_title">${_('Title')}:</label> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
118 </div> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
119 <div class="input"> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
120 ${h.text('pullrequest_title',size=30)} |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
121 </div> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
122 </div> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
123 |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
124 <div class="field"> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
125 <div class="label label-textarea"> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
126 <label for="pullrequest_desc">${_('description')}:</label> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
127 </div> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
128 <div class="textarea text-area editor"> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
129 ${h.textarea('pullrequest_desc',size=30)} |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
130 </div> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
131 </div> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
132 |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
133 <div class="buttons"> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
134 ${h.submit('save',_('Send pull request'),class_="ui-button")} |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
135 ${h.reset('reset',_('Reset'),class_="ui-button")} |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
136 </div> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
137 </div> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
138 </div> |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
139 ${h.end_form()} |
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
140 |
2244
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
141 </div> |
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
142 |
2395
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
143 <script type="text/javascript"> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
144 MultiSelectWidget('review_members','available_members','pull_request_form'); |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
145 |
2395
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
146 var loadPreview = function(){ |
2396
51e3d60fed2f
added link for detailed overview in pull-request form
Marcin Kuzminski <marcin@python-works.com>
parents:
2395
diff
changeset
|
147 YUD.setStyle(YUD.get('pull_request_overview_url').parentElement,'display','none'); |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
148 var url = "${h.url('compare_url', |
2395
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
149 repo_name='org_repo', |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
150 org_ref_type='branch', org_ref='org_ref', |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
151 other_ref_type='branch', other_ref='other_ref', |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
152 repo='other_repo', |
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
153 as_form=True)}"; |
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
154 |
2395
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
155 var select_refs = YUQ('#pull_request_form select.refs') |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
156 |
2395
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
157 for(var i=0;i<select_refs.length;i++){ |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
158 var select_ref = select_refs[i]; |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
159 var select_ref_data = select_ref.value.split(':'); |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
160 var key = null; |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
161 var val = null; |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
162 if(select_ref_data.length>1){ |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
163 key = select_ref.name+"_type"; |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
164 val = select_ref_data[0]; |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
165 url = url.replace(key,val); |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
166 |
2395
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
167 key = select_ref.name; |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
168 val = select_ref_data[1]; |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
169 url = url.replace(key,val); |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
170 |
2395
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
171 }else{ |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
172 key = select_ref.name; |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
173 val = select_ref.value; |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
174 url = url.replace(key,val); |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
175 } |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
176 } |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
177 |
2396
51e3d60fed2f
added link for detailed overview in pull-request form
Marcin Kuzminski <marcin@python-works.com>
parents:
2395
diff
changeset
|
178 ypjax(url,'pull_request_overview', function(data){ |
51e3d60fed2f
added link for detailed overview in pull-request form
Marcin Kuzminski <marcin@python-works.com>
parents:
2395
diff
changeset
|
179 YUD.get('pull_request_overview_url').href = url; |
51e3d60fed2f
added link for detailed overview in pull-request form
Marcin Kuzminski <marcin@python-works.com>
parents:
2395
diff
changeset
|
180 YUD.setStyle(YUD.get('pull_request_overview_url').parentElement,'display',''); |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
181 }) |
2395
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
182 } |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
183 YUE.on('refresh','click',function(e){ |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
184 loadPreview() |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
185 }) |
2434
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
186 |
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
187 //lazy load overview after 0.5s |
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
188 setTimeout(loadPreview, 500) |
f29469677319
Added basic models for saving open pull requests
Marcin Kuzminski <marcin@python-works.com>
parents:
2396
diff
changeset
|
189 |
2395
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
190 </script> |
b262e349a7a5
created pull-request overview
Marcin Kuzminski <marcin@python-works.com>
parents:
2244
diff
changeset
|
191 |
2244
77e376fdc4c6
pull requests draft UI
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
192 </%def> |