summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app/views/glsa/edit.html.erb')
-rw-r--r--app/views/glsa/edit.html.erb177
1 files changed, 0 insertions, 177 deletions
diff --git a/app/views/glsa/edit.html.erb b/app/views/glsa/edit.html.erb
deleted file mode 100644
index 000d1be..0000000
--- a/app/views/glsa/edit.html.erb
+++ /dev/null
@@ -1,177 +0,0 @@
-<h1>
- Edit GLSA <code><%= @glsa.glsa_id %></code>
-</h1>
-
-<%= form_for @glsa do |f| -%>
-<div style="float: right; width: 44%;">
- <div class="box">
- <%= box_title('Permissions', :icon => 'icons/permission.png') %>
- <p><label for="permissions">This GLSA is</label>:
- <select name="glsa[restricted]" id="permissions">
- <%= options_for_select %w{ public confidential }, @glsa.restricted ? "confidential" : "public" %>
- </select>
- </p>
- </div>
-
- <div class="box">
- <%= box_title('Metadata', :icon => 'icons/metadata.png') %>
- <p style="float: left; width: 50%;"><label for="access"><%= image_tag 'icons/access.png' %> Access:</label>
- <select name="glsa[access]" id="access">
- <%= options_for_select [['local', 'local'], ['remote', 'remote'], ['local, remote', 'both']], lastrev_content(@glsa, 'access') %>
- </select>
- </p>
- <p><label for="severity"><%= image_tag 'icons/severity.png' %> Severity:</label>
- <select name="glsa[severity]" id="severity">
- <%= options_for_select %w{ low normal high }, lastrev_content(@glsa, 'severity') %>
- </select>
- </p>
- <p><label for="keyword"><%= image_tag 'icons/keyword.png' %> GLSA Keyword:</label>
- <%= text_field_tag "glsa[product]", lastrev_content(@glsa, 'product'), :class => "nice" %>
- </p>
- </div>
-
- <div class="box">
- <%= box_title('Background', :icon => 'icons/background.png', :label => 'background') %>
- <p>
- <textarea name="glsa[background]" id="background" class="nice" rows="3"><%= lastrev_content(@glsa, 'background') %></textarea>
- </p>
- </div>
-
- <div class="box">
- <%= box_title('Bugs', :icon => 'icons/bug.png',
- :toolbar => [{:uri => "javascript:GLSAMaker.editing.bugs.add_dialog(#{@glsa.id})", :title => 'Add bug', :icon => 'icons/plus.png'}]) %>
- <table id="bugtable">
- <%= render :partial => "edit_bug_row", :collection => @bugs, :as => :bug %>
- </table>
- </div>
-
- <%= render :partial => "comments" %>
-
- <div style="text-align: right;">
- <input type="submit" class="button" style="font-size: 150%;" value="Save &rarr;" />
- </div>
-</div>
-
-<div id="left">
- <div class="box">
- <%= box_title('Title', :icon => 'icons/title.png',
- :toolbar => [{:title => 'Add template', :uri => "javascript:GLSAMaker.editing.templates.dropdown(this, 'title');", :icon => 'icons/template.png'}]) %>
- <p><textarea name="glsa[title]" id="title" class="largetext nice" rows="1"><%= lastrev_content(@glsa, 'title') %></textarea></p>
- </div>
-
- <div class="box">
- <%= box_title('Synopsis', :icon => 'icons/synopsis.png', :label => 'synopsis',
- :toolbar => [
- {:title => 'Add template', :uri => "javascript:GLSAMaker.editing.templates.dropdown(this, 'synopsis');", :icon => 'icons/template.png'}
- ]
- ) %>
- <p><textarea name="glsa[synopsis]" id="synopsis" class="nice" rows="1"><%= lastrev_content(@glsa, 'synopsis') %></textarea></p>
- </div>
-
- <div class="box">
- <%= box_title('Packages', :icon => 'icons/package.png') %>
-
- <table class="padcells swap centercells" id="packages_table_vulnerable">
- <tr>
- <th><%= image_tag 'icons/atom.png' %> Atom</th>
- <th class="odd" colspan="2">Version</th>
- <th title="* or slot">Slot</th>
- <th title="* or space-separated list of arches"><%= image_tag 'icons/arch.png' %> Arch</th>
- <th class="odd"><%= image_tag 'icons/auto.png' %> Auto</th>
- </tr>
-
- <tr>
- <td><%= image_tag 'icons/affected.png' %> Vulnerable
- (<%= add_vulnerable_package_link(image_tag('icons/package-add.png')) %>)</td>
- </tr>
- <%= render :partial => 'package', :collection => @vulnerable_packages %>
- </table>
-
- <table class="padcells swap centercells" id="packages_table_unaffected">
- <tr>
- <td><%= image_tag 'icons/unaffected.png' %> Unaffected
- (<%= add_unaffected_package_link(image_tag('icons/package-add.png')) %>)</td>
- </tr>
- <%= render :partial => 'package', :collection => @unaffected_packages %>
-
- </table>
- </div>
-
- <div class="box" id="desc-box">
- <%= box_title('Description', :icon => 'icons/document.png', :label => 'description',
- :toolbar => [
- {:title => 'Add template', :uri => "javascript:GLSAMaker.editing.templates.dropdown(this, 'description');", :icon => 'icons/template.png'},
- {:title => 'Set default description', :uri => "javascript:generateDescription()", :icon => 'icons/document-go.png'},
- :sep,
- {:title => 'Fewer lines', :uri => "javascript:lines('description', -5)", :icon => 'icons/zoom_out.png'},
- {:title => 'Reset lines', :uri => "javascript:$('description').rows = 15", :icon => 'icons/zoom_100.png'},
- {:title => 'More lines', :uri => "javascript:lines('description', 5)", :icon => 'icons/zoom_in.png'}
- ]
- ) %>
- <p><textarea name="glsa[description]" id="description" class="nice" rows="15"><%= lastrev_content(@glsa, 'description') %></textarea></p>
- </div>
-
- <div class="box">
- <%= box_title('Impact', :icon => 'icons/impact.png', :label => 'impact',
- :toolbar => [
- {:title => 'Add template', :uri => "javascript:GLSAMaker.editing.templates.dropdown(this, 'impact');", :icon => 'icons/template.png'},
- :sep,
- {:title => 'Fewer lines', :uri => "javascript:lines('impact', -5)", :icon => 'icons/zoom_out.png'},
- {:title => 'Reset lines', :uri => "javascript:$('impact').rows = 15", :icon => 'icons/zoom_100.png'},
- {:title => 'More lines', :uri => "javascript:lines('impact', 5)", :icon => 'icons/zoom_in.png'}
- ]
- ) %>
- <p><textarea name="glsa[impact]" id="impact" class="nice" rows="5"><%= lastrev_content(@glsa, 'impact') %></textarea></p>
- </div>
-
- <div class="box">
- <%= box_title('Workaround', :icon => 'icons/workaround.png', :label => 'workaround',
- :toolbar => [
- {:title => 'Add template', :uri => "javascript:GLSAMaker.editing.templates.dropdown(this, 'workaround');", :icon => 'icons/template.png'},
- {:title => 'No known workaround', :uri => "javascript:$('workaround').value = 'There is no known workaround at this time.'", :icon => 'icons/workaround-no.png'}
- ]
- ) %>
- <p><textarea name="glsa[workaround]" id="workaround" class="nice" rows="2"><%= lastrev_content(@glsa, 'workaround') %></textarea></p>
- </div>
-
- <div class="box">
- <%= box_title('Resolution', :icon => 'icons/resolution.png', :label => 'resolution',
- :toolbar => [
- {:title => 'Add template', :uri => "javascript:GLSAMaker.editing.templates.dropdown(this, 'resolution');", :icon => 'icons/template.png'},
- {:title => 'Set default resolution', :uri => "javascript:generateResolution()", :icon => 'icons/resolution-go.png'}
- ]
- ) %>
- <p><textarea name="glsa[resolution]" id="resolution" class="nice" rows="5"><%= lastrev_content(@glsa, 'resolution') %></textarea></p>
- </div>
-
- <div class="box">
- <%= box_title('References', :icon => 'icons/reference.png',
- :toolbar => [
- {:title => 'Add reference', :uri => "javascript:Element.insert('references_table', { bottom: '#{escape_javascript(render(:partial => 'reference', :object => Reference.new))}' })", :icon => 'icons/reference-add.png'}
- ]
- ) %>
- <table class="padcells swap centercells" id="references_table">
- <tr>
- <th><%= image_tag 'icons/atom.png' %> Title</th>
- <th><%= image_tag 'icons/reference.png' %> URL</th>
- <th></th>
- </tr>
-
- <%= render :partial => 'reference', :collection => @references %>
- </table>
- </div>
-
-</div>
-
-<%- end -%>
-
-<%= template_popups %>
-
-<script language="JavaScript" type="text/javascript">
- GLSAMaker.editing.templates.observeClick($('title'));
- GLSAMaker.editing.templates.observeClick($('synopsis'));
- GLSAMaker.editing.templates.observeClick($('description'));
- GLSAMaker.editing.templates.observeClick($('impact'));
- GLSAMaker.editing.templates.observeClick($('workaround'));
- GLSAMaker.editing.templates.observeClick($('resolution'));
-</script>