调整审批流&&增加人员分组
This commit is contained in:
@@ -393,6 +393,44 @@ class StockOrdersService
|
||||
return $this->postProcess('Approval', $item);
|
||||
}
|
||||
|
||||
/**
|
||||
* 作废审批
|
||||
*/
|
||||
public function serviceApprovalNullify(Request $request)
|
||||
{
|
||||
$config = $this->buildQueryConfig($request, 'approval');
|
||||
$item = $this->logicShow($config);
|
||||
$this->approvalNullify($item);
|
||||
return $this->postProcess('Approval', $item);
|
||||
}
|
||||
|
||||
/**
|
||||
* 审批作废
|
||||
*/
|
||||
public function approvalNullify($item)
|
||||
{
|
||||
$appro = new \app\common\utils\approval\service\ApprovalFlowService();
|
||||
$appro->startNullify('stock_orders_nullify', 'stock_orders_nullify', $item->id, [], $item->salesperson_id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 撤销审批
|
||||
*/
|
||||
public function serviceApprovalRevoke(Request $request)
|
||||
{
|
||||
$config = $this->buildQueryConfig($request, 'approval');
|
||||
$item = $this->logicShow($config);
|
||||
$this->approvalRevoke($item);
|
||||
return $this->postProcess('Approval', $item);
|
||||
}
|
||||
|
||||
public function approvalRevoke($item)
|
||||
{
|
||||
$instance = \app\common\model\ApprovalInstances::where('biz_id', $item->id)->where('flow_type', 'stock_orders')->first();
|
||||
$appro = new \app\common\utils\approval\service\ApprovalFlowService();
|
||||
$appro->revoke($instance->id, $item->salesperson_id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 创建
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user