diff options
author | David Lawrence <dkl@mozilla.com> | 2014-08-06 08:47:15 +0200 |
---|---|---|
committer | Byron Jones <glob@mozilla.com> | 2014-08-06 08:47:15 +0200 |
commit | ec10d05697c5e8b89d4a76374563bacaf4238d02 (patch) | |
tree | 63c1d6dbaa8f74f3be164e333327f8a46b71ce96 /extensions/UserStory/template/en/default/hook/bug/create/create-after_custom_fields.html.tmpl | |
parent | b9b47919cc8e335d11d3ea1faa2ddf9346cf3d49 (diff) | |
download | bugzilla-ec10d05697c5e8b89d4a76374563bacaf4238d02.tar.gz bugzilla-ec10d05697c5e8b89d4a76374563bacaf4238d02.tar.xz |
Bug 1047131: enable "user story" field on all products
Diffstat (limited to 'extensions/UserStory/template/en/default/hook/bug/create/create-after_custom_fields.html.tmpl')
-rw-r--r-- | extensions/UserStory/template/en/default/hook/bug/create/create-after_custom_fields.html.tmpl | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/extensions/UserStory/template/en/default/hook/bug/create/create-after_custom_fields.html.tmpl b/extensions/UserStory/template/en/default/hook/bug/create/create-after_custom_fields.html.tmpl index a0c904fe0..04c7f3c04 100644 --- a/extensions/UserStory/template/en/default/hook/bug/create/create-after_custom_fields.html.tmpl +++ b/extensions/UserStory/template/en/default/hook/bug/create/create-after_custom_fields.html.tmpl @@ -6,7 +6,7 @@ # defined by the Mozilla Public License, v. 2.0. #%] -[% RETURN UNLESS default.user_story_group.0 && default.check_can_change_field('cf_user_story', 0, 1) %] +[% RETURN UNLESS default.user_story_visible.0 && default.check_can_change_field('cf_user_story', 0, 1) %] </tbody> <tbody id="cf_user_story_container" class="expert_fields bz_default_hidden"> @@ -33,15 +33,15 @@ %] </div> <script type="text/javascript"> - var user_story_components = []; - [% FOREACH c = default.user_story_group.1 %] - user_story_components.push('[% c FILTER js %]'); + var user_story_exclude_components = []; + [% FOREACH c = default.user_story_visible.1 %] + user_story_exclude_components.push('[% c FILTER js %]'); [% END %] function toggleUserStory() { if (YAHOO.util.Dom.get('user_story').value != '') { hideUserStoryEdit(); } - if (user_story_components.length == 0) { + if (user_story_exclude_components.length == 0) { YAHOO.util.Dom.removeClass('cf_user_story_container', 'bz_default_hidden'); YAHOO.util.Dom.get('user_story').disabled = false; return; @@ -55,15 +55,15 @@ index = 0; } if (index != -1) { - for (var i = 0, l = user_story_components.length; i < l; i++) { - if (user_story_components[i] == components[index]) { - YAHOO.util.Dom.removeClass('cf_user_story_container', 'bz_default_hidden'); - YAHOO.util.Dom.get('user_story').disabled = false; + for (var i = 0, l = user_story_exclude_components.length; i < l; i++) { + if (user_story_exclude_components[i] == components[index]) { + YAHOO.util.Dom.addClass('cf_user_story_container', 'bz_default_hidden'); + YAHOO.util.Dom.get('user_story').disabled = true; return; } else { - YAHOO.util.Dom.addClass('cf_user_story_container', 'bz_default_hidden'); - YAHOO.util.Dom.get('user_story').disabled = true; + YAHOO.util.Dom.removeClass('cf_user_story_container', 'bz_default_hidden'); + YAHOO.util.Dom.get('user_story').disabled = false; } } } |