From 00d35bf431ba31770e78064ca8c5bb9ad491f05a Mon Sep 17 00:00:00 2001 From: win10 Date: Mon, 7 Sep 2020 10:36:35 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E7=AE=A1=E7=90=86=E5=91=98?= =?UTF-8?q?=E4=B8=8E=E6=95=99=E5=B8=88=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/chengji/model/Chengji.php | 4 +++- app/system/model/Fields.php | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/app/chengji/model/Chengji.php b/app/chengji/model/Chengji.php index 19c69c32..d816c2e4 100644 --- a/app/chengji/model/Chengji.php +++ b/app/chengji/model/Chengji.php @@ -233,11 +233,13 @@ class Chengji extends BaseModel { $xm = $this->cjAdmin->xingming . '(' . $this->cjAdmin->adSchool->jiancheng . ')'; } - }else{ + }elseif ($data['user_group'] === 'teacher') { if($this->cjTeacher) { $xm = $this->cjTeacher->xingming . '(' . $this->cjTeacher->jsDanwei->jiancheng . ')'; } + }else { + $xm = ''; } $arr = [ diff --git a/app/system/model/Fields.php b/app/system/model/Fields.php index 0df19ca5..52521988 100644 --- a/app/system/model/Fields.php +++ b/app/system/model/Fields.php @@ -84,11 +84,13 @@ class Fields extends BaseModel { $xm = $this->flAdmin->xingming . '(' . $this->flAdmin->adSchool->jiancheng . ')'; } - }else{ + }elseif ($data['user_group'] === 'teacher') { if($this->flTeacher) { $xm = $this->flTeacher->xingming . '(' . $this->flTeacher->jsDanwei->jiancheng . ')'; } + }else{ + $xm = ''; } $arr = [