From 2c925582f8bd4f6e062dbddabbd424ddfd69debb Mon Sep 17 00:00:00 2001 From: Byron Jones Date: Thu, 31 Oct 2013 13:44:10 +0800 Subject: Bug 920026: show reminder of pending review, feedback, and needinfo requests in the header --- .../default/hook/global/header-message.html.tmpl | 23 ++++++++++++++++++++++ .../en/default/hook/global/header-start.html.tmpl | 7 +++++++ .../user-error-auth_failure_object.html.tmpl | 11 +++++++++++ 3 files changed, 41 insertions(+) create mode 100644 extensions/Review/template/en/default/hook/global/header-message.html.tmpl create mode 100644 extensions/Review/template/en/default/hook/global/user-error-auth_failure_object.html.tmpl (limited to 'extensions/Review/template/en/default/hook') diff --git a/extensions/Review/template/en/default/hook/global/header-message.html.tmpl b/extensions/Review/template/en/default/hook/global/header-message.html.tmpl new file mode 100644 index 000000000..33e899492 --- /dev/null +++ b/extensions/Review/template/en/default/hook/global/header-message.html.tmpl @@ -0,0 +1,23 @@ +[%# 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. + #%] + +[% RETURN UNLESS + user.review_request_count + || user.feedback_request_count + || user.needinfo_request_count +%] + + + + [%- user.review_request_count + user.feedback_request_count + user.needinfo_request_count ~%] + + diff --git a/extensions/Review/template/en/default/hook/global/header-start.html.tmpl b/extensions/Review/template/en/default/hook/global/header-start.html.tmpl index e086e9b55..585041e99 100644 --- a/extensions/Review/template/en/default/hook/global/header-start.html.tmpl +++ b/extensions/Review/template/en/default/hook/global/header-start.html.tmpl @@ -6,6 +6,13 @@ # defined by the Mozilla Public License, v. 2.0. #%] +[% IF user.review_request_count + || user.feedback_request_count + || user.needinfo_request_count +%] + [% style_urls.push('extensions/Review/web/styles/badge.css') %] +[% END %] + [% RETURN UNLESS template.name == 'attachment/edit.html.tmpl' || template.name == 'attachment/create.html.tmpl' || template.name == 'attachment/diff-header.html.tmpl' diff --git a/extensions/Review/template/en/default/hook/global/user-error-auth_failure_object.html.tmpl b/extensions/Review/template/en/default/hook/global/user-error-auth_failure_object.html.tmpl new file mode 100644 index 000000000..156f0aa93 --- /dev/null +++ b/extensions/Review/template/en/default/hook/global/user-error-auth_failure_object.html.tmpl @@ -0,0 +1,11 @@ +[%# 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. + #%] + +[% IF object == 'review_requests_rebuild' %] + rebuild review request counters +[% END %] -- cgit v1.2.3-24-g4f1b