Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
bugzilla
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
etersoft
bugzilla
Commits
8a6f08e5
Commit
8a6f08e5
authored
Jan 24, 2005
by
travis%sedsystems.ca
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bug 34488: Add a checkbox to add self to CC list
Patch by GavinS <bugzilla@chimpychompy.org> r=vladd, myk a=myk
parent
cd6211de
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
5 deletions
+16
-5
process_bug.cgi
process_bug.cgi
+8
-5
edit.html.tmpl
template/en/default/bug/edit.html.tmpl
+8
-0
No files found.
process_bug.cgi
View file @
8a6f08e5
...
...
@@ -651,7 +651,7 @@ my @groupDel = ();
SendSQL
(
"SELECT groups.id, isactive FROM groups, user_group_map WHERE "
.
"groups.id = user_group_map.group_id AND "
.
"user_group_map.user_id = $
::user
id AND "
.
"user_group_map.user_id = $
who
id AND "
.
"isbless = 0 AND isbuggroup = 1"
);
while
(
my
(
$b
,
$isactive
)
=
FetchSQLData
())
{
# The multiple change page may not show all groups a bug is in
...
...
@@ -831,7 +831,7 @@ my $duplicate = 0;
# What we'll do here is formulate the CC data into two hashes of ID's involved
# in this CC change. Then those hashes can be used later on for the actual change.
my
(
%
cc_add
,
%
cc_remove
);
if
(
defined
$::FORM
{
newcc
}
||
defined
$::FORM
{
removecc
}
||
defined
$::FORM
{
masscc
})
{
if
(
defined
$::FORM
{
newcc
}
||
defined
$::FORM
{
'addselfcc'
}
||
defined
$::FORM
{
removecc
}
||
defined
$::FORM
{
masscc
})
{
# If masscc is defined, then we came from buglist and need to either add or
# remove cc's... otherwise, we came from bugform and may need to do both.
my
(
$cc_add
,
$cc_remove
)
=
""
;
...
...
@@ -857,6 +857,9 @@ if (defined $::FORM{newcc} || defined $::FORM{removecc} || defined $::FORM{massc
$cc_add
{
$pid
}
=
$person
;
}
}
if
(
$::FORM
{
'addselfcc'
})
{
$cc_add
{
$whoid
}
=
$user
->
login
;
}
if
(
$cc_remove
)
{
$cc_remove
=~
s/[\s,]+/ /g
;
# Change all delimiters to a single space
foreach
my
$person
(
split
(
" "
,
$cc_remove
)
)
{
...
...
@@ -1468,7 +1471,7 @@ foreach my $id (@idlist) {
}
my
@ccRemoved
=
();
if
(
defined
$::FORM
{
newcc
}
||
defined
$::FORM
{
removecc
}
||
defined
$::FORM
{
masscc
})
{
if
(
defined
$::FORM
{
newcc
}
||
defined
$::FORM
{
'addselfcc'
}
||
defined
$::FORM
{
removecc
}
||
defined
$::FORM
{
masscc
})
{
# Get the current CC list for this bug
my
%
oncc
;
SendSQL
(
"SELECT who FROM cc WHERE bug_id = $id"
);
...
...
@@ -1595,7 +1598,7 @@ foreach my $id (@idlist) {
"AND newcontrolmap.product_id = $newproduct_id "
.
"LEFT JOIN user_group_map "
.
"ON user_group_map.group_id = groups.id "
.
"AND user_group_map.user_id = $
::user
id "
.
"AND user_group_map.user_id = $
who
id "
.
"AND user_group_map.isbless = 0 "
.
"LEFT JOIN bug_group_map "
.
"ON bug_group_map.group_id = groups.id "
.
...
...
@@ -1829,7 +1832,7 @@ foreach my $id (@idlist) {
# now show the next bug
if
(
$next_bug
)
{
if
(
detaint_natural
(
$next_bug
)
&&
Bugzilla
->
user
->
can_see_bug
(
$next_bug
))
{
my
$bug
=
new
Bugzilla::
Bug
(
$next_bug
,
$
::user
id
);
my
$bug
=
new
Bugzilla::
Bug
(
$next_bug
,
$
who
id
);
ThrowCodeError
(
"bug_error"
,
{
bug
=>
$bug
})
if
$bug
->
error
;
# next.html.tmpl includes edit.html.tmpl, and therefore we
...
...
template/en/default/bug/edit.html.tmpl
View file @
8a6f08e5
...
...
@@ -484,6 +484,14 @@
<a name="add_comment"></a>
<textarea wrap="hard" name="comment" id="comment" rows="10" cols="80"
accesskey="c"></textarea>
[% IF NOT bug.cc || NOT bug.cc.contains(user.login) %]
<br>
<label>
<input type="checkbox" name="addselfcc">
Add [% user.login FILTER html %] to CC list
</label>
[% END %]
<br>
[% IF bug.groups.size > 0 %]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment