End of week commit

This commit is contained in:
2014-04-18 20:38:13 +02:00
parent 2a5331471c
commit 821f59b761
42 changed files with 304 additions and 91 deletions
+21 -15
View File
@@ -1,19 +1,25 @@
- model_class = Product
.page-header= title :show, @product
dl.dl-horizontal.show-list
dt= model_class.human_attribute_name(:name)
dd= @product.name
dt= model_class.human_attribute_name(:code)
dd= @product.code
dt= model_class.human_attribute_name(:price)
dd=currency @product.price
dt= ProductCategory.model_name.human_plural
dd= @product.category_links(namespace: :suppliers)
.display-row
.display-label
span data-t='attributes.product.name'
.display-field
span= @product.name
.display-row
.display-label
span data-t='attributes.product.code'
.display-field
span= @product.code
.display-row
.display-label
span data-t='attributes.product.price'
.display-field
span=currency @product.price
.display-row
.display-label
span data-t='models.plural.product_category'
.display-field
span= @product.category_links(namespace: :suppliers)
.form-actions
= link_to t("helpers.links.back"), suppliers_products_path, class: 'btn'
'
= link_to t('helpers.links.edit'), [:edit, :suppliers, @product], class: 'btn'
'
= link_to t("helpers.links.destroy"), [:suppliers, @product], method: :delete, data: {confirm: are_you_sure? }, class: 'btn btn-danger'
= supplier_form_actions :index, :edit, :destroy, object: @product, for: :products