##// END OF EJS Templates
pull-requests: added commit flow into pr listing tables
super-admin -
r5170:a77dd674 default
parent child Browse files
Show More
@@ -91,6 +91,10 b' formencode==2.0.1'
91 91 six==1.16.0
92 92 gunicorn==21.2.0
93 93 packaging==23.1
94 gevent==23.7.0
95 greenlet==2.0.2
96 zope.event==5.0.0
97 zope.interface==6.0.0
94 98 infrae.cache==1.0.1
95 99 beaker==1.12.1
96 100 repoze.lru==0.7
@@ -706,6 +706,7 b' class MyAccountView(BaseAppView, DataGri'
706 706 'my_status': _render('pullrequest_status',
707 707 my_review_status),
708 708 'title': _render('pullrequest_title', pr.title, pr.description),
709 'pr_flow': _render('pullrequest_commit_flow', pr),
709 710 'description': h.escape(pr.description),
710 711 'updated_on': _render('pullrequest_updated_on',
711 712 h.datetime_to_time(pr.updated_on),
@@ -124,6 +124,7 b' class RepoPullRequestsView(RepoAppView, '
124 124 'my_status': _render('pullrequest_status',
125 125 my_review_status),
126 126 'title': _render('pullrequest_title', pr.title, pr.description),
127 'pr_flow': _render('pullrequest_commit_flow', pr),
127 128 'description': h.escape(pr.description),
128 129 'updated_on': _render('pullrequest_updated_on',
129 130 h.datetime_to_time(pr.updated_on),
@@ -95,6 +95,12 b''
95 95 },
96 96 {
97 97 data: {
98 "_": "pr_flow",
99 "sort": "pr_flow"
100 }, title: "${_('Flow')}", className: "td-componentname"
101 },
102 {
103 data: {
98 104 "_": "author",
99 105 "sort": "author_raw"
100 106 }, title: "${_('Author')}", className: "td-user", orderable: false
@@ -374,6 +374,25 b''
374 374 ${title}
375 375 </%def>
376 376
377 <%def name="pullrequest_commit_flow(pull_request)">
378 <div class="pr-commit-flow">
379 <%!
380 def pr_ref_type_to_icon(ref_type):
381 return dict(
382 branch='branch',
383 book='bookmark',
384 rev='history',
385 ).get(ref_type, 'branch')
386
387 %>
388 ## Source
389 <code class="pr-source-info"><i class="icon-${pr_ref_type_to_icon(pull_request.source_ref_parts.type)}"></i>${pull_request.source_ref_parts.name}</code>
390 &rarr;
391 ## Target
392 <code class="pr-target-info"><i class="icon-${pr_ref_type_to_icon(pull_request.target_ref_parts.type)}"></i>${pull_request.target_ref_parts.name}</code>
393 </div>
394 </%def>
395
377 396 <%def name="pullrequest_comments(comments_nr)">
378 397 <i class="icon-comment"></i> ${comments_nr}
379 398 </%def>
@@ -91,48 +91,54 b''
91 91 pageLength: ${c.visual.dashboard_items},
92 92 order: [[ 2, "desc" ]],
93 93 columns: [
94 {
95 data: {
96 "_": "status",
97 "sort": "status"
98 }, title: "PR", className: "td-status", orderable: false
99 },
100 {
101 data: {
102 "_": "my_status",
103 "sort": "status"
104 }, title: "You", className: "td-status", orderable: false
105 },
106 {
107 data: {
108 "_": "name",
109 "sort": "name_raw"
110 }, title: "${_('Id')}", className: "td-componentname", "type": "num"
111 },
112 {
113 data: {
114 "_": "title",
115 "sort": "title"
116 }, title: "${_('Title')}", className: "td-description"
117 },
118 {
119 data: {
120 "_": "author",
121 "sort": "author_raw"
122 }, title: "${_('Author')}", className: "td-user", orderable: false
123 },
124 {
125 data: {
126 "_": "comments",
127 "sort": "comments_raw"
128 }, title: "", className: "td-comments", orderable: false
129 },
130 {
131 data: {
132 "_": "updated_on",
133 "sort": "updated_on_raw"
134 }, title: "${_('Last Update')}", className: "td-time"
135 }
94 {
95 data: {
96 "_": "status",
97 "sort": "status"
98 }, title: "PR", className: "td-status", orderable: false
99 },
100 {
101 data: {
102 "_": "my_status",
103 "sort": "status"
104 }, title: "You", className: "td-status", orderable: false
105 },
106 {
107 data: {
108 "_": "name",
109 "sort": "name_raw"
110 }, title: "${_('Id')}", className: "td-componentname", "type": "num"
111 },
112 {
113 data: {
114 "_": "title",
115 "sort": "title"
116 }, title: "${_('Title')}", className: "td-description"
117 },
118 {
119 data: {
120 "_": "pr_flow",
121 "sort": "pr_flow"
122 }, title: "${_('Flow')}", className: "td-componentname"
123 },
124 {
125 data: {
126 "_": "author",
127 "sort": "author_raw"
128 }, title: "${_('Author')}", className: "td-user", orderable: false
129 },
130 {
131 data: {
132 "_": "comments",
133 "sort": "comments_raw"
134 }, title: "", className: "td-comments", orderable: false
135 },
136 {
137 data: {
138 "_": "updated_on",
139 "sort": "updated_on_raw"
140 }, title: "${_('Last Update')}", className: "td-time"
141 }
136 142 ],
137 143 language: {
138 144 paginate: DEFAULT_GRID_PAGINATION,
General Comments 0
You need to be logged in to leave comments. Login now