Commit 9b0e4a9b by hcy001

1

parent a420f07e
...@@ -29,6 +29,7 @@ class HdController extends Controller ...@@ -29,6 +29,7 @@ class HdController extends Controller
$dompdf->setPaper('A4', 'portrait'); $dompdf->setPaper('A4', 'portrait');
$dompdf->setOptions($options); $dompdf->setOptions($options);
$dompdf->render(); $dompdf->render();
$dompdf->save(storage_path('app/public/pdf/date.pdf'));
return $dompdf->stream('44444.pdf'); return $dompdf->stream('44444.pdf');
} }
......
...@@ -7,6 +7,7 @@ use App\Model\InquiryItemsAssignModel; ...@@ -7,6 +7,7 @@ use App\Model\InquiryItemsAssignModel;
use App\Model\OplogModel; use App\Model\OplogModel;
use App\Model\UserModel; use App\Model\UserModel;
use DB; use DB;
use PDF;
// 销售/报价 单 // 销售/报价 单
class InquiryItemsReportModel extends Model class InquiryItemsReportModel extends Model
...@@ -18,11 +19,12 @@ class InquiryItemsReportModel extends Model ...@@ -18,11 +19,12 @@ class InquiryItemsReportModel extends Model
//生成报价单 //生成报价单
public function addOffer(){ public function addOffer(){
if (!Request::has("abnormal_id")){
return false; $path = 'pdf/销售报价单'.date("Y-m-d").'.pdf';
} PDF::loadHTML("<h1>gagagagag</h1>")
$input = Request::all(); ->setPaper('a4', 'portrait')
print_r($input); ->setWarnings(false)
->save($path);
die(); die();
$insertArr = []; //批量插入数组 $insertArr = []; //批量插入数组
......
...@@ -124,6 +124,12 @@ class InquiryModel extends Model ...@@ -124,6 +124,12 @@ class InquiryModel extends Model
} }
$v['quote_price'] = @$quote["quote_price"] > 0 ? $quote["quote_price"] : "------"; //存在报价 $v['quote_price'] = @$quote["quote_price"] > 0 ? $quote["quote_price"] : "------"; //存在报价
// 在Redis集合中检查是否有新的报价
$res = RedisDB::sIsMember('frq_quote_urge', $v['id']);
if ($res) {
$v['inquiry_sn'] = $v['inquiry_sn']."<span style='color:red;'>&nbsp;*</span>";
}
} }
$data = $list['data']; $data = $list['data'];
if (@$input["is_export"] == 1){ #如果是导出 if (@$input["is_export"] == 1){ #如果是导出
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment