From da83963484fe35ac709328eafb5b766ffbf3b00e Mon Sep 17 00:00:00 2001 From: Markus Krogh Date: Wed, 17 Dec 2014 11:34:56 +0100 Subject: Removing journal reuse --- ibisticintegration2.1.ms | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/ibisticintegration2.1.ms b/ibisticintegration2.1.ms index ea362fb..8b60a71 100644 --- a/ibisticintegration2.1.ms +++ b/ibisticintegration2.1.ms @@ -725,18 +725,10 @@ public function iteImportExpence(iteInput) //,TransactionNumberSeries: {value: getPopupValue("TransactionNumberSeriesType","General Ledger")} ,AutomaticVoucherVar : {value: false} }; - - var journalNumber2Use=0; - var keyFindGLJournal = maconomy::sql(sprint("select JournalNumber, nameofuser,period, periodend, companynumber from journal where Posted=0 and CompanyNumber='^1' and nameofuser='^2' and ((Period<='^3' and PeriodEnd>='^3') or (Period=' ' and PeriodEnd=' '))",newGLJournal.CompanyNumber.value,"ibistic",theEntryDate)); - var index=sizeof(keyFindGLJournal.result.rows); + iteInput.IbisticVoucherNo = int(iteInput.IbisticVoucherNo); //+6000000; - - if (index==0) - { - journalNumber2Use=createNewJournal(newGLJournal); - } else { - journalNumber2Use=keyFindGLJournal.result.rows[0].journalnumber.value; - } + + var journalNumber2Use = createNewJournal(newGLJournal); try { -- cgit v1.1