internationalise currency in order screen
This commit is contained in:
parent
dddd11d8f0
commit
c31e864c73
2 changed files with 12 additions and 11 deletions
|
|
@ -3,7 +3,7 @@
|
|||
$(function() {
|
||||
#{data_to_js(@ordering_data)}
|
||||
setGroupBalance(#{@ordering_data[:available_funds]});
|
||||
setDecimalSeparator(",");
|
||||
setCurrencyFormat("#{t('number.currency.format.separator')}", #{t('number.currency.format.precision')}, "#{t('number.currency.format.unit')}");
|
||||
setToleranceBehaviour(#{FoodsoftConfig[:tolerance_is_costly]});
|
||||
setStockit(#{@order.stockit?});
|
||||
});
|
||||
|
|
@ -97,8 +97,7 @@
|
|||
%input{type: 'button', value: '-', 'data-decrease_tolerance' => order_article.id}
|
||||
|
||||
%td{id: "td_price_#{order_article.id}", style: "text-align:right; padding-right:10px; width:4em"}
|
||||
%span{id: "price_#{order_article.id}_display"}= number_to_currency(@ordering_data[:order_articles][order_article.id][:total_price], unit: "")
|
||||
€
|
||||
%span{id: "price_#{order_article.id}_display"}= number_to_currency(@ordering_data[:order_articles][order_article.id][:total_price])
|
||||
.article-info
|
||||
.article-name= order_article.article.name
|
||||
.pull-right
|
||||
|
|
@ -125,8 +124,7 @@
|
|||
%tr
|
||||
%td= t('.total_sum_amount') + ':'
|
||||
%td.currency
|
||||
%span#total_price= @group_order.price
|
||||
€
|
||||
%span#total_price= number_to_currency(@group_order.price)
|
||||
%tr
|
||||
%td= t('.available_funds') + ':'
|
||||
%td.currency= number_to_currency(@ordering_data[:available_funds])
|
||||
|
|
@ -134,8 +132,7 @@
|
|||
%td= t('.new_funds') + ':'
|
||||
%td.currency
|
||||
%strong
|
||||
%span#new_balance= @ordering_data[:available_funds] - @group_order.price
|
||||
€
|
||||
%span#new_balance= number_to_currency(@ordering_data[:available_funds] - @group_order.price)
|
||||
#order-button
|
||||
= submit_tag( t('.action_save'), id: 'submit_button', class: 'btn btn-primary' )
|
||||
#{link_to t('ui.or_cancel'), group_orders_path}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue