Update relation for order steps

This commit is contained in:
Fairuz
2021-08-12 13:41:27 +08:00
parent f876cc5822
commit b0246ccfda
14 changed files with 92 additions and 33 deletions
@@ -39,7 +39,7 @@ class UpdatesOrderCurrentStepProcessor
$order = $this->fetchesOrder->execute(['id'=>$order_object->getId()]);
//Count steps / obligations that pending
$order_steps_processing = $this->fetchesOrderSteps->getRepository()->where(['order_id'=>$order_object->getId(), 'status'=> OrderStatus::PROCESSING])->count();
$order_steps_processing = $this->fetchesOrderSteps->getRepository()->where(['owner_id'=>$order_object->getId(), 'status'=> OrderStatus::PROCESSING])->count();
//If no more steps / obligations, then update Order status to complete (Contract fullfilled)
if($order_steps_processing==0){