//Removing the Reservation
//remark ProdTable is current prodTable record on the prodTable
clicked()
{
ProdTable ProdTable;
InventUpd_Reservation res;
InventMovement movement;
InventDimParm inventDimParmFixed;
InventDimParm inventDimParm;
Salesline Salesline = Salesline::findInventTransId(ProdTable.inventRefTransId,true);
InventDim inventDim = inventDim::find(Salesline.inventDimId);
Inventtrans Inventtrans;
;
if(Custtable::find(Salesline.CustAccount))
{
Inventtrans = InventTrans::findTransId(Salesline.inventtransId);
if(Inventtrans.StatusIssue == StatusIssue::ReservPhysical)
{
movement = Inventtrans.inventmovement(true);
res = InventUpd_Reservation::newInventDim( movement,
inventTrans.inventDim(),
Salesline.SalesQty,
true
);
res.updatenow();
}
}
}
没有评论:
发表评论