mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-02-05 22:26:07 +00:00
Use localizeCurrency filter in subscriptions
This commit is contained in:
@@ -19,7 +19,7 @@
|
||||
%div{ ng: { bind: "::orderCycleCloses(proxyOrder.order_cycle_id)" } }
|
||||
%td.text-center
|
||||
%span.state{ ng: { class: "proxyOrder.state", bind: 'stateText(proxyOrder.state)' } }
|
||||
%td.text-center{ ng: { bind: '(proxyOrder.total || subscription.estimatedTotal()) | currency' } }
|
||||
%td.text-center{ ng: { bind: '(proxyOrder.total || subscription.estimatedTotal()) | localizeCurrency' } }
|
||||
%td.actions
|
||||
%a.edit-order.icon-edit.no-text{ href: '{{::proxyOrder.edit_path}}', target: '_blank', 'ofn-with-tip' => t(:edit_order), confirm_order_edit: true }
|
||||
%a.cancel-order.icon-remove.no-text{ href: 'javascript:void(0)', ng: { hide: "proxyOrder.state == 'canceled'", click: "cancelOrder(proxyOrder)" }, 'ofn-with-tip' => t(:cancel_order) }
|
||||
|
||||
@@ -75,9 +75,9 @@
|
||||
.description {{ item.description }}
|
||||
.not-in-open-and-upcoming-order-cycles-warning{ ng: { if: '!item.in_open_and_upcoming_order_cycles' } }
|
||||
= t(".no_open_or_upcoming_order_cycle")
|
||||
%td.price.align-center {{ item.price_estimate | currency }}
|
||||
%td.price.align-center {{ item.price_estimate | localizeCurrency }}
|
||||
%td.quantity {{ item.quantity }}
|
||||
%td.total.align-center {{ (item.price_estimate * item.quantity) | currency }}
|
||||
%td.total.align-center {{ (item.price_estimate * item.quantity) | localizeCurrency }}
|
||||
%tbody#subtotal.no-border-top{"data-hook" => "admin_order_form_subtotal"}
|
||||
%tr#subtotal-row
|
||||
%td{:colspan => "3"}
|
||||
@@ -85,7 +85,7 @@
|
||||
= t(:subtotal)
|
||||
\:
|
||||
%td.total.align-center
|
||||
%span {{ subscription.estimatedSubtotal() | currency }}
|
||||
%span {{ subscription.estimatedSubtotal() | localizeCurrency }}
|
||||
%tbody#order-total.grand-total.no-border-top{"data-hook" => "admin_order_form_total"}
|
||||
%tr
|
||||
%td{:colspan => "3"}
|
||||
@@ -93,6 +93,6 @@
|
||||
= t(:order_total_price)
|
||||
\:
|
||||
%td.total.align-center
|
||||
%span#order_form_total {{ subscription.estimatedTotal() | currency }}
|
||||
%span#order_form_total {{ subscription.estimatedTotal() | localizeCurrency }}
|
||||
%p.notice
|
||||
= t "this_is_an_estimate", scope: 'admin.subscriptions.subscription_line_items'
|
||||
|
||||
@@ -19,10 +19,10 @@
|
||||
.description {{ item.description }}
|
||||
.not-in-open-and-upcoming-order-cycles-warning{ ng: { if: '!item.in_open_and_upcoming_order_cycles' } }
|
||||
= t(".not_in_open_and_upcoming_order_cycles_warning")
|
||||
%td.price.align-center {{ item.price_estimate | currency }}
|
||||
%td.price.align-center {{ item.price_estimate | localizeCurrency }}
|
||||
%td.quantity
|
||||
%input{ name: 'quantity', type: 'number', min: 0, ng: { model: 'item.quantity' } }
|
||||
%td.total.align-center {{ (item.price_estimate * item.quantity) | currency }}
|
||||
%td.total.align-center {{ (item.price_estimate * item.quantity) | localizeCurrency }}
|
||||
%td.actions
|
||||
%a.delete-item.icon-trash.no-text{ ng: { click: 'removeSubscriptionLineItem(item)'}, :href => "javascript:void(0)" }
|
||||
%tbody#subtotal.no-border-top{"data-hook" => "admin_order_form_subtotal"}
|
||||
@@ -32,7 +32,7 @@
|
||||
= t(:subtotal)
|
||||
\:
|
||||
%td.total.align-center
|
||||
%span#order_subtotal {{ subscription.estimatedSubtotal() | currency }}
|
||||
%span#order_subtotal {{ subscription.estimatedSubtotal() | localizeCurrency }}
|
||||
%td.actions
|
||||
%tbody#fees.no-border-top{ ng: { show: "subscription.estimatedFees() > 0" } }
|
||||
%tr#fees-row
|
||||
@@ -41,7 +41,7 @@
|
||||
= t(:fees)
|
||||
\:
|
||||
%td.total.align-center
|
||||
%span#order_fees {{ subscription.estimatedFees() | currency }}
|
||||
%span#order_fees {{ subscription.estimatedFees() | localizeCurrency }}
|
||||
%td.actions
|
||||
%tbody#order-total.grand-total.no-border-top{"data-hook" => "admin_order_form_total"}
|
||||
%tr
|
||||
@@ -50,7 +50,7 @@
|
||||
= t(:order_total_price)
|
||||
\:
|
||||
%td.total.align-center
|
||||
%span#order_form_total {{ subscription.estimatedTotal() | currency }}
|
||||
%span#order_form_total {{ subscription.estimatedTotal() | localizeCurrency }}
|
||||
%td.actions
|
||||
%p.notice
|
||||
= t ".this_is_an_estimate"
|
||||
|
||||
Reference in New Issue
Block a user