diff --git a/app/api/controller/Common.php b/app/api/controller/Common.php index d0daa23..7690faa 100644 --- a/app/api/controller/Common.php +++ b/app/api/controller/Common.php @@ -605,8 +605,17 @@ class Common extends ApiController } //获取审核流程节点 - public function get_flow_nodes($id=0,$type=1) + public function get_flow_nodes() { + $param = get_params(); + if (empty($param['id'])) { + $this->apiError("审批流程id不能为空"); + } + if (empty($param['type'])) { + $this->apiError("审批流程type不能为空"); + } + $id = $param['id']; + $type = $param['type']; $flows = Db::name('FlowStep')->where(['action_id'=>$id,'type'=>$type,'delete_time'=>0])->order('sort asc')->select()->toArray(); foreach ($flows as $key => &$val) { $user_id_info = Db::name('Admin')->field('id,name,thumb')->where('id','in',$val['flow_uids'])->select()->toArray();