Fix: Dr/Cr did not show in Journal Voucher because of Type error with the debit filter.
This commit is contained in:
parent
1cc9ba6a01
commit
8e8cc78489
@ -4,7 +4,7 @@ var JournalController = ['$scope', '$location', 'asDateFilter', '$modal', 'uploa
|
||||
$scope.foAccount = true;
|
||||
|
||||
$scope.voucher = voucher;
|
||||
$scope.debit = 1;
|
||||
$scope.debit = "1";
|
||||
function getOld(ledgerID, journals) {
|
||||
return _.find(journals, function (journal) {
|
||||
return journal.Ledger.LedgerID === ledgerID;
|
||||
@ -49,7 +49,7 @@ var JournalController = ['$scope', '$location', 'asDateFilter', '$modal', 'uploa
|
||||
oldJournal.Amount = amount;
|
||||
}
|
||||
} else {
|
||||
$scope.voucher.Journals.push({Debit: $scope.debit, Amount: Number($scope.amount), Ledger: $scope.account});
|
||||
$scope.voucher.Journals.push({Debit: parseInt($scope.debit), Amount: Number($scope.amount), Ledger: $scope.account});
|
||||
}
|
||||
delete $scope.account;
|
||||
delete $scope.amount;
|
||||
|
Loading…
Reference in New Issue
Block a user