Add admin UI for SupplierCategories
This commit is contained in:
parent
7e8c1d041d
commit
708f85a839
10 changed files with 108 additions and 0 deletions
12
app/views/admin/supplier_categories/_form.html.haml
Normal file
12
app/views/admin/supplier_categories/_form.html.haml
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
= simple_form_for [:admin, @supplier_category], :validate => true, :remote => true do |f|
|
||||
.modal-header
|
||||
= close_button :modal
|
||||
%h3= @supplier_category.new_record? ? t('.title_new') : t('.title_edit')
|
||||
.modal-body
|
||||
= f.input :name
|
||||
= f.input :description
|
||||
= f.association :financial_transaction_class, :include_blank => false
|
||||
= f.association :bank_account, :include_blank => false
|
||||
.modal-footer
|
||||
= link_to t('ui.close'), '#', class: 'btn', data: {dismiss: 'modal'}
|
||||
= f.submit class: 'btn btn-primary'
|
||||
2
app/views/admin/supplier_categories/new.js.haml
Normal file
2
app/views/admin/supplier_categories/new.js.haml
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
$('#modalContainer').html('#{j(render("form"))}');
|
||||
$('#modalContainer').modal();
|
||||
Loading…
Add table
Add a link
Reference in a new issue