作者 张关杰

Merge branch 'develop' of http://47.244.231.31:8099/zhl/globalso-v6 into bate

@@ -277,7 +277,6 @@ class ImageController extends Controller @@ -277,7 +277,6 @@ class ImageController extends Controller
277 $data[] = $this->responseData($image_hash['path']); 277 $data[] = $this->responseData($image_hash['path']);
278 continue; 278 continue;
279 } 279 }
280 - $url = $this->config['root'].$this->path;  
281 $image_type = $file->getClientOriginalExtension(); 280 $image_type = $file->getClientOriginalExtension();
282 $fileName = uniqid().rand(10000,99999).'.'.$image_type; 281 $fileName = uniqid().rand(10000,99999).'.'.$image_type;
283 //同步数据到cos 282 //同步数据到cos
@@ -42,7 +42,7 @@ class AmazonS3Service @@ -42,7 +42,7 @@ class AmazonS3Service
42 */ 42 */
43 public function uploadFiles(&$files, $s3Key,$filename) 43 public function uploadFiles(&$files, $s3Key,$filename)
44 { 44 {
45 - $key = $s3Key.'/'.$filename; 45 + $key = ltrim($s3Key.'/'.$filename,'/');
46 $body = $files->getRealPath(); 46 $body = $files->getRealPath();
47 try { 47 try {
48 $result = $this->s3->putObject([ 48 $result = $this->s3->putObject([