?? create.html.tmpl
字號:
$output .= $stash->get(['initial_cc_list', 0, 'join', [ ', ' ]]); &$_tt_filter($output); }; $output .= "\";\n"; #line 73 "template\en\default\bug\create\create.html.tmpl" $stash->set('count', $stash->get('count') + 1); ; ($_tt_value, $_tt_error) = $_tt_list->get_next(); } }; $stash->set('loop', $_tt_oldloop); die $@ if $@; $_tt_error = 0 if $_tt_error && $_tt_error eq Template::Constants::STATUS_DONE; die $_tt_error if $_tt_error; }; $output .= "\n\nfunction set_assign_to() {\n // Based on the selected component, fill the \"Assign To:\" field\n // with the default component owner, and the \"QA Contact:\" field\n // with the default QA Contact. It also selectively enables flags.\n var form = document.Create;\n var assigned_to = form.assigned_to.value;\n"; #line 85 "template\en\default\bug\create\create.html.tmpl" if ($stash->get(['Param', [ 'useqacontact' ]])) { $output .= "\n var qa_contact = form.qa_contact.value;"; } $output .= "\n\n var index = -1;\n if (form.component.type == 'select-one') {\n index = form.component.selectedIndex;\n } else if (form.component.type == 'hidden') {\n // Assume there is only one component in the list\n index = 0;\n }\n if (index != -1) {\n var owner = initialowners[index];\n var component = components[index];\n if (assigned_to == last_initialowner\n || assigned_to == owner\n || assigned_to == '') {\n form.assigned_to.value = owner;\n last_initialowner = owner;\n }\n\n document.getElementById('initial_cc').innerHTML = initialccs[index];\n"; #line 114 "template\en\default\bug\create\create.html.tmpl" if ($stash->get(['Param', [ 'useqacontact' ]])) { $output .= "\n var contact = initialqacontacts[index];\n if (qa_contact == last_initialqacontact\n || qa_contact == contact\n || qa_contact == '') {\n form.qa_contact.value = contact;\n last_initialqacontact = contact;\n }"; } $output .= "\n\n // First, we disable all flags. Then we re-enable those\n // which are available for the selected component.\n var inputElements = document.getElementsByTagName(\"select\");\n var inputElement, flagField;\n for ( var i=0 ; i<inputElements.length ; i++ ) {\n inputElement = inputElements.item(i);\n if (inputElement.name.search(/^flag_type-(\\d+)\$/) != -1) {\n var id = inputElement.name.replace(/^flag_type-(\\d+)\$/, \"\$1\");\n inputElement.disabled = true;\n // Also disable the requestee field, if it exists.\n inputElement = document.getElementById(\"requestee_type-\" + id);\n if (inputElement) inputElement.disabled = true;\n }\n }\n // Now enable flags available for the selected component.\n for (var i = 0; i < flags[index].length; i++) {\n flagField = document.getElementById(\"flag_type-\" + flags[index][i]);\n // Do not enable flags the user cannot set nor request.\n if (flagField && flagField.options.length > 1) {\n flagField.disabled = false;\n // Re-enabling the requestee field depends on the status\n // of the flag.\n toggleRequesteeField(flagField, 1);\n }\n }\n }\n}\n\nfunction handleWantsAttachment(wants_attachment) {\n if (wants_attachment) {\n document.getElementById('attachment_false').style.display = 'none';\n document.getElementById('attachment_true').style.display = 'block';\n }\n else {\n document.getElementById('attachment_false').style.display = 'block';\n document.getElementById('attachment_true').style.display = 'none';\n clearAttachmentFields();\n }\n}\n\n-->\n</script>\n\n<form name=\"Create\" id=\"Create\" method=\"post\" action=\"post_bug.cgi\"\n enctype=\"multipart/form-data\">\n<input type=\"hidden\" name=\"product\" value=\""; #line 161 "template\en\default\bug\create\create.html.tmpl" # FILTER $output .= do { my $output = ''; my $_tt_filter = $context->filter('html') || $context->throw($context->error); $output .= $stash->get(['product', 0, 'name', 0]); &$_tt_filter($output); }; $output .= "\">\n<input type=\"hidden\" name=\"token\" value=\""; #line 162 "template\en\default\bug\create\create.html.tmpl" # FILTER $output .= do { my $output = ''; my $_tt_filter = $context->filter('html') || $context->throw($context->error); $output .= $stash->get('token'); &$_tt_filter($output); }; $output .= "\">\n\n<table cellspacing=\"2\" cellpadding=\"0\" border=\"0\">\n\n <tr>\n <td> </td>\n <td colspan=\"3\">\n "; #line 172 "template\en\default\bug\create\create.html.tmpl" $output .= $context->include('bug/create/user-message.html.tmpl'); $output .= "\n </td>\n </tr>\n\n <tr>\n <td> </td>\n <td colspan=\"3\"> </td>\n </tr>\n\n <tr>\n <td align=\"right\" valign=\"top\"><strong>Reporter:</strong></td>\n <td valign=\"top\">"; #line 183 "template\en\default\bug\create\create.html.tmpl" # FILTER $output .= do { my $output = ''; my $_tt_filter = $context->filter('html') || $context->throw($context->error); $output .= $stash->get(['user', 0, 'login', 0]); &$_tt_filter($output); }; $output .= "</td>\n\n <td align=\"right\" valign=\"top\"><strong>Product:</strong></td>\n <td valign=\"top\">"; #line 186 "template\en\default\bug\create\create.html.tmpl" # FILTER $output .= do { my $output = ''; my $_tt_filter = $context->filter('html') || $context->throw($context->error); $output .= $stash->get(['product', 0, 'name', 0]); &$_tt_filter($output); }; $output .= "</td>\n </tr>\n\n "; $output .= "\n <tr>\n <td align=\"right\" valign=\"top\">\n <strong>Version:</strong>\n </td>\n <td>\n <select name=\"version\" size=\"5\">"; #line 200 "template\en\default\bug\create\create.html.tmpl" # FOREACH do { my ($_tt_value, $_tt_error, $_tt_oldloop); my $_tt_list = $stash->get('version'); unless (UNIVERSAL::isa($_tt_list, 'Template::Iterator')) { $_tt_list = Template::Config->iterator($_tt_list) || die $Template::Config::ERROR, "\n"; } ($_tt_value, $_tt_error) = $_tt_list->get_first(); eval { $_tt_oldloop = $stash->get('loop') }; $stash->set('loop', $_tt_list); eval { LOOP: while (! $_tt_error) { $stash->{'v'} = $_tt_value; $output .= "\n <option value=\""; #line 197 "template\en\default\bug\create\create.html.tmpl" # FILTER $output .= do { my $output = ''; my $_tt_filter = $context->filter('html') || $context->throw($context->error); $output .= $stash->get('v'); &$_tt_filter($output); }; $output .= "\""; #line 198 "template\en\default\bug\create\create.html.tmpl" if ($stash->get('v') eq $stash->get(['default', 0, 'version', 0])) { $output .= ('' . " selected=\"selected\""); } $output .= ">"; #line 198 "template\en\default\bug\create\create.html.tmpl" # FILTER $output .= do { my $output = ''; my $_tt_filter = $context->filter('html') || $context->throw($context->error); $output .= $stash->get('v'); &$_tt_filter($output); }; $output .= " </option>";; ($_tt_value, $_tt_error) = $_tt_list->get_next(); } }; $stash->set('loop', $_tt_oldloop); die $@ if $@; $_tt_error = 0 if $_tt_error && $_tt_error eq Template::Constants::STATUS_DONE; die $_tt_error if $_tt_error; }; $output .= "\n </select>\n </td>\n\n <td align=\"right\" valign=\"top\">\n <strong>\n <a href=\"describecomponents.cgi?product="; #line 206 "template\en\default\bug\create\create.html.tmpl" # FILTER $output .= do { my $output = ''; my $_tt_filter = $context->filter('url_quote') || $context->throw($context->error); $output .= $stash->get(['product', 0, 'name', 0]); &$_tt_filter($output); }; $output .= "\">\n Component</a>:\n </strong>\n </td>\n <td>\n <select name=\"component\" onchange=\"set_assign_to();\" size=\"5\">"; #line 217 "template\en\default\bug\create\create.html.tmpl" # FOREACH do { my ($_tt_value, $_tt_error, $_tt_oldloop); my $_tt_list = $stash->get(['product', 0, 'components', 0]); unless (UNIVERSAL::isa($_tt_list, 'Template::Iterator')) { $_tt_list = Template::Config->iterator($_tt_list) || die $Template::Config::ERROR, "\n"; } ($_tt_value, $_tt_error) = $_tt_list->get_first(); eval { $_tt_oldloop = $stash->get('loop') }; $stash->set('loop', $_tt_list); eval { LOOP: while (! $_tt_error) { $stash->{'c'} = $_tt_value; $output .= "\n <option value=\""; #line 213 "template\en\default\bug\create\create.html.tmpl" # FILTER $output .= do { my $output = ''; my $_tt_filter = $context->filter('html') || $context->throw($context->error); $output .= $stash->get(['c', 0, 'name', 0]); &$_tt_filter($output); }; $output .= "\""; #line 214 "template\en\default\bug\create\create.html.tmpl" if ($stash->get(['c', 0, 'name', 0]) eq $stash->get(['default', 0, 'component_', 0])) { $output .= ('' . " selected=\"selected\""); } $output .= ">"; #line 215 "template\en\default\bug\create\create.html.tmpl" # FILTER $output .= do { my $output = ''; my $_tt_filter = $context->filter('html') || $context->throw($context->error); $output .= $stash->get(['c', 0, 'name', 0]); &$_tt_filter($output); }; $output .= " </option>";; ($_tt_value, $_tt_error) = $_tt_list->get_next(); } }; $stash->set('loop', $_tt_oldloop); die $@ if $@; $_tt_error = 0 if $_tt_error && $_tt_error eq Template::Constants::STATUS_DONE; die $_tt_error if $_tt_error; }; $output .= "\n </select>\n </td>\n </tr>\n\n <tr>\n <td> </td>\n <td colspan=\"3\"> </td>\n </tr>\n\n <tr>"; #line 228 "template\en\default\bug\create\create.html.tmpl" $stash->set('sel', { 'description' => 'Severity', 'name' => 'bug_severity' }); #line 229 "template\en\default\bug\create\create.html.tmpl" $output .= $context->include('select'); $output .= "\n"; #line 231 "template\en\default\bug\create\create.html.tmpl" $stash->set('sel', { 'description' => 'Platform', 'name' => 'rep_platform' }); #line 232 "template\en\default\bug\create\create.html.tmpl" $output .= $context->include('select'); $output .= "\n </tr>\n\n <tr>"; #line 243 "template\en\default\bug\create\create.html.tmpl" if ($stash->get(['Param', [ 'letsubmitterchoosepriority' ]])) { #line 237 "template\en\default\bug\create\create.html.tmpl" $stash->set('sel', { 'description' => 'Priority', 'name' => 'priority' }); #line 238 "template\en\default\bug\create\create.html.tmpl" $output .= $context->include('select'); } else { $output .= "\n <td colspan=\"2\">\n <input type=\"hidden\" name=\"priority\" value=\""; #line 241 "template\en\default\bug\create\create.html.tmpl" # FILTER $output .= do { my $output = ''; my $_tt_filter = $context->filter('html') || $context->throw($context->error); $output .= $stash->get(['default', 0, 'priority', 0]); &$_tt_filter($output); }; $output .= "\">\n </td>"; } $output .= "\n"; #line 245 "template\en\default\bug\create\create.html.tmpl" $stash->set('sel', { 'description' => 'OS', 'name' => 'op_sys' }); #line 246 "template\en\default\bug\create\create.html.tmpl" $output .= $context->include('select'); $output .= "\n </tr>\n"; #line 255 "template\en\default\bug\create\create.html.tmpl" if ($stash->get(['Param', [ 'usetargetmilestone' ]]) && $stash->get(['Param', [ 'letsubmitterchoosemilestone' ]])) { $output .= "\n <tr>"; #line 251 "template\en\default\bug\create\create.html.tmpl" $stash->set('sel', { 'description' => 'Target Milestone', 'name' => 'target_milestone' }); #line 252 "template\en\default\bug\create\create.html.tmpl" $output .= $context->include('select'); $output .= "\n <td colspan=\"2\"> </td>\n </tr>"; }
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -