上传组件记录extparam参数

pull/98/MERGE
pppscn 2019-02-16 14:40:14 +08:00 committed by Karson
parent 3763b0d69e
commit ac312ef41e
1 changed files with 2 additions and 0 deletions

View File

@ -54,6 +54,7 @@ class Ajax extends Backend
//判断是否已经存在附件 //判断是否已经存在附件
$sha1 = $file->hash(); $sha1 = $file->hash();
$extparam = $this->request->post();
$upload = Config::get('upload'); $upload = Config::get('upload');
@ -118,6 +119,7 @@ class Ajax extends Backend
'uploadtime' => time(), 'uploadtime' => time(),
'storage' => 'local', 'storage' => 'local',
'sha1' => $sha1, 'sha1' => $sha1,
'extparam' => json_encode($extparam),
); );
$attachment = model("attachment"); $attachment = model("attachment");
$attachment->data(array_filter($params)); $attachment->data(array_filter($params));