|
...
|
...
|
@@ -110,7 +110,7 @@ class FileController |
|
|
|
* @time :2023/6/17 16:32
|
|
|
|
*/
|
|
|
|
public function single(&$files){
|
|
|
|
$hash = hash_file('md5', $files->getPathname());
|
|
|
|
$hash = hash_file('sha256', $files->getPathname());
|
|
|
|
$name = $files->getClientOriginalName();
|
|
|
|
//查看文件是否存在
|
|
|
|
$fileModel = new File();
|
|
...
|
...
|
@@ -277,7 +277,7 @@ class FileController |
|
|
|
foreach ($files as $file) {
|
|
|
|
$fileModel = new File();
|
|
|
|
$name = $file->getClientOriginalName();
|
|
|
|
$hash = hash_file('md5', $file->getPathname());
|
|
|
|
$hash = hash_file('sha256', $file->getPathname());
|
|
|
|
$param = ['hash'=>$hash,'refer'=>$this->param['refer'] ?? 0,'is_cos'=>(($this->upload_location == 0) ? 1 : 0)];
|
|
|
|
if(isset($this->cache['project_id']) && !empty($this->cache['project_id'])){
|
|
|
|
$param['project_id'] = $this->cache['project_id'];
|
...
|
...
|
|