6
0
Fork 0

调整导入

release
vine_liutk 2022-01-21 18:03:55 +08:00
parent e8ba0e860b
commit f68ac5039a
1 changed files with 2 additions and 1 deletions

View File

@ -15,7 +15,8 @@ class Import
$file_name = substr($url, strrpos($url, '/')+1);
$path = DIRECTORY_SEPARATOR.'import'.DIRECTORY_SEPARATOR.date('Y-m-d').DIRECTORY_SEPARATOR.'import'.$file_name;
Storage::put($path, file_get_contents($url));
// dd(str_replace(config('filesystems.disks.aliyun.domain'), config('filesystems.disks.aliyun.bucket').'.'.config('filesystems.disks.aliyun.endpoint'), $url));
Storage::put($path, file_get_contents(str_replace(config('filesystems.disks.aliyun.domain'), config('filesystems.disks.aliyun.bucket').'.'.config('filesystems.disks.aliyun.endpoint'), $url)));
$file = new File(storage_path('app'.$path));
return $this->readFile($file);
}