|
|
@@ -317,11 +317,12 @@ class Controller extends BaseController
|
|
|
$directory = date('Ymd');
|
|
|
$path = '/assets/images/qrcode/' . $directory . '/';
|
|
|
if (!file_exists(public_path($path))) { //检查是否有该文件夹,如果没有就创建,并给予最高权限
|
|
|
- mkdir(public_path($path), 0700, true);
|
|
|
+ mkdir(public_path($path), 0755, true);
|
|
|
}
|
|
|
|
|
|
$fileName = makeRandStr(18, true) . ".{$type}";
|
|
|
if (file_put_contents(public_path($path . $fileName), base64_decode(str_replace($result[1], '', $base64_image_content)))) {
|
|
|
+ chmod(public_path($path . $fileName), 0744);
|
|
|
return $path . $fileName;
|
|
|
} else {
|
|
|
return '';
|