From 64d426be5124f46c16e105ec3f45b17c8869b481 Mon Sep 17 00:00:00 2001 From: yin5th <541304803@qq.com> Date: Wed, 20 Nov 2024 16:11:37 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E4=B8=8A=E4=BC=A0=E8=B7=AF=E5=BE=84?= =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controller/manager/Upload.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/app/controller/manager/Upload.php b/app/controller/manager/Upload.php index e7f9481..96b639e 100755 --- a/app/controller/manager/Upload.php +++ b/app/controller/manager/Upload.php @@ -25,7 +25,7 @@ class Upload extends BaseController } $this->validate = new VUpload(); $this->uploadPath = Config::get('filesystem.disks.local.url'); - if(is_writable(app()->getRootPath() . 'wwwroot' . $this->uploadPath)){ + if(is_writable(app()->getRootPath() . 'public' . $this->uploadPath)){ $this->uploadPathIsWritable = 1; } } @@ -48,7 +48,7 @@ class Upload extends BaseController return $this->json(1, $errorMsg); } } - + //文件上传(通用) public function file() { @@ -72,7 +72,7 @@ class Upload extends BaseController return $this->json(1, $errorMsg); } } - + //图片上传(通用) public function image() { @@ -108,7 +108,7 @@ class Upload extends BaseController //富文本编辑器商城图片 public function wangImage() { - + $imageArr = request()->file('wang_img'); // 该方式,前端js上传方法中字段名称必须以数组形式传参 如 wang_img[] = 值 $errno = 0; $data = []; @@ -133,7 +133,7 @@ class Upload extends BaseController } } } - + $return['errno'] = $errno; $return['data'] = $data; return json($return);