瀏覽代碼

update image size

xielin 5 年之前
父節點
當前提交
00a8b855b9
共有 1 個文件被更改,包括 2 次插入0 次删除
  1. 2 0
      app/Http/Controllers/UploadController.php

+ 2 - 0
app/Http/Controllers/UploadController.php

@@ -58,6 +58,8 @@ class UploadController extends Controller
                 $height = Image::make($filePath)->height();
                 //要保存的文件名 时间+扩展名
                 $filename = time() . '_' . uniqid() . '*' . $width . '_' . $height . '.' . $kuoname;
+                //todo 等待客户端更新后替换为下列规则
+                //$filename = time() . '_' . uniqid() . '.' . $kuoname . '?' . $width . '_' . $height;
             } else {
                 //要保存的文件名 时间+扩展名
                 $filename = time() . '_' . uniqid() . '.' . $kuoname;