[%# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
# This Source Code Form is "Incompatible With Secondary Licenses", as
# defined by the Mozilla Public License, v. 2.0.
#%]
[%#
# types: array of flag_type objects
# no_label: if set to a true value, flag name and status will not be outputted (default: false)
# view_only: if true, don't output edit ui (default: false)
#%]
[% IF view_only %]
[% FOREACH type IN types %]
[% FOREACH flag IN type.flags %]
[%
FOREACH type IN types;
FOREACH flag IN type.flags;
IF flag.requestee && flag.requestee.id == user.id;
INCLUDE edit_flag t=type f=flag;
ELSE;
%]
[% INCLUDE view_flag t=type f=flag %]
[% INCLUDE edit_flag t=type f=flag %]
[%
END;
END;
END;
%]
[%
FOREACH type IN types;
NEXT IF !type.is_active || type.flags.size;
INCLUDE edit_flag t=type;
END;
FOREACH type IN types;
NEXT IF !type.is_active || !type.is_multiplicable;
INCLUDE edit_flag t=type;
END;
%]
[% BLOCK view_flag %]
[% INCLUDE bug_modal/user.html.tmpl u=f.setter nick_only=1 %]