mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-06-23 20:00:33 -04:00
Fix for expense client
This commit is contained in:
parent
cbcc299187
commit
462032f2fc
@ -386,11 +386,6 @@
|
||||
self.convert_currency = ko.observable({{ ($expense && $expense->isExchanged()) ? 'true' : 'false' }});
|
||||
self.apply_taxes = ko.observable({{ ($expense && ($expense->tax_name1 || $expense->tax_name2)) ? 'true' : 'false' }});
|
||||
|
||||
self.account_currency_id = ko.observable({{ $account->getCurrencyId() }});
|
||||
self.client_id = ko.observable({{ $clientPublicId }});
|
||||
self.vendor_id = ko.observable({{ $vendorPublicId }});
|
||||
self.expense_category_id = ko.observable({{ $categoryPublicId }});
|
||||
|
||||
self.mapping = {
|
||||
'documents': {
|
||||
create: function(options) {
|
||||
@ -403,6 +398,11 @@
|
||||
ko.mapping.fromJS(data, self.mapping, this);
|
||||
}
|
||||
|
||||
self.account_currency_id = ko.observable({{ $account->getCurrencyId() }});
|
||||
self.client_id = ko.observable({{ $clientPublicId }});
|
||||
self.vendor_id = ko.observable({{ $vendorPublicId }});
|
||||
self.expense_category_id = ko.observable({{ $categoryPublicId }});
|
||||
|
||||
self.convertedAmount = ko.computed({
|
||||
read: function () {
|
||||
return roundToTwo(self.amount() * self.exchange_rate()).toFixed(2);
|
||||
|
Loading…
x
Reference in New Issue
Block a user