更新
This commit is contained in:
parent
efe6cc7e6d
commit
01c7ff2ddf
@ -111,7 +111,7 @@ class StoreMicro extends BaseController
|
||||
$find['extend'] = [];
|
||||
$find['param_temp_id'] = [];
|
||||
$find['mer_labels'] = [];
|
||||
$find['delivery_way'] = [0 => "2"];
|
||||
$find['delivery_way'] = [0 => "2",1=>'1'];
|
||||
$find["guarantee_template_id"] = "";
|
||||
$find['product_type'] = $product_type;
|
||||
$find['mer_cate_id'] = [0 => 0];
|
||||
|
@ -12,7 +12,9 @@ use app\common\repositories\system\merchant\MerchantRepository;
|
||||
use crmeb\utils\DingTalk;
|
||||
use think\facade\Db;
|
||||
use think\facade\Log;
|
||||
|
||||
/**
|
||||
* 支付后逻辑
|
||||
*/
|
||||
class paySuccessOrder
|
||||
{
|
||||
|
||||
@ -38,6 +40,24 @@ class paySuccessOrder
|
||||
if (!$merchant || $merchant['street_id'] == 0) {
|
||||
throw new \Exception('商户地址不存在', 200);
|
||||
}
|
||||
if($merchant['type_id']==13){
|
||||
$codes=explode(',',$event['order']['user_address_code']);
|
||||
$count_code=count($codes);
|
||||
if($count_code>4){
|
||||
$merchant_two= Db::name('merchant')->where('street_id',$count_code[3])->where('type_id',17)->where('category_id',$merchant['category_id'])->find();
|
||||
if($merchant_two){
|
||||
$datas=[
|
||||
'master_mer_id'=>$merchant['mer_id'],
|
||||
'mer_id'=>$merchant_two['mer_id'],
|
||||
'order_id'=>$event['order']['order_id'],
|
||||
'status'=>1
|
||||
];
|
||||
Db::name('store_order_behalf')->insert($datas);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
$this->streetId = $merchant['street_id'];
|
||||
|
||||
$commission_rate = ($event['order']['commission_rate'] / 100);
|
||||
|
Loading…
x
Reference in New Issue
Block a user