Add hint to copy stock_article if price change desired in delivery process

This commit is contained in:
Julius 2013-07-08 21:02:43 +02:00
parent 5fcc14a36d
commit ff1317b17b
4 changed files with 18 additions and 1 deletions

View file

@ -25,4 +25,13 @@ module DeliveriesHelper
return output.html_safe return output.html_safe
end end
def stock_article_price_hint(stock_article)
t('simple_form.hints.stock_article.edit_stock_article.price',
:stock_article_copy_link => link_to(t('.copy_stock_article'),
copy_stock_article_supplier_deliveries_path(@supplier, :old_stock_article_id => stock_article.id),
:remote => true
)
)
end
end end

View file

@ -16,7 +16,7 @@
%span.add-on % %span.add-on %
= f.input :deposit = f.input :deposit
- else - else
= f.input :price, :input_html => {:disabled => 'disabled'}, :hint => t('stockit.form.price_hint') = f.input :price, :input_html => {:disabled => 'disabled'}, :hint => stock_article_price_hint(stock_article)
= f.association :article_category = f.association :article_category
.modal-footer .modal-footer
= link_to t('ui.close'), '#', class: 'btn', data: {dismiss: 'modal'} = link_to t('ui.close'), '#', class: 'btn', data: {dismiss: 'modal'}

View file

@ -461,6 +461,8 @@ de:
action_add_to_delivery: 'Liefern' action_add_to_delivery: 'Liefern'
action_edit: 'Bearbeiten' action_edit: 'Bearbeiten'
action_other_price: 'Kopieren' action_other_price: 'Kopieren'
stock_article_form:
copy_stock_article: 'Lagerartikel kopieren'
stock_change_fields: stock_change_fields:
remove_article: Artikel aus Lieferung entfernen remove_article: Artikel aus Lieferung entfernen
suppliers_overview: Lieferantenübersicht suppliers_overview: Lieferantenübersicht
@ -1528,6 +1530,8 @@ de:
supplier: supplier:
copy_stock_article: copy_stock_article:
name: Bitte ändern name: Bitte ändern
edit_stock_article:
price: ! '<ul><li>Preisänderung gesperrt.</li><li>Bei Bedarf %{stock_article_copy_link}.</li></ul>'
supplier: supplier:
min_order_quantity: Die Mindestbestellmenge wird während der Bestellung angezeigt und soll motivieren min_order_quantity: Die Mindestbestellmenge wird während der Bestellung angezeigt und soll motivieren
task: task:

View file

@ -463,6 +463,8 @@ en:
action_add_to_delivery: 'Add to delivery' action_add_to_delivery: 'Add to delivery'
action_edit: 'Edit' action_edit: 'Edit'
action_other_price: 'Copy' action_other_price: 'Copy'
stock_article_form:
copy_stock_article: 'Lagerartikel kopieren'
stock_change_fields: stock_change_fields:
remove_article: Remove article from delivery remove_article: Remove article from delivery
suppliers_overview: Supplier overview suppliers_overview: Supplier overview
@ -1530,6 +1532,8 @@ en:
supplier: supplier:
copy_stock_article: copy_stock_article:
name: Please modify name: Please modify
edit_stock_article:
price: ! '<ul><li>Price changes are forbidden.</li><li>If necessary, %{stock_article_copy_link}.</li></ul>'
supplier: supplier:
min_order_quantity: The minimum amount which has to be orderd will be shown during the order process and should motivate ordering min_order_quantity: The minimum amount which has to be orderd will be shown during the order process and should motivate ordering
task: task: