From 0e70cd46fe9377b9a267a8e1efbc6f8e7064e95e Mon Sep 17 00:00:00 2001 From: "lpsolit%gmail.com" <> Date: Sun, 20 Aug 2006 06:02:55 +0000 Subject: Bug 344875: Implement a UI to manage custom fields and remove customfield.pl - Patch by Frédéric Buclin r=mkanat a=myk MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../default/admin/custom_fields/create.html.tmpl | 111 +++++++++++++++++++++ .../en/default/admin/custom_fields/edit.html.tmpl | 99 ++++++++++++++++++ .../en/default/admin/custom_fields/list.html.tmpl | 63 ++++++++++++ 3 files changed, 273 insertions(+) create mode 100644 template/en/default/admin/custom_fields/create.html.tmpl create mode 100644 template/en/default/admin/custom_fields/edit.html.tmpl create mode 100644 template/en/default/admin/custom_fields/list.html.tmpl (limited to 'template/en/default/admin') diff --git a/template/en/default/admin/custom_fields/create.html.tmpl b/template/en/default/admin/custom_fields/create.html.tmpl new file mode 100644 index 000000000..b366371bd --- /dev/null +++ b/template/en/default/admin/custom_fields/create.html.tmpl @@ -0,0 +1,111 @@ +[%# 1.0@bugzilla.org %] +[%# The contents of this file are subject to the Mozilla Public + # License Version 1.1 (the "License"); you may not use this file + # except in compliance with the License. You may obtain a copy of + # the License at http://www.mozilla.org/MPL/ + # + # Software distributed under the License is distributed on an "AS + # IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or + # implied. See the License for the specific language governing + # rights and limitations under the License. + # + # The Original Code is the Bugzilla Bug Tracking System. + # + # Contributor(s): Frédéric Buclin + #%] + +[%# INTERFACE: + # none + #%] + +[% PROCESS "global/field-descs.none.tmpl" %] + +[% PROCESS global/header.html.tmpl + title = "Add a new Custom Field" + onload = "document.getElementById('new_bugmail').disabled = true;" %] + + + +

+ Adding custom fields can make the interface of [% terms.Bugzilla %] very + complicated. Many admins who are new to [% terms.Bugzilla %] start off + adding many custom fields, and then their users complain that the interface + is "too complex". Please think carefully before adding any custom fields. + It may be the case that [% terms.Bugzilla %] already does what you need, + and you just haven't enabled the correct feature yet. + +

+
+

+ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + + + + +
+ +
+ [%# Only one field type is valid right now. But let's prepare the UI + # for future new types. %] + +
+ +   
+
+ + +
+ +

+ Back to the list of existing custom fields +

+ +[% PROCESS global/footer.html.tmpl %] diff --git a/template/en/default/admin/custom_fields/edit.html.tmpl b/template/en/default/admin/custom_fields/edit.html.tmpl new file mode 100644 index 000000000..cb7b56a0a --- /dev/null +++ b/template/en/default/admin/custom_fields/edit.html.tmpl @@ -0,0 +1,99 @@ +[%# 1.0@bugzilla.org %] +[%# The contents of this file are subject to the Mozilla Public + # License Version 1.1 (the "License"); you may not use this file + # except in compliance with the License. You may obtain a copy of + # the License at http://www.mozilla.org/MPL/ + # + # Software distributed under the License is distributed on an "AS + # IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or + # implied. See the License for the specific language governing + # rights and limitations under the License. + # + # The Original Code is the Bugzilla Bug Tracking System. + # + # Contributor(s): Frédéric Buclin + #%] + +[%# INTERFACE: + # none + #%] + +[% PROCESS "global/field-descs.none.tmpl" %] + +[% title = BLOCK %] + Edit the Custom Field '[% field.name FILTER html %]' ([% field.description FILTER html %]) +[% END %] + +[% PROCESS global/header.html.tmpl + title = title + onload = "toggleCheckbox(document.getElementById('enter_bug'), 'new_bugmail');" %] + + + +

+ Descriptions are a very short string describing the field and will be used as + the label for this field in the user interface. +

+ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Name:[% field.name FILTER html %] + +
+ +
Type:Free Text
+ +   
+
+ + + +
+ +

+ Back to the list of existing custom fields +

+ +[% PROCESS global/footer.html.tmpl %] diff --git a/template/en/default/admin/custom_fields/list.html.tmpl b/template/en/default/admin/custom_fields/list.html.tmpl new file mode 100644 index 000000000..e02609dd3 --- /dev/null +++ b/template/en/default/admin/custom_fields/list.html.tmpl @@ -0,0 +1,63 @@ +[%# 1.0@bugzilla.org %] +[%# The contents of this file are subject to the Mozilla Public + # License Version 1.1 (the "License"); you may not use this file + # except in compliance with the License. You may obtain a copy of + # the License at http://www.mozilla.org/MPL/ + # + # Software distributed under the License is distributed on an "AS + # IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or + # implied. See the License for the specific language governing + # rights and limitations under the License. + # + # The Original Code is the Bugzilla Bug Tracking System. + # + # Contributor(s): Frédéric Buclin + #%] + +[%# INTERFACE: + # custom_fields: a list of Bugzilla::Field objects, representing custom fields. + #%] + +[% PROCESS "global/field-descs.none.tmpl" %] + +[% PROCESS global/header.html.tmpl title = "Custom Fields" %] + +[% columns = [ + { + name => "name" + heading => "Edit custom field..." + contentlink => "editfields.cgi?action=edit&name=%%name%%" + }, + { + name => "description" + heading => "Description" + }, + { + name => "sortkey" + heading => "Sortkey" + }, + { + name => "enter_bug" + heading => "Editable on Bug Creation" + }, + { + name => "mailhead" + heading => "In Bugmail on Bug Creation" + }, + { + name => "obsolete" + heading => "Is Obsolete" + } + ] +%] + +[% PROCESS admin/table.html.tmpl + columns = columns + data = custom_fields +%] + +

+ Add a new custom field +

+ +[% PROCESS global/footer.html.tmpl %] -- cgit v1.2.3-24-g4f1b