提交 01d841e0 authored 作者: chengye's avatar chengye

修复账单如果没有附件则现实错误页面的问题

上级 14ae20b0
...@@ -118,7 +118,7 @@ class EmInvoice extends Base ...@@ -118,7 +118,7 @@ class EmInvoice extends Base
//查询抄表信息 //查询抄表信息
$uModel = Useage::get(['useage_id'=>$eiu->useage_id]); $uModel = Useage::get(['useage_id'=>$eiu->useage_id]);
if($uModel->cert_id != ''){ if($uModel && $uModel->cert_id != ''){
$useage = Useage::with('photo')->get(['useage_id'=>$eiu->useage_id]); $useage = Useage::with('photo')->get(['useage_id'=>$eiu->useage_id]);
if($useage->photo_id) { if($useage->photo_id) {
$receipt = Receipt::get(['id'=>$useage->photo_id]); $receipt = Receipt::get(['id'=>$useage->photo_id]);
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论