Sha256: 657d99f456641f02520952cec726d51a4daf0b74818978a9c624b2e3ae034461

Contents?: true

Size: 1.82 KB

Versions: 1

Compression:

Stored size: 1.82 KB

Contents

= javascript 'katello/widgets/jquery.jeditable.helpers'

= content_for :content do
  .grid_8
    %h5 #{_("Custom Information")}
  .grid_9
    %table
      %tbody
        %tr#new_custom_info_row.custom_info_row
          %td
            %input.custom_info_txt#new_custom_info_keyname{:placeholder => _("Keyname")}
          %td
            %input.custom_info_txt#new_custom_info_value{:placeholder => _("Value")}
          %td
            %input.btn.primary#create_custom_info_button{:value => _("Add"), :type => "submit", "data-url" => api_create_custom_info_path(informable_type, informable_id), "data-method" => "post", :disabled => true}
        - informable.custom_info.sort.each do |info|
          - space_safe_keyname = info.keyname.gsub(" ", "_")
          %tr.multiline.custom_info_row{"data-id" => "custom_info_#{space_safe_keyname}"}
            %td.ra
              = label :custom_info, space_safe_keyname.to_sym, info.keyname
            %td
              %div{:name => "custom_info[#{info.keyname}]", :class => ("editable edit_textfield_custom_info" if informable.editable?), "data-method" => "put", "data-url" => api_update_custom_info_path(informable_type, informable_id, info.keyname)} #{info.value}
            %td
              %input.btn.warning.remove_custom_info_button{:value => _("Remove"), :type => "submit", "data-url" => api_destroy_custom_info_path(informable_type, informable_id, info.keyname), "data-method" => "delete", "data-id" => "custom_info_#{space_safe_keyname}"}

= javascript do
  :plain
    localize({
      "custom_info_create_success": '#{escape_javascript(_("Successfully created custom information"))}',
      "custom_info_delete_success": '#{escape_javascript(_("Successfully deleted custom information"))}',
      "custom_info_update_success": '#{escape_javascript(_("Successfully updated custom information"))}'
    });

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
katello-2.2.2 app/views/katello/custom_info/_edit.html.haml