src-db/database/model/functions/C_INVOICE_POST.xml
changeset 7819 110640fbe62b
parent 7808 801436f99c13
child 7929 acce63739f67
equal deleted inserted replaced
7818:fc5a6575baf5 7819:110640fbe62b
  1176       -- Update Header
  1176       -- Update Header
  1177       SELECT COALESCE(SUM(TaxAmt),0) INTO v_TaxNoRecalculable
  1177       SELECT COALESCE(SUM(TaxAmt),0) INTO v_TaxNoRecalculable
  1178       FROM C_INVOICETAX
  1178       FROM C_INVOICETAX
  1179       WHERE C_Invoice_ID = v_Record_ID
  1179       WHERE C_Invoice_ID = v_Record_ID
  1180         AND Recalculate = 'N';
  1180         AND Recalculate = 'N';
  1181       SELECT c_getwithholding(v_record_id) INTO withholdamount FROM dual;
  1181       IF (v_IsSOTrx = 'N') THEN
       
  1182         SELECT c_getwithholding(v_record_id) INTO withholdamount FROM dual;
       
  1183       ELSE
       
  1184         withholdamount:=0;
       
  1185       END IF;
  1182 
  1186 
  1183       v_GrandTotal:=C_Currency_Round(v_GrandTotal+v_TaxNoRecalculable, v_Currency_ID, NULL) ;
  1187       v_GrandTotal:=C_Currency_Round(v_GrandTotal+v_TaxNoRecalculable, v_Currency_ID, NULL) ;
  1184       SELECT COALESCE(SUM(TAXAMT), 0) INTO v_GrandTotal
  1188       SELECT COALESCE(SUM(TAXAMT), 0) INTO v_GrandTotal
  1185       FROM C_INVOICETAX
  1189       FROM C_INVOICETAX
  1186       WHERE C_INVOICE_ID = v_Record_ID;
  1190       WHERE C_INVOICE_ID = v_Record_ID;