Add SupplierCategory
This allows the categorization of suppliers. For a better reporting it is necessary to split the expenses of the invoices. E.g. we want to be able to generate independent sums of general cost like the rent or electricity and the cost of the bought articles.
This commit is contained in:
parent
f5bbe0d5ae
commit
d90d188dbf
11 changed files with 90 additions and 25 deletions
|
|
@ -12,6 +12,9 @@
|
|||
= f.input :url
|
||||
= f.input :contact_person
|
||||
= f.input :customer_number
|
||||
- supplier_categories = SupplierCategory.order(:name)
|
||||
- if supplier_categories.count > 1
|
||||
= f.association :supplier_category, collection: supplier_categories, include_blank: false
|
||||
- if FoodsoftConfig[:use_iban]
|
||||
= f.input :iban
|
||||
= f.input :delivery_days
|
||||
|
|
|
|||
|
|
@ -29,6 +29,9 @@
|
|||
%dd= @supplier.contact_person
|
||||
%dt= heading_helper(Supplier, :customer_number) + ':'
|
||||
%dd= @supplier.customer_number
|
||||
- if SupplierCategory.count > 1
|
||||
%dt= heading_helper(Supplier, :supplier_category) + ':'
|
||||
%dd= @supplier.supplier_category.try(:name)
|
||||
- if FoodsoftConfig[:use_iban]
|
||||
%dt= heading_helper(Supplier, :iban) + ':'
|
||||
%dd= @supplier.iban
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue