From acf5add18d8589f565cd443554ec448a3e26f797 Mon Sep 17 00:00:00 2001 From: Dai Date: Sun, 13 Oct 2024 21:35:59 +0800 Subject: [PATCH] =?UTF-8?q?fix=20=E8=AF=BE=E8=A1=A8=E7=94=9F=E6=88=90?= =?UTF-8?q?=E9=AB=98=E6=B8=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/api/controller/StudentController.php | 2 +- app/api/controller/TeacherScheduleTimeController.php | 2 +- plugin/admin/app/controller/TeacherScheduleTimeController.php | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/api/controller/StudentController.php b/app/api/controller/StudentController.php index d101006..861c293 100644 --- a/app/api/controller/StudentController.php +++ b/app/api/controller/StudentController.php @@ -204,7 +204,7 @@ class StudentController extends BaseController { mkdir($base['file_path'], 0777, true);//可创建多级目录 } - imagepng($img, $save_path);//输出图片,输出png使用imagepng方法,输出gif使用imagegif方法 + imagepng($img, $save_path, 0);//输出图片,输出png使用imagepng方法,输出gif使用imagegif方法 $url = getenv('SERVER_DOMAIN') . $file_path . $params['file_name']; return $this->json([ diff --git a/app/api/controller/TeacherScheduleTimeController.php b/app/api/controller/TeacherScheduleTimeController.php index 17cadef..4528a24 100644 --- a/app/api/controller/TeacherScheduleTimeController.php +++ b/app/api/controller/TeacherScheduleTimeController.php @@ -176,7 +176,7 @@ class TeacherScheduleTimeController extends BaseController { mkdir($base['file_path'], 0777, true);//可创建多级目录 } - imagepng($img, $save_path);//输出图片,输出png使用imagepng方法,输出gif使用imagegif方法 + imagepng($img, $save_path, 0);//输出图片,输出png使用imagepng方法,输出gif使用imagegif方法 $url = getenv('SERVER_DOMAIN') . $file_path . $params['file_name']; diff --git a/plugin/admin/app/controller/TeacherScheduleTimeController.php b/plugin/admin/app/controller/TeacherScheduleTimeController.php index 6bbb061..a2d06a4 100644 --- a/plugin/admin/app/controller/TeacherScheduleTimeController.php +++ b/plugin/admin/app/controller/TeacherScheduleTimeController.php @@ -458,7 +458,7 @@ class TeacherScheduleTimeController extends Crud 'msg' => '请先选择课程再发布' ]); } - + $student_schedule = StudentSchedule::where(['teacher_schedule_time_id' => $teacher_schedule_time->id])->select(); if($student_schedule->isEmpty()){ return json([