Show More
@@ -1,157 +1,155 b'' | |||||
1 | <%namespace name="base" file="/base/base.html"/> |
|
1 | <%namespace name="base" file="/base/base.html"/> | |
2 |
|
2 | |||
3 | <div class="panel panel-default"> |
|
3 | <div class="panel panel-default"> | |
4 | <div class="panel-body"> |
|
4 | <div class="panel-body"> | |
5 | %if c.show_closed: |
|
5 | %if c.show_closed: | |
6 | ${h.checkbox('show_closed',checked="checked", label=_('Show Closed Pull Requests'))} |
|
6 | ${h.checkbox('show_closed',checked="checked", label=_('Show Closed Pull Requests'))} | |
7 | %else: |
|
7 | %else: | |
8 | ${h.checkbox('show_closed',label=_('Show Closed Pull Requests'))} |
|
8 | ${h.checkbox('show_closed',label=_('Show Closed Pull Requests'))} | |
9 | %endif |
|
9 | %endif | |
10 | </div> |
|
10 | </div> | |
11 | </div> |
|
11 | </div> | |
12 |
|
12 | |||
13 | <div class="panel panel-default"> |
|
13 | <div class="panel panel-default"> | |
14 | <div class="panel-heading"> |
|
14 | <div class="panel-heading"> | |
15 | <h3 class="panel-title">${_('Pull Requests You Opened')}</h3> |
|
15 | <h3 class="panel-title">${_('Pull Requests You Opened')}</h3> | |
16 | </div> |
|
16 | </div> | |
17 | <div class="panel-body"> |
|
17 | <div class="panel-body"> | |
18 | <div class="pullrequestlist"> |
|
18 | <div class="pullrequestlist"> | |
19 | %if c.my_pull_requests: |
|
19 | %if c.my_pull_requests: | |
20 | <table class="rctable"> |
|
20 | <table class="rctable"> | |
21 | <thead> |
|
21 | <thead> | |
22 | <th class="td-status"></th> |
|
22 | <th class="td-status"></th> | |
23 | <th>${_('Target Repo')}</th> |
|
23 | <th>${_('Target Repo')}</th> | |
24 | <th>${_('Author')}</th> |
|
24 | <th>${_('Author')}</th> | |
25 | <th></th> |
|
25 | <th></th> | |
26 | <th>${_('Title')}</th> |
|
26 | <th>${_('Title')}</th> | |
27 |
<th class="td-time">${_(' |
|
27 | <th class="td-time">${_('Last Update')}</th> | |
28 | <th></th> |
|
28 | <th></th> | |
29 | </thead> |
|
29 | </thead> | |
30 | %for pull_request in c.my_pull_requests: |
|
30 | %for pull_request in c.my_pull_requests: | |
31 | <tr class="${'closed' if pull_request.is_closed() else ''} prwrapper"> |
|
31 | <tr class="${'closed' if pull_request.is_closed() else ''} prwrapper"> | |
32 | <td class="td-status"> |
|
32 | <td class="td-status"> | |
33 | <div class="${'flag_status %s' % pull_request.calculated_review_status()} pull-left"></div> |
|
33 | <div class="${'flag_status %s' % pull_request.calculated_review_status()} pull-left"></div> | |
34 | </td> |
|
34 | </td> | |
35 | <td class="truncate-wrap td-componentname"> |
|
35 | <td class="truncate-wrap td-componentname"> | |
36 | <div class="truncate"> |
|
36 | <div class="truncate"> | |
37 | ${h.link_to(pull_request.target_repo.repo_name,h.url('summary_home',repo_name=pull_request.target_repo.repo_name))} |
|
37 | ${h.link_to(pull_request.target_repo.repo_name,h.url('summary_home',repo_name=pull_request.target_repo.repo_name))} | |
38 | </div> |
|
38 | </div> | |
39 | </td> |
|
39 | </td> | |
40 | <td class="user"> |
|
40 | <td class="user"> | |
41 | ${base.gravatar_with_user(pull_request.author.email, 16)} |
|
41 | ${base.gravatar_with_user(pull_request.author.email, 16)} | |
42 | </td> |
|
42 | </td> | |
43 | <td class="td-message expand_commit" data-pr-id="m${pull_request.pull_request_id}" title="${_('Expand commit message')}"> |
|
43 | <td class="td-message expand_commit" data-pr-id="m${pull_request.pull_request_id}" title="${_('Expand commit message')}"> | |
44 | <div class="show_more_col"> |
|
44 | <div class="show_more_col"> | |
45 | <i class="show_more"></i> |
|
45 | <i class="show_more"></i> | |
46 | </div> |
|
46 | </div> | |
47 | </td> |
|
47 | </td> | |
48 | <td class="mid td-description"> |
|
48 | <td class="mid td-description"> | |
49 | <div class="log-container truncate-wrap"> |
|
49 | <div class="log-container truncate-wrap"> | |
50 | <div class="message truncate" id="c-m${pull_request.pull_request_id}"><a href="${h.url('pullrequest_show',repo_name=pull_request.target_repo.repo_name,pull_request_id=pull_request.pull_request_id)}">#${pull_request.pull_request_id}: ${pull_request.title}</a>\ |
|
50 | <div class="message truncate" id="c-m${pull_request.pull_request_id}"><a href="${h.url('pullrequest_show',repo_name=pull_request.target_repo.repo_name,pull_request_id=pull_request.pull_request_id)}">#${pull_request.pull_request_id}: ${pull_request.title}</a>\ | |
51 | %if pull_request.is_closed(): |
|
51 | %if pull_request.is_closed(): | |
52 | (${_('Closed')})\ |
|
52 | (${_('Closed')})\ | |
53 | %endif |
|
53 | %endif | |
54 | <br/>${pull_request.description}</div> |
|
54 | <br/>${pull_request.description}</div> | |
55 | </div> |
|
55 | </div> | |
56 | </td> |
|
56 | </td> | |
57 |
|
||||
58 | <td class="td-time"> |
|
57 | <td class="td-time"> | |
59 |
${h.age_component(pull_request. |
|
58 | ${h.age_component(pull_request.updated_on)} | |
60 | </td> |
|
59 | </td> | |
61 | <td class="td-action repolist_actions"> |
|
60 | <td class="td-action repolist_actions"> | |
62 | ${h.secure_form(url('pullrequest_delete', repo_name=pull_request.target_repo.repo_name, pull_request_id=pull_request.pull_request_id),method='delete')} |
|
61 | ${h.secure_form(url('pullrequest_delete', repo_name=pull_request.target_repo.repo_name, pull_request_id=pull_request.pull_request_id),method='delete')} | |
63 | ${h.submit('remove_%s' % pull_request.pull_request_id, _('Delete'), |
|
62 | ${h.submit('remove_%s' % pull_request.pull_request_id, _('Delete'), | |
64 | class_="btn btn-link btn-danger",onclick="return confirm('"+_('Confirm to delete this pull request')+"');")} |
|
63 | class_="btn btn-link btn-danger",onclick="return confirm('"+_('Confirm to delete this pull request')+"');")} | |
65 | ${h.end_form()} |
|
64 | ${h.end_form()} | |
66 | </td> |
|
65 | </td> | |
67 | </tr> |
|
66 | </tr> | |
68 | %endfor |
|
67 | %endfor | |
69 | </table> |
|
68 | </table> | |
70 | %else: |
|
69 | %else: | |
71 | <h2><span class="empty_data">${_('You currently have no open pull requests.')}</span></h2> |
|
70 | <h2><span class="empty_data">${_('You currently have no open pull requests.')}</span></h2> | |
72 | %endif |
|
71 | %endif | |
73 | </div> |
|
72 | </div> | |
74 | </div> |
|
73 | </div> | |
75 | </div> |
|
74 | </div> | |
76 |
|
75 | |||
77 | <div class="panel panel-default"> |
|
76 | <div class="panel panel-default"> | |
78 | <div class="panel-heading"> |
|
77 | <div class="panel-heading"> | |
79 | <h3 class="panel-title">${_('Pull Requests You Participate In')}</h3> |
|
78 | <h3 class="panel-title">${_('Pull Requests You Participate In')}</h3> | |
80 | </div> |
|
79 | </div> | |
81 |
|
80 | |||
82 | <div class="panel-body"> |
|
81 | <div class="panel-body"> | |
83 | <div class="pullrequestlist"> |
|
82 | <div class="pullrequestlist"> | |
84 | %if c.participate_in_pull_requests: |
|
83 | %if c.participate_in_pull_requests: | |
85 | <table class="rctable"> |
|
84 | <table class="rctable"> | |
86 | <thead> |
|
85 | <thead> | |
87 | <th class="td-status"></th> |
|
86 | <th class="td-status"></th> | |
88 | <th>${_('Target Repo')}</th> |
|
87 | <th>${_('Target Repo')}</th> | |
89 | <th>${_('Author')}</th> |
|
88 | <th>${_('Author')}</th> | |
90 | <th></th> |
|
89 | <th></th> | |
91 | <th>${_('Title')}</th> |
|
90 | <th>${_('Title')}</th> | |
92 |
<th class="td-time">${_(' |
|
91 | <th class="td-time">${_('Last Update')}</th> | |
93 | </thead> |
|
92 | </thead> | |
94 | %for pull_request in c.participate_in_pull_requests: |
|
93 | %for pull_request in c.participate_in_pull_requests: | |
95 | <tr class="${'closed' if pull_request.is_closed() else ''} prwrapper"> |
|
94 | <tr class="${'closed' if pull_request.is_closed() else ''} prwrapper"> | |
96 | <td class="td-status"> |
|
95 | <td class="td-status"> | |
97 | <div class="${'flag_status %s' % pull_request.calculated_review_status()} pull-left"></div> |
|
96 | <div class="${'flag_status %s' % pull_request.calculated_review_status()} pull-left"></div> | |
98 | </td> |
|
97 | </td> | |
99 | <td class="truncate-wrap td-componentname"> |
|
98 | <td class="truncate-wrap td-componentname"> | |
100 | <div class="truncate"> |
|
99 | <div class="truncate"> | |
101 | ${h.link_to(pull_request.target_repo.repo_name,h.url('summary_home',repo_name=pull_request.target_repo.repo_name))} |
|
100 | ${h.link_to(pull_request.target_repo.repo_name,h.url('summary_home',repo_name=pull_request.target_repo.repo_name))} | |
102 | </div> |
|
101 | </div> | |
103 | </td> |
|
102 | </td> | |
104 | <td class="user"> |
|
103 | <td class="user"> | |
105 | ${base.gravatar_with_user(pull_request.author.email, 16)} |
|
104 | ${base.gravatar_with_user(pull_request.author.email, 16)} | |
106 | </td> |
|
105 | </td> | |
107 | <td class="td-message expand_commit" data-pr-id="p${pull_request.pull_request_id}" title="${_('Expand commit message')}"> |
|
106 | <td class="td-message expand_commit" data-pr-id="p${pull_request.pull_request_id}" title="${_('Expand commit message')}"> | |
108 | <div class="show_more_col"> |
|
107 | <div class="show_more_col"> | |
109 | <i class="show_more"></i> |
|
108 | <i class="show_more"></i> | |
110 | </div> |
|
109 | </div> | |
111 | </td> |
|
110 | </td> | |
112 | <td class="mid td-description"> |
|
111 | <td class="mid td-description"> | |
113 | <div class="log-container truncate-wrap"> |
|
112 | <div class="log-container truncate-wrap"> | |
114 | <div class="message truncate" id="c-p${pull_request.pull_request_id}"><a href="${h.url('pullrequest_show',repo_name=pull_request.target_repo.repo_name,pull_request_id=pull_request.pull_request_id)}">#${pull_request.pull_request_id}: ${pull_request.title}</a>\ |
|
113 | <div class="message truncate" id="c-p${pull_request.pull_request_id}"><a href="${h.url('pullrequest_show',repo_name=pull_request.target_repo.repo_name,pull_request_id=pull_request.pull_request_id)}">#${pull_request.pull_request_id}: ${pull_request.title}</a>\ | |
115 | %if pull_request.is_closed(): |
|
114 | %if pull_request.is_closed(): | |
116 | (${_('Closed')})\ |
|
115 | (${_('Closed')})\ | |
117 | %endif |
|
116 | %endif | |
118 | <br/>${pull_request.description}</div> |
|
117 | <br/>${pull_request.description}</div> | |
119 | </div> |
|
118 | </div> | |
120 | </td> |
|
119 | </td> | |
121 |
|
||||
122 | <td class="td-time"> |
|
120 | <td class="td-time"> | |
123 |
${h.age_component(pull_request. |
|
121 | ${h.age_component(pull_request.updated_on)} | |
124 | </td> |
|
122 | </td> | |
125 | </tr> |
|
123 | </tr> | |
126 | %endfor |
|
124 | %endfor | |
127 | </table> |
|
125 | </table> | |
128 | %else: |
|
126 | %else: | |
129 | <h2 class="empty_data">${_('There are currently no open pull requests requiring your participation.')}</h2> |
|
127 | <h2 class="empty_data">${_('There are currently no open pull requests requiring your participation.')}</h2> | |
130 | %endif |
|
128 | %endif | |
131 | </div> |
|
129 | </div> | |
132 | </div> |
|
130 | </div> | |
133 | </div> |
|
131 | </div> | |
134 |
|
132 | |||
135 | <script> |
|
133 | <script> | |
136 | $('#show_closed').on('click', function(e){ |
|
134 | $('#show_closed').on('click', function(e){ | |
137 | if($(this).is(":checked")){ |
|
135 | if($(this).is(":checked")){ | |
138 | window.location = "${h.url('my_account_pullrequests', pr_show_closed=1)}"; |
|
136 | window.location = "${h.url('my_account_pullrequests', pr_show_closed=1)}"; | |
139 | } |
|
137 | } | |
140 | else{ |
|
138 | else{ | |
141 | window.location = "${h.url('my_account_pullrequests')}"; |
|
139 | window.location = "${h.url('my_account_pullrequests')}"; | |
142 | } |
|
140 | } | |
143 | }); |
|
141 | }); | |
144 | $('.expand_commit').on('click',function(e){ |
|
142 | $('.expand_commit').on('click',function(e){ | |
145 | var target_expand = $(this); |
|
143 | var target_expand = $(this); | |
146 | var cid = target_expand.data('prId'); |
|
144 | var cid = target_expand.data('prId'); | |
147 |
|
145 | |||
148 | if (target_expand.hasClass('open')){ |
|
146 | if (target_expand.hasClass('open')){ | |
149 | $('#c-'+cid).css({'height': '2.75em', 'text-overflow': 'ellipsis', 'overflow':'hidden'}); |
|
147 | $('#c-'+cid).css({'height': '2.75em', 'text-overflow': 'ellipsis', 'overflow':'hidden'}); | |
150 | target_expand.removeClass('open'); |
|
148 | target_expand.removeClass('open'); | |
151 | } |
|
149 | } | |
152 | else { |
|
150 | else { | |
153 | $('#c-'+cid).css({'height': 'auto', 'text-overflow': 'initial', 'overflow':'visible'}); |
|
151 | $('#c-'+cid).css({'height': 'auto', 'text-overflow': 'initial', 'overflow':'visible'}); | |
154 | target_expand.addClass('open'); |
|
152 | target_expand.addClass('open'); | |
155 | } |
|
153 | } | |
156 | }); |
|
154 | }); | |
157 | </script> |
|
155 | </script> |
@@ -1,132 +1,132 b'' | |||||
1 | <%inherit file="/base/base.html"/> |
|
1 | <%inherit file="/base/base.html"/> | |
2 |
|
2 | |||
3 | <%def name="title()"> |
|
3 | <%def name="title()"> | |
4 | ${_('%s Pull Requests') % c.repo_name} |
|
4 | ${_('%s Pull Requests') % c.repo_name} | |
5 | %if c.rhodecode_name: |
|
5 | %if c.rhodecode_name: | |
6 | · ${h.branding(c.rhodecode_name)} |
|
6 | · ${h.branding(c.rhodecode_name)} | |
7 | %endif |
|
7 | %endif | |
8 | </%def> |
|
8 | </%def> | |
9 |
|
9 | |||
10 | <%def name="breadcrumbs_links()"> |
|
10 | <%def name="breadcrumbs_links()"> | |
11 |
|
11 | |||
12 | </%def> |
|
12 | </%def> | |
13 |
|
13 | |||
14 | <%def name="menu_bar_nav()"> |
|
14 | <%def name="menu_bar_nav()"> | |
15 | ${self.menu_items(active='repositories')} |
|
15 | ${self.menu_items(active='repositories')} | |
16 | </%def> |
|
16 | </%def> | |
17 |
|
17 | |||
18 |
|
18 | |||
19 | <%def name="menu_bar_subnav()"> |
|
19 | <%def name="menu_bar_subnav()"> | |
20 | ${self.repo_menu(active='showpullrequest')} |
|
20 | ${self.repo_menu(active='showpullrequest')} | |
21 | </%def> |
|
21 | </%def> | |
22 |
|
22 | |||
23 |
|
23 | |||
24 | <%def name="main()"> |
|
24 | <%def name="main()"> | |
25 | <div class="box"> |
|
25 | <div class="box"> | |
26 | <div class="title"> |
|
26 | <div class="title"> | |
27 | ${self.repo_page_title(c.rhodecode_db_repo)} |
|
27 | ${self.repo_page_title(c.rhodecode_db_repo)} | |
28 |
|
28 | |||
29 | <ul class="links"> |
|
29 | <ul class="links"> | |
30 | <li> |
|
30 | <li> | |
31 | %if c.rhodecode_user.username != h.DEFAULT_USER: |
|
31 | %if c.rhodecode_user.username != h.DEFAULT_USER: | |
32 | <span> |
|
32 | <span> | |
33 | <a id="open_new_pull_request" class="btn btn-small btn-success" href="${h.url('pullrequest_home',repo_name=c.repo_name)}"> |
|
33 | <a id="open_new_pull_request" class="btn btn-small btn-success" href="${h.url('pullrequest_home',repo_name=c.repo_name)}"> | |
34 | ${_('Open new Pull Request')} |
|
34 | ${_('Open new Pull Request')} | |
35 | </a> |
|
35 | </a> | |
36 | </span> |
|
36 | </span> | |
37 | %endif |
|
37 | %endif | |
38 | </li> |
|
38 | </li> | |
39 | </ul> |
|
39 | </ul> | |
40 |
|
40 | |||
41 | ${self.breadcrumbs()} |
|
41 | ${self.breadcrumbs()} | |
42 | </div> |
|
42 | </div> | |
43 |
|
43 | |||
44 | <div class="sidebar-col-wrapper"> |
|
44 | <div class="sidebar-col-wrapper"> | |
45 | ##main |
|
45 | ##main | |
46 | <div class="sidebar"> |
|
46 | <div class="sidebar"> | |
47 | <ul class="nav nav-pills nav-stacked"> |
|
47 | <ul class="nav nav-pills nav-stacked"> | |
48 | <li class="${'active' if c.active=='open' else ''}"><a href="${h.url('pullrequest_show_all',repo_name=c.repo_name,source=0)}">${_('Opened')}</a></li> |
|
48 | <li class="${'active' if c.active=='open' else ''}"><a href="${h.url('pullrequest_show_all',repo_name=c.repo_name,source=0)}">${_('Opened')}</a></li> | |
49 | <li class="${'active' if c.active=='my' else ''}"><a href="${h.url('pullrequest_show_all',repo_name=c.repo_name,source=0,my=1)}">${_('Opened by me')}</a></li> |
|
49 | <li class="${'active' if c.active=='my' else ''}"><a href="${h.url('pullrequest_show_all',repo_name=c.repo_name,source=0,my=1)}">${_('Opened by me')}</a></li> | |
50 | <li class="${'active' if c.active=='awaiting' else ''}"><a href="${h.url('pullrequest_show_all',repo_name=c.repo_name,source=0,awaiting_review=1)}">${_('Awaiting review')}</a></li> |
|
50 | <li class="${'active' if c.active=='awaiting' else ''}"><a href="${h.url('pullrequest_show_all',repo_name=c.repo_name,source=0,awaiting_review=1)}">${_('Awaiting review')}</a></li> | |
51 | <li class="${'active' if c.active=='awaiting_my' else ''}"><a href="${h.url('pullrequest_show_all',repo_name=c.repo_name,source=0,awaiting_my_review=1)}">${_('Awaiting my review')}</a></li> |
|
51 | <li class="${'active' if c.active=='awaiting_my' else ''}"><a href="${h.url('pullrequest_show_all',repo_name=c.repo_name,source=0,awaiting_my_review=1)}">${_('Awaiting my review')}</a></li> | |
52 | <li class="${'active' if c.active=='closed' else ''}"><a href="${h.url('pullrequest_show_all',repo_name=c.repo_name,source=0,closed=1)}">${_('Closed')}</a></li> |
|
52 | <li class="${'active' if c.active=='closed' else ''}"><a href="${h.url('pullrequest_show_all',repo_name=c.repo_name,source=0,closed=1)}">${_('Closed')}</a></li> | |
53 | <li class="${'active' if c.active=='source' else ''}"><a href="${h.url('pullrequest_show_all',repo_name=c.repo_name,source=1)}">${_('From this repo')}</a></li> |
|
53 | <li class="${'active' if c.active=='source' else ''}"><a href="${h.url('pullrequest_show_all',repo_name=c.repo_name,source=1)}">${_('From this repo')}</a></li> | |
54 | </ul> |
|
54 | </ul> | |
55 | </div> |
|
55 | </div> | |
56 |
|
56 | |||
57 | <div class="main-content-full-width"> |
|
57 | <div class="main-content-full-width"> | |
58 | <div class="panel panel-default"> |
|
58 | <div class="panel panel-default"> | |
59 | <div class="panel-heading"> |
|
59 | <div class="panel-heading"> | |
60 | <h3 class="panel-title"> |
|
60 | <h3 class="panel-title"> | |
61 | %if c.source: |
|
61 | %if c.source: | |
62 | ${_('Pull Requests from %(repo_name)s repository') % {'repo_name': c.repo_name}} |
|
62 | ${_('Pull Requests from %(repo_name)s repository') % {'repo_name': c.repo_name}} | |
63 | %elif c.closed: |
|
63 | %elif c.closed: | |
64 | ${_('Closed Pull Requests to repository %(repo_name)s') % {'repo_name': c.repo_name}} |
|
64 | ${_('Closed Pull Requests to repository %(repo_name)s') % {'repo_name': c.repo_name}} | |
65 | %elif c.my: |
|
65 | %elif c.my: | |
66 | ${_('Pull Requests to %(repo_name)s repository opened by me') % {'repo_name': c.repo_name}} |
|
66 | ${_('Pull Requests to %(repo_name)s repository opened by me') % {'repo_name': c.repo_name}} | |
67 | %elif c.awaiting_review: |
|
67 | %elif c.awaiting_review: | |
68 | ${_('Pull Requests to %(repo_name)s repository awaiting review') % {'repo_name': c.repo_name}} |
|
68 | ${_('Pull Requests to %(repo_name)s repository awaiting review') % {'repo_name': c.repo_name}} | |
69 | %elif c.awaiting_my_review: |
|
69 | %elif c.awaiting_my_review: | |
70 | ${_('Pull Requests to %(repo_name)s repository awaiting my review') % {'repo_name': c.repo_name}} |
|
70 | ${_('Pull Requests to %(repo_name)s repository awaiting my review') % {'repo_name': c.repo_name}} | |
71 | %else: |
|
71 | %else: | |
72 | ${_('Pull Requests to %(repo_name)s repository') % {'repo_name': c.repo_name}} |
|
72 | ${_('Pull Requests to %(repo_name)s repository') % {'repo_name': c.repo_name}} | |
73 | %endif |
|
73 | %endif | |
74 | </h3> |
|
74 | </h3> | |
75 | </div> |
|
75 | </div> | |
76 | <div class="panel-body"> |
|
76 | <div class="panel-body"> | |
77 | <table id="pull_request_list_table" class="display"></table> |
|
77 | <table id="pull_request_list_table" class="display"></table> | |
78 | </div> |
|
78 | </div> | |
79 | </div> |
|
79 | </div> | |
80 | </div> |
|
80 | </div> | |
81 | </div> |
|
81 | </div> | |
82 | </div> |
|
82 | </div> | |
83 |
|
83 | |||
84 | <script type="text/javascript"> |
|
84 | <script type="text/javascript"> | |
85 | $(document).ready(function() { |
|
85 | $(document).ready(function() { | |
86 | // object list |
|
86 | // object list | |
87 | $('#pull_request_list_table').DataTable({ |
|
87 | $('#pull_request_list_table').DataTable({ | |
88 | data: ${c.data|n}, |
|
88 | data: ${c.data|n}, | |
89 | processing: true, |
|
89 | processing: true, | |
90 | serverSide: true, |
|
90 | serverSide: true, | |
91 | deferLoading: ${c.records_total}, |
|
91 | deferLoading: ${c.records_total}, | |
92 | ajax: "", |
|
92 | ajax: "", | |
93 | dom: 'tp', |
|
93 | dom: 'tp', | |
94 | pageLength: ${c.visual.dashboard_items}, |
|
94 | pageLength: ${c.visual.dashboard_items}, | |
95 | order: [[ 1, "desc" ]], |
|
95 | order: [[ 1, "desc" ]], | |
96 | columns: [ |
|
96 | columns: [ | |
97 | { data: {"_": "status", |
|
97 | { data: {"_": "status", | |
98 | "sort": "status"}, title: "", className: "td-status", orderable: false}, |
|
98 | "sort": "status"}, title: "", className: "td-status", orderable: false}, | |
99 | { data: {"_": "name", |
|
99 | { data: {"_": "name", | |
100 | "sort": "name_raw"}, title: "${_('Name')}", className: "td-componentname", "type": "num" }, |
|
100 | "sort": "name_raw"}, title: "${_('Name')}", className: "td-componentname", "type": "num" }, | |
101 | { data: {"_": "author", |
|
101 | { data: {"_": "author", | |
102 | "sort": "author_raw"}, title: "${_('Author')}", className: "td-user", orderable: false }, |
|
102 | "sort": "author_raw"}, title: "${_('Author')}", className: "td-user", orderable: false }, | |
103 | { data: {"_": "title", |
|
103 | { data: {"_": "title", | |
104 | "sort": "title"}, title: "${_('Title')}", className: "td-description" }, |
|
104 | "sort": "title"}, title: "${_('Title')}", className: "td-description" }, | |
105 | { data: {"_": "comments", |
|
105 | { data: {"_": "comments", | |
106 | "sort": "comments_raw"}, title: "", className: "td-comments", orderable: false}, |
|
106 | "sort": "comments_raw"}, title: "", className: "td-comments", orderable: false}, | |
107 | { data: {"_": "updated_on", |
|
107 | { data: {"_": "updated_on", | |
108 |
"sort": "updated_on_raw"}, title: "${_('Update |
|
108 | "sort": "updated_on_raw"}, title: "${_('Last Update')}", className: "td-time" } | |
109 | ], |
|
109 | ], | |
110 | language: { |
|
110 | language: { | |
111 | paginate: DEFAULT_GRID_PAGINATION, |
|
111 | paginate: DEFAULT_GRID_PAGINATION, | |
112 | emptyTable: _gettext("No pull requests available yet.") |
|
112 | emptyTable: _gettext("No pull requests available yet.") | |
113 | }, |
|
113 | }, | |
114 | "drawCallback": function( settings, json ) { |
|
114 | "drawCallback": function( settings, json ) { | |
115 | timeagoActivate(); |
|
115 | timeagoActivate(); | |
116 | }, |
|
116 | }, | |
117 | "createdRow": function ( row, data, index ) { |
|
117 | "createdRow": function ( row, data, index ) { | |
118 | if (data['closed']) { |
|
118 | if (data['closed']) { | |
119 | $(row).addClass('closed'); |
|
119 | $(row).addClass('closed'); | |
120 | } |
|
120 | } | |
121 | } |
|
121 | } | |
122 | }); |
|
122 | }); | |
123 | }); |
|
123 | }); | |
124 | $('#pull_request_list_table').on('xhr.dt', function(e, settings, json, xhr){ |
|
124 | $('#pull_request_list_table').on('xhr.dt', function(e, settings, json, xhr){ | |
125 | $('#pull_request_list_table').css('opacity', 1); |
|
125 | $('#pull_request_list_table').css('opacity', 1); | |
126 | }); |
|
126 | }); | |
127 |
|
127 | |||
128 | $('#pull_request_list_table').on('preXhr.dt', function(e, settings, data){ |
|
128 | $('#pull_request_list_table').on('preXhr.dt', function(e, settings, data){ | |
129 | $('#pull_request_list_table').css('opacity', 0.3); |
|
129 | $('#pull_request_list_table').css('opacity', 0.3); | |
130 | }); |
|
130 | }); | |
131 | </script> |
|
131 | </script> | |
132 | </%def> |
|
132 | </%def> |
General Comments 0
You need to be logged in to leave comments.
Login now