Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Z_DeleteInvoice: locstock not updated
10-17-2018, 11:44 PM,
#1
Z_DeleteInvoice: locstock not updated
It looks like the query used to supposedly update locstock is missing and what is used instead in the if statement line 130 is the same $SQL used to update salesorderdetails.


starting line 121:
Code:
$SQL = "UPDATE salesorderdetails SET qtyinvoiced = qtyinvoiced + " . $OrderLine['qty'] . ",
                                             completed = 0
                                WHERE orderno = '" . $ProcessingOrder . "'
                                AND stkcode = '" . $OrderLine['stockid'] . "'";

    $ErrMsg = _('The SQL to reverse the update of the sales order detail records failed because');
    $Result = DB_query($SQL,$ErrMsg,$DbgMsg,true);
    prnMsg(_('The sales order records have been updated as not invoiced'),'info');
/*reverse the update to LocStock */
    if ($OrderLine['mbflag']!='A' AND $OrderLine['mbflag']!='D'){

            $ErrMsg = _('The SQL to reverse update to the location stock records failed because');
            $Result = DB_query($SQL, $ErrMsg, $DbgMsg, true);
             prnMsg(_('Reversed the location stock quantities for items that decreased'),'info');
    }

Additionally, it appears that controlled items are not handled by the script as stockserialmoves is not called in the process

Thank you for your input!
Reply


Messages In This Thread
Z_DeleteInvoice: locstock not updated - by HDeriauFF - 10-17-2018, 11:44 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)