正在显示
1 个修改的文件
包含
2 行增加
和
2 行删除
| @@ -179,8 +179,6 @@ class FileController | @@ -179,8 +179,6 @@ class FileController | ||
| 179 | $url = $this->config['root'].$this->path; | 179 | $url = $this->config['root'].$this->path; |
| 180 | $fileName = uniqid().rand(10000,99999).'.'.$files->getClientOriginalExtension(); | 180 | $fileName = uniqid().rand(10000,99999).'.'.$files->getClientOriginalExtension(); |
| 181 | //同步数据到cos | 181 | //同步数据到cos |
| 182 | - var_dump($this->upload_location); | ||
| 183 | - die(); | ||
| 184 | if($this->upload_location == 1){ | 182 | if($this->upload_location == 1){ |
| 185 | $cosService = new CosService(); | 183 | $cosService = new CosService(); |
| 186 | $cosService->uploadFile($files,$this->path,$fileName); | 184 | $cosService->uploadFile($files,$this->path,$fileName); |
| @@ -334,6 +332,8 @@ class FileController | @@ -334,6 +332,8 @@ class FileController | ||
| 334 | //根据项目上传标识区分上传到cos/本地 | 332 | //根据项目上传标识区分上传到cos/本地 |
| 335 | $projectModel = new Project(); | 333 | $projectModel = new Project(); |
| 336 | $project_info = $projectModel->read(['id'=>$this->cache['project_id']],['upload_location']); | 334 | $project_info = $projectModel->read(['id'=>$this->cache['project_id']],['upload_location']); |
| 335 | + var_dump($project_info); | ||
| 336 | + die(); | ||
| 337 | $this->upload_location = $project_info['upload_location']; | 337 | $this->upload_location = $project_info['upload_location']; |
| 338 | } | 338 | } |
| 339 | $this->path = $this->uploads['path_b'].'/'.$this->cache['project_id'].'/'.$this->file_type[$this->param['refer']].'/'.date('Y-m'); | 339 | $this->path = $this->uploads['path_b'].'/'.$this->cache['project_id'].'/'.$this->file_type[$this->param['refer']].'/'.date('Y-m'); |
-
请 注册 或 登录 后发表评论