|
@@ -51,6 +51,7 @@ class CheckTicket extends Command
|
|
|
if(!$info->isEmpty()){
|
|
|
$companyInfo = CompanyInfo::where(["companyNo"=>$info->inv_out,"is_del"=>0,"status"=>1])->findOrEmpty();
|
|
|
$isTicket = $companyInfo['out_ticket']??0;
|
|
|
+ $ticket['is_comon'] = $info->is_comon;
|
|
|
$this->taxCheck($ticket);
|
|
|
}
|
|
|
}
|
|
@@ -85,9 +86,9 @@ class CheckTicket extends Command
|
|
|
}
|
|
|
protected function changeFiled($data,$info){
|
|
|
$item = $this->itemFiled($data['detailList']);
|
|
|
- $info = (new InvoiceTicket)->where(['invNo'=>$info['invNo'],'type'=>0,'status'=>0,'is_del'=>0])->findOrEmpty();
|
|
|
- if(!$info->isEmpty()){
|
|
|
- $info->save(['inv_total'=>$data['jshj'],
|
|
|
+ $tick = (new InvoiceTicket)->where(['invNo'=>$info['invNo'],'type'=>0,'status'=>0,'is_del'=>0])->findOrEmpty();
|
|
|
+ if(!$tick->isEmpty()){
|
|
|
+ $tick->save(['inv_total'=>$data['jshj'],
|
|
|
'inv_subtotal'=>$data['fpje'],
|
|
|
'buyer_id'=>$data['gmfsbh'],
|
|
|
'buyer_title'=>$data['gmfmc'],
|
|
@@ -109,6 +110,7 @@ class CheckTicket extends Command
|
|
|
}
|
|
|
InvoicePool::where(['invNo'=>$info['invNo']])->save(["status"=>4,"updatetime"=>$this->dateTime]);
|
|
|
\app\admin\model\Assoc::subOrder($info['invNo']);
|
|
|
+ if($info->is_comon==1)event('comonOrder',['invNo'=>$info['invNo'],'type'=>'inv']);
|
|
|
}
|
|
|
protected function itemFiled($detail){
|
|
|
|