mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Handle ‘exchange rate’ field in any language
This commit is contained in:
parent
43313c4b58
commit
9a91bc7d32
@ -1063,16 +1063,16 @@ ko.bindingHandlers.productTypeahead = {
|
|||||||
from: currencyMap[accountCurrencyId].code,
|
from: currencyMap[accountCurrencyId].code,
|
||||||
to: currencyMap[clientCurrencyId].code,
|
to: currencyMap[clientCurrencyId].code,
|
||||||
});
|
});
|
||||||
if ((account.custom_invoice_text_label1 || '').toLowerCase() == 'exchange rate') {
|
if ((account.custom_invoice_text_label1 || '').toLowerCase() == "{{ strtolower(trans('texts.exchange_rate')) }}") {
|
||||||
window.model.invoice().custom_text_value1(roundToFour(rate, true));
|
window.model.invoice().custom_text_value1(roundToFour(rate, true));
|
||||||
} else if ((account.custom_invoice_text_label2 || '').toLowerCase() == 'exchange rate') {
|
} else if ((account.custom_invoice_text_label2 || '').toLowerCase() == "{{ strtolower(trans('texts.exchange_rate')) }}") {
|
||||||
window.model.invoice().custom_text_value2(roundToFour(rate, true));
|
window.model.invoice().custom_text_value2(roundToFour(rate, true));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@endif
|
@endif
|
||||||
|
|
||||||
model.cost(roundSignificant(cost, true));
|
model.cost(roundToTwo(cost, true));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!model.qty() && ! model.task_public_id()) {
|
if (!model.qty() && ! model.task_public_id()) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user