Commit 22c96de3 authored by Dave Lawrence's avatar Dave Lawrence

Bug 960748 - Queries involving comment tags crash

r/a=glob
parent 87941c04
......@@ -307,7 +307,8 @@ use constant OPERATOR_FIELD_OVERRIDE => {
_non_changed => \&_product_nonchanged,
},
tag => MULTI_SELECT_OVERRIDE,
comment_tag => MULTI_SELECT_OVERRIDE,
# Timetracking Fields
deadline => { _non_changed => \&_deadline },
percentage_complete => {
......@@ -2867,6 +2868,13 @@ sub _multiselect_table {
return "attachments INNER JOIN attach_data "
. " ON attachments.attach_id = attach_data.id"
}
elsif ($field eq 'comment_tag') {
$args->{_extra_where} = " AND longdescs.isprivate = 0"
if !$self->_user->is_insider;
$args->{full_field} = 'longdescs_tags.tag';
return "longdescs INNER JOIN longdescs_tags".
" ON longdescs.comment_id = longdescs_tags.comment_id";
}
my $table = "bug_$field";
$args->{full_field} = "bug_$field.value";
return $table;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment