summaryrefslogtreecommitdiffstats
path: root/extensions/BMO
diff options
context:
space:
mode:
authorAnthony Hughes <anthony.s.hughes@gmail.com>2017-10-25 18:30:40 +0200
committerDylan William Hardison <dylan@hardison.net>2017-10-31 15:06:30 +0100
commit4c9afb9aa9c3fa8cb16824a7a032d560f5780403 (patch)
tree9187f974bc7c27d6eb1cbb6afa88fcab6beff623 /extensions/BMO
parent3465c3905f542d576a61f372a5cb2da3f823d508 (diff)
downloadbugzilla-4c9afb9aa9c3fa8cb16824a7a032d560f5780403.tar.gz
bugzilla-4c9afb9aa9c3fa8cb16824a7a032d560f5780403.tar.xz
Bug 1332016 - Integrate the Socorro Lens into Bug Modal
Diffstat (limited to 'extensions/BMO')
-rw-r--r--extensions/BMO/template/en/default/hook/bug_modal/edit-custom_field-cf_crash_signature.html.tmpl37
1 files changed, 18 insertions, 19 deletions
diff --git a/extensions/BMO/template/en/default/hook/bug_modal/edit-custom_field-cf_crash_signature.html.tmpl b/extensions/BMO/template/en/default/hook/bug_modal/edit-custom_field-cf_crash_signature.html.tmpl
index cdf2c10df..4a5d742f5 100644
--- a/extensions/BMO/template/en/default/hook/bug_modal/edit-custom_field-cf_crash_signature.html.tmpl
+++ b/extensions/BMO/template/en/default/hook/bug_modal/edit-custom_field-cf_crash_signature.html.tmpl
@@ -13,26 +13,25 @@
field_type = field.type
hide_on_view = bug.${field.name} == "" || bug.${field.name} == "---";
%]
- [%
- IF split_cf_crash_signature.size;
- FOREACH sig IN split_cf_crash_signature;
- "<div>";
- IF sig.match('^\[\@\s*') && sig.match('\s*\]$');
- sig = sig.replace('(^\[\@\s*|\s*\]$)', '');
- %]
+ [% IF split_cf_crash_signature.size %]
+ [% FOREACH sig IN split_cf_crash_signature %]
+ <div>
+ [% IF sig.match('^\[\@\s*') && sig.match('\s*\]$') %]
+ [% sig = sig.replace('(^\[\@\s*|\s*\]$)', '') %]
<a href="https://crash-stats.mozilla.com/signature/?signature=[% sig FILTER uri %]" target="_blank">
[@ [% sig FILTER html %] ]
</a>
- [%
- ELSE;
- sig FILTER html;
- END;
- "</div>";
- END;
- ELSIF value;
- %]
- <span class="multiline-value">[% value FILTER html FILTER html_line_break %]</span>
- [%
- END
- %]
+ [% ELSE %]
+ [% sig FILTER html %]
+ [% END %]
+ </div>
+ [% END %]
+ [%# socorro_lens_url() is defined in Bugzilla/Template.pm %]
+ [% SET lens_url = socorro_lens_url(split_cf_crash_signature) %]
+ [% IF lens_url %]
+ <iframe src='[% lens_url FILTER html %]' style='border:0; width:300px; height:200px; max-width:600px; max-height:300px; float:left;' id='chart' scrolling='no'></iframe>
+ [% END %]
+ [% ELSIF value %]
+ <span class="multiline-value">[% value FILTER html FILTER html_line_break %]</span>
+ [% END %]
[% END %]