This commit is contained in:
mkm 2024-01-13 10:11:13 +08:00
parent 1c80c028ad
commit ad353e17a9

View File

@ -74,19 +74,20 @@ class TaskStages extends CommonModel
$member=new MemberAccount();
$member_code=getCurrentMember()['code'];
$find=$member->where('member_code',$member_code)->find();
if($find &&$find['is_liaison_man']==0){
$joinTaskMember = true;
$type=ProjectAuth::where('id',$find['authorize'])->value('type');
if($type=='admin'){
$taskModel = $taskModel->where('t.create_by',$member_code);
}else{
if(isset($data['type']) &&$data['type']=='copied_list'){
$taskModel = $taskModel->whereRaw('find_in_set(t.copied_list ,:id) ', ['id' => $member_code]);
if(isset($data['type']) &&$data['type']=='copied_list'){
$taskModel = $taskModel->whereRaw('find_in_set(t.copied_list ,:id) ', ['id' => $member_code]);
}else{
if($find &&$find['is_liaison_man']==0){
$joinTaskMember = true;
$type=ProjectAuth::where('id',$find['authorize'])->value('type');
if($type=='admin'){
$taskModel = $taskModel->where('t.create_by',$member_code);
}else{
$taskModel = $taskModel->leftJoin('task_member tm', 't.code = tm.task_code')->where('tm.member_code', $member_code)->where('tm.is_executor', 1);
}
}
}
// if ($executor) {
// }