##// END OF EJS Templates
pull requests: add show/hide comment functionality #4106
lisaq -
r517:bf98000c default
parent child Browse files
Show More
@@ -1,568 +1,589 b''
1 1 <%inherit file="/base/base.html"/>
2 2
3 3 <%def name="title()">
4 4 ${_('%s Pull Request #%s') % (c.repo_name, c.pull_request.pull_request_id)}
5 5 %if c.rhodecode_name:
6 6 &middot; ${h.branding(c.rhodecode_name)}
7 7 %endif
8 8 </%def>
9 9
10 10 <%def name="breadcrumbs_links()">
11 11 <span id="pr-title">
12 12 ${c.pull_request.title}
13 13 %if c.pull_request.is_closed():
14 14 (${_('Closed')})
15 15 %endif
16 16 </span>
17 17 <div id="pr-title-edit" class="input" style="display: none;">
18 18 ${h.text('pullrequest_title', id_="pr-title-input", class_="large", value=c.pull_request.title)}
19 19 </div>
20 20 </%def>
21 21
22 22 <%def name="menu_bar_nav()">
23 23 ${self.menu_items(active='repositories')}
24 24 </%def>
25 25
26 26 <%def name="menu_bar_subnav()">
27 27 ${self.repo_menu(active='showpullrequest')}
28 28 </%def>
29 29
30 30 <%def name="main()">
31 31 <script type="text/javascript">
32 32 // TODO: marcink switch this to pyroutes
33 33 AJAX_COMMENT_DELETE_URL = "${url('pullrequest_comment_delete',repo_name=c.repo_name,comment_id='__COMMENT_ID__')}";
34 34 templateContext.pull_request_data.pull_request_id = ${c.pull_request.pull_request_id};
35 35 </script>
36 36 <div class="box">
37 37 <div class="title">
38 38 ${self.repo_page_title(c.rhodecode_db_repo)}
39 39 </div>
40 40
41 41 ${self.breadcrumbs()}
42 42
43 43
44 44 <div class="box pr-summary">
45 45 <div class="summary-details block-left">
46 46 <%summary = lambda n:{False:'summary-short'}.get(n)%>
47 47 <div class="pr-details-title">
48 48 ${_('Pull request #%s') % c.pull_request.pull_request_id} ${_('From')} ${h.format_date(c.pull_request.created_on)}
49 49 %if c.allowed_to_update:
50 50 <span id="open_edit_pullrequest" class="block-right action_button">${_('Edit')}</span>
51 51 <span id="close_edit_pullrequest" class="block-right action_button" style="display: none;">${_('Close')}</span>
52 52 %endif
53 53 </div>
54 54
55 55 <div id="summary" class="fields pr-details-content">
56 56 <div class="field">
57 57 <div class="label-summary">
58 58 <label>${_('Origin')}:</label>
59 59 </div>
60 60 <div class="input">
61 61 <div class="pr-origininfo">
62 62 ## branch link is only valid if it is a branch
63 63 <span class="tag">
64 64 %if c.pull_request.source_ref_parts.type == 'branch':
65 65 <a href="${h.url('changelog_home', repo_name=c.pull_request.source_repo.repo_name, branch=c.pull_request.source_ref_parts.name)}">${c.pull_request.source_ref_parts.type}: ${c.pull_request.source_ref_parts.name}</a>
66 66 %else:
67 67 ${c.pull_request.source_ref_parts.type}: ${c.pull_request.source_ref_parts.name}
68 68 %endif
69 69 </span>
70 70 <span class="clone-url">
71 71 <a href="${h.url('summary_home', repo_name=c.pull_request.source_repo.repo_name)}">${c.pull_request.source_repo.clone_url()}</a>
72 72 </span>
73 73 </div>
74 74 <div class="pr-pullinfo">
75 75 %if h.is_hg(c.pull_request.source_repo):
76 76 <input type="text" value="hg pull -r ${h.short_id(c.source_ref)} ${c.pull_request.source_repo.clone_url()}" readonly="readonly">
77 77 %elif h.is_git(c.pull_request.source_repo):
78 78 <input type="text" value="git pull ${c.pull_request.source_repo.clone_url()} ${c.pull_request.source_ref_parts.name}" readonly="readonly">
79 79 %endif
80 80 </div>
81 81 </div>
82 82 </div>
83 83 <div class="field">
84 84 <div class="label-summary">
85 85 <label>${_('Target')}:</label>
86 86 </div>
87 87 <div class="input">
88 88 <div class="pr-targetinfo">
89 89 ## branch link is only valid if it is a branch
90 90 <span class="tag">
91 91 %if c.pull_request.target_ref_parts.type == 'branch':
92 92 <a href="${h.url('changelog_home', repo_name=c.pull_request.target_repo.repo_name, branch=c.pull_request.target_ref_parts.name)}">${c.pull_request.target_ref_parts.type}: ${c.pull_request.target_ref_parts.name}</a>
93 93 %else:
94 94 ${c.pull_request.target_ref_parts.type}: ${c.pull_request.target_ref_parts.name}
95 95 %endif
96 96 </span>
97 97 <span class="clone-url">
98 98 <a href="${h.url('summary_home', repo_name=c.pull_request.target_repo.repo_name)}">${c.pull_request.target_repo.clone_url()}</a>
99 99 </span>
100 100 </div>
101 101 </div>
102 102 </div>
103 103 <div class="field">
104 104 <div class="label-summary">
105 105 <label>${_('Review')}:</label>
106 106 </div>
107 107 <div class="input">
108 108 %if c.pull_request_review_status:
109 109 <div class="${'flag_status %s' % c.pull_request_review_status} tooltip pull-left"></div>
110 110 <span class="changeset-status-lbl tooltip">
111 111 %if c.pull_request.is_closed():
112 112 ${_('Closed')},
113 113 %endif
114 114 ${h.commit_status_lbl(c.pull_request_review_status)}
115 115 </span>
116 116 - ${ungettext('calculated based on %s reviewer vote', 'calculated based on %s reviewers votes', len(c.pull_request_reviewers)) % len(c.pull_request_reviewers)}
117 117 %endif
118 118 </div>
119 119 </div>
120 120 <div class="field">
121 121 <div class="pr-description-label label-summary">
122 122 <label>${_('Description')}:</label>
123 123 </div>
124 124 <div id="pr-desc" class="input">
125 125 <div class="pr-description">${h.urlify_commit_message(c.pull_request.description, c.repo_name)}</div>
126 126 </div>
127 127 <div id="pr-desc-edit" class="input textarea editor" style="display: none;">
128 128 <textarea id="pr-description-input" size="30">${c.pull_request.description}</textarea>
129 129 </div>
130 130 </div>
131 131 <div class="field">
132 132 <div class="label-summary">
133 133 <label>${_('Comments')}:</label>
134 134 </div>
135 135 <div class="input">
136 136 <div>
137 137 <div class="comments-number">
138 138 %if c.comments:
139 139 <a href="#comments">${ungettext("%d Pull request comment", "%d Pull request comments", len(c.comments)) % len(c.comments)}</a>,
140 140 %else:
141 141 ${ungettext("%d Pull request comment", "%d Pull request comments", len(c.comments)) % len(c.comments)}
142 142 %endif
143 143 %if c.inline_cnt:
144 144 ## this is replaced with a proper link to first comment via JS linkifyComments() func
145 145 <a href="#inline-comments" id="inline-comments-counter">${ungettext("%d Inline Comment", "%d Inline Comments", c.inline_cnt) % c.inline_cnt}</a>
146 146 %else:
147 147 ${ungettext("%d Inline Comment", "%d Inline Comments", c.inline_cnt) % c.inline_cnt}
148 148 %endif
149 149
150 150 % if c.outdated_cnt:
151 151 ,${ungettext("%d Outdated Comment", "%d Outdated Comments", c.outdated_cnt) % c.outdated_cnt} <span id="show-outdated-comments" class="btn btn-link">${_('(Show)')}</span>
152 152 % endif
153 153 </div>
154 154 </div>
155 155 </div>
156 156 </div>
157 157 <div id="pr-save" class="field" style="display: none;">
158 158 <div class="label-summary"></div>
159 159 <div class="input">
160 160 <span id="edit_pull_request" class="btn btn-small">${_('Save Changes')}</span>
161 161 </div>
162 162 </div>
163 163 </div>
164 164 </div>
165 165 <div>
166 166 ## AUTHOR
167 167 <div class="reviewers-title block-right">
168 168 <div class="pr-details-title">
169 169 ${_('Author')}
170 170 </div>
171 171 </div>
172 172 <div class="block-right pr-details-content reviewers">
173 173 <ul class="group_members">
174 174 <li>
175 175 ${self.gravatar_with_user(c.pull_request.author.email, 16)}
176 176 </li>
177 177 </ul>
178 178 </div>
179 179 ## REVIEWERS
180 180 <div class="reviewers-title block-right">
181 181 <div class="pr-details-title">
182 182 ${_('Pull request reviewers')}
183 183 %if c.allowed_to_update:
184 184 <span id="open_edit_reviewers" class="block-right action_button">${_('Edit')}</span>
185 185 <span id="close_edit_reviewers" class="block-right action_button" style="display: none;">${_('Close')}</span>
186 186 %endif
187 187 </div>
188 188 </div>
189 189 <div id="reviewers" class="block-right pr-details-content reviewers">
190 190 ## members goes here !
191 191 <ul id="review_members" class="group_members">
192 192 %for member,status in c.pull_request_reviewers:
193 193 <li id="reviewer_${member.user_id}">
194 194 <div class="reviewers_member">
195 195 <div class="reviewer_status tooltip" title="${h.tooltip(h.commit_status_lbl(status[0][1].status if status else 'not_reviewed'))}">
196 196 <div class="${'flag_status %s' % (status[0][1].status if status else 'not_reviewed')} pull-left reviewer_member_status"></div>
197 197 </div>
198 198 <div id="reviewer_${member.user_id}_name" class="reviewer_name">
199 199 ${self.gravatar_with_user(member.email, 16)} <div class="reviewer">(${_('owner') if c.pull_request.user_id == member.user_id else _('reviewer')})</div>
200 200 </div>
201 201 <input id="reviewer_${member.user_id}_input" type="hidden" value="${member.user_id}" name="review_members" />
202 202 %if c.allowed_to_update:
203 203 <div class="reviewer_member_remove action_button" onclick="removeReviewMember(${member.user_id}, true)" style="visibility: hidden;">
204 204 <i class="icon-remove-sign" ></i>
205 205 </div>
206 206 %endif
207 207 </div>
208 208 </li>
209 209 %endfor
210 210 </ul>
211 211 %if not c.pull_request.is_closed():
212 212 <div id="add_reviewer_input" class='ac' style="display: none;">
213 213 %if c.allowed_to_update:
214 214 <div class="reviewer_ac">
215 215 ${h.text('user', class_='ac-input', placeholder=_('Add reviewer'))}
216 216 <div id="reviewers_container"></div>
217 217 </div>
218 218 <div>
219 219 <span id="update_pull_request" class="btn btn-small">${_('Save Changes')}</span>
220 220 </div>
221 221 %endif
222 222 </div>
223 223 %endif
224 224 </div>
225 225 </div>
226 226 </div>
227 227 <div class="box">
228 228 ##DIFF
229 229 <div class="table" >
230 230 <div id="changeset_compare_view_content">
231 231 ##CS
232 232 % if c.missing_requirements:
233 233 <div class="box">
234 234 <div class="alert alert-warning">
235 235 <div>
236 236 <strong>${_('Missing requirements:')}</strong>
237 237 ${_('These commits cannot be displayed, because this repository uses the Mercurial largefiles extension, which was not enabled.')}
238 238 </div>
239 239 </div>
240 240 </div>
241 241 % elif c.missing_commits:
242 242 <div class="box">
243 243 <div class="alert alert-warning">
244 244 <div>
245 245 <strong>${_('Missing commits')}:</strong>
246 246 ${_('This pull request cannot be displayed, because one or more commits no longer exist in the source repository.')}
247 247 ${_('Please update this pull request, push the commits back into the source repository, or consider closing this pull request.')}
248 248 </div>
249 249 </div>
250 250 </div>
251 251 % endif
252 252 <div class="compare_view_commits_title">
253 253 % if c.allowed_to_update and not c.pull_request.is_closed():
254 254 <button id="update_commits" class="btn btn-small">${_('Update commits')}</button>
255 255 % endif
256 256 % if len(c.commit_ranges):
257 257 <h2>${ungettext('Compare View: %s commit','Compare View: %s commits', len(c.commit_ranges)) % len(c.commit_ranges)}</h2>
258 258 % endif
259 259 </div>
260 260 % if not c.missing_commits:
261 261 <%include file="/compare/compare_commits.html" />
262 262 ## FILES
263 263 <div class="cs_files_title">
264 264 <span class="cs_files_expand">
265 265 <span id="expand_all_files">${_('Expand All')}</span> | <span id="collapse_all_files">${_('Collapse All')}</span>
266 266 </span>
267 267 <h2>
268 268 ${diff_block.diff_summary_text(len(c.files), c.lines_added, c.lines_deleted, c.limited_diff)}
269 269 </h2>
270 270 </div>
271 271 % endif
272 272 <div class="cs_files">
273 273 %if not c.files and not c.missing_commits:
274 274 <span class="empty_data">${_('No files')}</span>
275 275 %endif
276 276 <table class="compare_view_files">
277 277 <%namespace name="diff_block" file="/changeset/diff_block.html"/>
278 278 %for FID, change, path, stats in c.files:
279 279 <tr class="cs_${change} collapse_file" fid="${FID}">
280 280 <td class="cs_icon_td">
281 281 <span class="collapse_file_icon" fid="${FID}"></span>
282 282 </td>
283 283 <td class="cs_icon_td">
284 284 <div class="flag_status not_reviewed hidden"></div>
285 285 </td>
286 286 <td class="cs_${change}" id="a_${FID}">
287 287 <div class="node">
288 288 <a href="#a_${FID}">
289 289 <i class="icon-file-${change.lower()}"></i>
290 290 ${h.safe_unicode(path)}
291 291 </a>
292 292 </div>
293 293 </td>
294 294 <td>
295 295 <div class="changes pull-right">${h.fancy_file_stats(stats)}</div>
296 296 <div class="comment-bubble pull-right" data-path="${path}">
297 297 <i class="icon-comment"></i>
298 298 </div>
299 299 </td>
300 300 </tr>
301 301 <tr fid="${FID}" id="diff_${FID}" class="diff_links">
302 302 <td></td>
303 303 <td></td>
304 304 <td class="cs_${change}">
305 305 %if c.target_repo.repo_name == c.repo_name:
306 306 ${diff_block.diff_menu(c.repo_name, h.safe_unicode(path), c.target_ref, c.source_ref, change)}
307 307 %else:
308 308 ## this is slightly different case later, since the other repo can have this
309 309 ## file in other state than the origin repo
310 310 ${diff_block.diff_menu(c.target_repo.repo_name, h.safe_unicode(path), c.target_ref, c.source_ref, change)}
311 311 %endif
312 312 </td>
313 313 <td class="td-actions rc-form">
314 <div data-comment-id="${FID}" class="btn-link show-inline-comments comments-visible">
315 <span class="comments-show">${_('Show comments')}</span>
316 <span class="comments-hide">${_('Hide comments')}</span>
317 </div>
314 318 </td>
315 319 </tr>
316 320 <tr id="tr_${FID}">
317 321 <td></td>
318 322 <td></td>
319 323 <td class="injected_diff" colspan="2">
320 324 ${diff_block.diff_block_simple([c.changes[FID]])}
321 325 </td>
322 326 </tr>
323 327
324 328 ## Loop through inline comments
325 329 % if c.outdated_comments.get(path,False):
326 330 <tr class="outdated">
327 331 <td></td>
328 332 <td></td>
329 333 <td colspan="2">
330 334 <p>${_('Outdated Inline Comments')}:</p>
331 335 </td>
332 336 </tr>
333 337 <tr class="outdated">
334 338 <td></td>
335 339 <td></td>
336 340 <td colspan="2" class="outdated_comment_block">
337 341 % for line, comments in c.outdated_comments[path].iteritems():
338 342 <div class="inline-comment-placeholder" path="${path}" target_id="${h.safeid(h.safe_unicode(path))}">
339 343 % for co in comments:
340 344 ${comment.comment_block_outdated(co)}
341 345 % endfor
342 346 </div>
343 347 % endfor
344 348 </td>
345 349 </tr>
346 350 % endif
347 351 %endfor
348 352 ## Loop through inline comments for deleted files
349 353 %for path in c.deleted_files:
350 354 <tr class="outdated deleted">
351 355 <td></td>
352 356 <td></td>
353 357 <td>${path}</td>
354 358 </tr>
355 359 <tr class="outdated deleted">
356 360 <td></td>
357 361 <td></td>
358 362 <td>(${_('Removed')})</td>
359 363 </tr>
360 364 % if path in c.outdated_comments:
361 365 <tr class="outdated deleted">
362 366 <td></td>
363 367 <td></td>
364 368 <td colspan="2">
365 369 <p>${_('Outdated Inline Comments')}:</p>
366 370 </td>
367 371 </tr>
368 372 <tr class="outdated">
369 373 <td></td>
370 374 <td></td>
371 375 <td colspan="2" class="outdated_comment_block">
372 376 % for line, comments in c.outdated_comments[path].iteritems():
373 377 <div class="inline-comment-placeholder" path="${path}" target_id="${h.safeid(h.safe_unicode(path))}">
374 378 % for co in comments:
375 379 ${comment.comment_block_outdated(co)}
376 380 % endfor
377 381 </div>
378 382 % endfor
379 383 </td>
380 384 </tr>
381 385 % endif
382 386 %endfor
383 387 </table>
384 388 </div>
385 389 % if c.limited_diff:
386 390 <h5>${_('Commit was too big and was cut off...')} <a href="${h.url.current(fulldiff=1, **request.GET.mixed())}" onclick="return confirm('${_("Showing a huge diff might take some time and resources")}')">${_('Show full diff')}</a></h5>
387 391 % endif
388 392 </div>
389 393 </div>
390 394
391 395 % if c.limited_diff:
392 396 <p>${_('Commit was too big and was cut off...')} <a href="${h.url.current(fulldiff=1, **request.GET.mixed())}" onclick="return confirm('${_("Showing a huge diff might take some time and resources")}')">${_('Show full diff')}</a></p>
393 397 % endif
394 398
395 399 ## template for inline comment form
396 400 <%namespace name="comment" file="/changeset/changeset_file_comment.html"/>
397 401 ${comment.comment_inline_form()}
398 402
399 403 ## render comments and inlines
400 404 ${comment.generate_comments(include_pull_request=True, is_pull_request=True)}
401 405
402 406 % if not c.pull_request.is_closed():
403 407 ## main comment form and it status
404 408 ${comment.comments(h.url('pullrequest_comment', repo_name=c.repo_name,
405 409 pull_request_id=c.pull_request.pull_request_id),
406 410 c.pull_request_review_status,
407 411 is_pull_request=True, change_status=c.allowed_to_change_status)}
408 412 %endif
409 413
410 414 <script type="text/javascript">
411 415 if (location.href.indexOf('#') != -1) {
412 416 var id = '#'+location.href.substring(location.href.indexOf('#') + 1).split('#');
413 417 var line = $('html').find(id);
414 418 offsetScroll(line, 70);
415 419 }
416 420 $(function(){
417 421 ReviewerAutoComplete('user');
418 422 // custom code mirror
419 423 var codeMirrorInstance = initPullRequestsCodeMirror('#pr-description-input');
420 424
421 425 var PRDetails = {
422 426 editButton: $('#open_edit_pullrequest'),
423 427 closeButton: $('#close_edit_pullrequest'),
424 428 viewFields: $('#pr-desc, #pr-title'),
425 429 editFields: $('#pr-desc-edit, #pr-title-edit, #pr-save'),
426 430
427 431 init: function() {
428 432 var that = this;
429 433 this.editButton.on('click', function(e) { that.edit(); });
430 434 this.closeButton.on('click', function(e) { that.view(); });
431 435 },
432 436
433 437 edit: function(event) {
434 438 this.viewFields.hide();
435 439 this.editButton.hide();
436 440 this.editFields.show();
437 441 codeMirrorInstance.refresh();
438 442 },
439 443
440 444 view: function(event) {
441 445 this.editFields.hide();
442 446 this.closeButton.hide();
443 447 this.viewFields.show();
444 448 }
445 449 };
446 450
447 451 var ReviewersPanel = {
448 452 editButton: $('#open_edit_reviewers'),
449 453 closeButton: $('#close_edit_reviewers'),
450 454 addButton: $('#add_reviewer_input'),
451 455 removeButtons: $('.reviewer_member_remove'),
452 456
453 457 init: function() {
454 458 var that = this;
455 459 this.editButton.on('click', function(e) { that.edit(); });
456 460 this.closeButton.on('click', function(e) { that.close(); });
457 461 },
458 462
459 463 edit: function(event) {
460 464 this.editButton.hide();
461 465 this.closeButton.show();
462 466 this.addButton.show();
463 467 this.removeButtons.css('visibility', 'visible');
464 468 },
465 469
466 470 close: function(event) {
467 471 this.editButton.show();
468 472 this.closeButton.hide();
469 473 this.addButton.hide();
470 474 this.removeButtons.css('visibility', 'hidden');
471 475 }
472 476 };
473 477
474 478 PRDetails.init();
475 479 ReviewersPanel.init();
476 480
477 481 $('#show-outdated-comments').on('click', function(e){
478 482 var button = $(this);
479 483 var outdated = $('.outdated');
480 484 if (button.html() === "(Show)") {
481 485 button.html("(Hide)");
482 486 outdated.show();
483 487 } else {
484 488 button.html("(Show)");
485 489 outdated.hide();
486 490 }
487 491 });
488 492
489 493 $('.show-inline-comments').on('change', function(e){
490 494 var show = 'none';
491 495 var target = e.currentTarget;
492 496 if(target.checked){
493 497 show = ''
494 498 }
495 499 var boxid = $(target).attr('id_for');
496 500 var comments = $('#{0} .inline-comments'.format(boxid));
497 501 var fn_display = function(idx){
498 502 $(this).css('display', show);
499 503 };
500 504 $(comments).each(fn_display);
501 505 var btns = $('#{0} .inline-comments-button'.format(boxid));
502 506 $(btns).each(fn_display);
503 507 });
504 508
505 509 // inject comments into their proper positions
506 510 var file_comments = $('.inline-comment-placeholder');
507 511 %if c.pull_request.is_closed():
508 512 renderInlineComments(file_comments, false);
509 513 %else:
510 514 renderInlineComments(file_comments, true);
511 515 %endif
512 516 var commentTotals = {};
513 517 $.each(file_comments, function(i, comment) {
514 518 var path = $(comment).attr('path');
515 519 var comms = $(comment).children().length;
516 520 if (path in commentTotals) {
517 521 commentTotals[path] += comms;
518 522 } else {
519 523 commentTotals[path] = comms;
520 524 }
521 525 });
522 526 $.each(commentTotals, function(path, total) {
523 527 var elem = $('.comment-bubble[data-path="'+ path +'"]');
524 528 elem.css('visibility', 'visible');
525 529 elem.html(elem.html() + ' ' + total );
526 530 });
527 531
528 532 $('#merge_pull_request_form').submit(function() {
529 533 if (!$('#merge_pull_request').attr('disabled')) {
530 534 $('#merge_pull_request').attr('disabled', 'disabled');
531 535 }
532 536 return true;
533 537 });
534 538
535 539 $('#edit_pull_request').on('click', function(e){
536 540 var title = $('#pr-title-input').val();
537 541 var description = codeMirrorInstance.getValue();
538 542 editPullRequest(
539 543 "${c.repo_name}", "${c.pull_request.pull_request_id}",
540 544 title, description);
541 545 });
542 546
543 547 $('#update_pull_request').on('click', function(e){
544 548 updateReviewers(undefined, "${c.repo_name}", "${c.pull_request.pull_request_id}");
545 549 });
546 550
547 551 $('#update_commits').on('click', function(e){
548 552 var isDisabled = !$(e.currentTarget).attr('disabled');
549 553 $(e.currentTarget).text(_gettext('Updating...'));
550 554 $(e.currentTarget).attr('disabled', 'disabled');
551 555 if(isDisabled){
552 556 updateCommits("${c.repo_name}", "${c.pull_request.pull_request_id}");
553 557 }
554 558
555 559 });
556 560 // fixing issue with caches on firefox
557 561 $('#update_commits').removeAttr("disabled");
558 562
559 563 $('#close_pull_request').on('click', function(e){
560 564 closePullRequest("${c.repo_name}", "${c.pull_request.pull_request_id}");
561 565 });
566
567 $('.show-inline-comments').on('click', function(e){
568 var boxid = $(this).attr('data-comment-id');
569 var button = $(this);
570
571 if(button.hasClass("comments-visible")) {
572 $('#{0} .inline-comments'.format(boxid)).each(function(index){
573 $(this).hide();
574 })
575 button.removeClass("comments-visible");
576 } else {
577 $('#{0} .inline-comments'.format(boxid)).each(function(index){
578 $(this).show();
579 })
580 button.addClass("comments-visible");
581 }
582 });
562 583 })
563 584 </script>
564 585
565 586 </div>
566 587 </div>
567 588
568 589 </%def>
General Comments 0
You need to be logged in to leave comments. Login now