提交 b1b6a8a1 authored 作者: chengye's avatar chengye

修复不能上传电表照片bug

上级 87e7f693
差异被折叠。
...@@ -47,15 +47,13 @@ class Upload extends Base ...@@ -47,15 +47,13 @@ class Upload extends Base
$receipt->suffix = $info->getExtension(); $receipt->suffix = $info->getExtension();
$receipt->size =$info->getSize(); $receipt->size =$info->getSize();
if($receipt->save()){ if($receipt->save()){
return ['aaa']; return ['id'=>$receipt->id,'src'=>ltrim($receipt->src,'.')];
//return ['id'=>$receipt->id,'src'=>ltrim($receipt->src,'.')];
} else { } else {
return ['cccc']; return ['faild'];
} }
} else { } else {
// 上传失败获取错误信息 // 上传失败获取错误信息
return ['bbb']; return $this->file->getError();
// return $this->file->getError();
} }
} }
} }
\ No newline at end of file
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论