Bug 830333: Make the comment box hidden if bug_check_can_change_field reports the user is unable to comment on the bug
r=glob, a=LpSolit git-svn-id: svn://10.0.0.236/trunk@264728 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
parent
58393f06dc
commit
ae669f8fb4
@ -1 +1 @@
|
|||||||
8573
|
8574
|
||||||
@ -141,18 +141,20 @@
|
|||||||
|
|
||||||
[% IF mode == "edit" %]
|
[% IF mode == "edit" %]
|
||||||
<span class="bz_comment_actions">
|
<span class="bz_comment_actions">
|
||||||
|
[% IF bug.check_can_change_field('longdesc', 0, 1) %]
|
||||||
[<a class="bz_reply_link" href="#add_comment"
|
[<a class="bz_reply_link" href="#add_comment"
|
||||||
[% IF user.settings.quote_replies.value != 'off' %]
|
[% IF user.settings.quote_replies.value != 'off' %]
|
||||||
onclick="replyToComment('[% count %]', '[% comment.id %]', '[% comment.author.name || comment.author.nick FILTER html FILTER js %]'); return false;"
|
onclick="replyToComment('[% count %]', '[% comment.id %]', '[% comment.author.name || comment.author.nick FILTER html FILTER js %]'); return false;"
|
||||||
[% END %]
|
[% END %]
|
||||||
>reply</a>]
|
>reply</a>]
|
||||||
|
[% END %]
|
||||||
<script type="text/javascript"><!--
|
<script type="text/javascript"><!--
|
||||||
addCollapseLink([% count %], 'Toggle comment display'); // -->
|
addCollapseLink([% count %], 'Toggle comment display'); // -->
|
||||||
</script>
|
</script>
|
||||||
</span>
|
</span>
|
||||||
[% END %]
|
[% END %]
|
||||||
|
|
||||||
[% IF mode == "edit" && user.is_insider %]
|
[% IF mode == "edit" && user.is_insider && bug.check_can_change_field('longdesc', 0, 1) %]
|
||||||
<div class="bz_private_checkbox">
|
<div class="bz_private_checkbox">
|
||||||
<input type="hidden" value="1"
|
<input type="hidden" value="1"
|
||||||
name="defined_isprivate_[% comment.id %]">
|
name="defined_isprivate_[% comment.id %]">
|
||||||
|
|||||||
@ -1052,7 +1052,7 @@
|
|||||||
<label for="comment" accesskey="c"><b>Additional
|
<label for="comment" accesskey="c"><b>Additional
|
||||||
<u>C</u>omments</b></label>:
|
<u>C</u>omments</b></label>:
|
||||||
|
|
||||||
[% IF user.is_insider %]
|
[% IF user.is_insider && bug.check_can_change_field('longdesc', 0, 1) %]
|
||||||
<input type="checkbox" name="comment_is_private" value="1"
|
<input type="checkbox" name="comment_is_private" value="1"
|
||||||
id="newcommentprivacy"
|
id="newcommentprivacy"
|
||||||
onClick="updateCommentTagControl(this, 'comment')">
|
onClick="updateCommentTagControl(this, 'comment')">
|
||||||
@ -1064,6 +1064,7 @@
|
|||||||
|
|
||||||
<!-- This table keeps the submit button aligned with the box. -->
|
<!-- This table keeps the submit button aligned with the box. -->
|
||||||
<table><tr><td>
|
<table><tr><td>
|
||||||
|
[% IF bug.check_can_change_field('longdesc', 0, 1) %]
|
||||||
[% INCLUDE global/textarea.html.tmpl
|
[% INCLUDE global/textarea.html.tmpl
|
||||||
name = 'comment'
|
name = 'comment'
|
||||||
id = 'comment'
|
id = 'comment'
|
||||||
@ -1072,6 +1073,9 @@
|
|||||||
cols = constants.COMMENT_COLS
|
cols = constants.COMMENT_COLS
|
||||||
%]
|
%]
|
||||||
[% Hook.process("after_comment_textarea", 'bug/edit.html.tmpl') %]
|
[% Hook.process("after_comment_textarea", 'bug/edit.html.tmpl') %]
|
||||||
|
[% ELSE %]
|
||||||
|
You are not allowed to make an additional comment on this [% terms.bug %].
|
||||||
|
[% END %]
|
||||||
<br>
|
<br>
|
||||||
[% PROCESS commit_button id=""%]
|
[% PROCESS commit_button id=""%]
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user