update 用户邀请数据
This commit is contained in:
parent
363ec01a24
commit
21030d98dc
|
@ -121,6 +121,7 @@ class UserLogic extends BaseLogic
|
||||||
'register_num' => $params['register_num'],
|
'register_num' => $params['register_num'],
|
||||||
'merchant_num' => $params['merchant_num'],
|
'merchant_num' => $params['merchant_num'],
|
||||||
'trade_amount' => $params['trade_amount'],
|
'trade_amount' => $params['trade_amount'],
|
||||||
|
'update_time' => time()
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -95,10 +95,15 @@ class UserLogic extends BaseLogic
|
||||||
$name=DictData::where('id',$data['company']['company_type'])->value('name');
|
$name=DictData::where('id',$data['company']['company_type'])->value('name');
|
||||||
$data['company']['company_type_name']=$name;
|
$data['company']['company_type_name']=$name;
|
||||||
}
|
}
|
||||||
$inviteUserStatistics = ShopRequestLogic::getInviteUserInfo(['promotion_code' => $data['invite_code']]);
|
if (date('Y-m-d', strtotime($data['update_time'])) == date('Y-m-d', time())) {
|
||||||
$data['register_num'] = $inviteUserStatistics['data']['user_count'];
|
|
||||||
$data['merchant_num'] = $inviteUserStatistics['data']['merchant_count'];
|
} else {
|
||||||
$data['trade_amount'] = $inviteUserStatistics['data']['trade_amount'];
|
$inviteUserStatistics = ShopRequestLogic::getInviteUserInfo(['promotion_code' => $data['invite_code']]);
|
||||||
|
$data['register_num'] = $inviteUserStatistics['data']['user_count'];
|
||||||
|
$data['merchant_num'] = $inviteUserStatistics['data']['merchant_count'];
|
||||||
|
$data['trade_amount'] = $inviteUserStatistics['data']['trade_amount'];
|
||||||
|
}
|
||||||
|
|
||||||
return $data ;
|
return $data ;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue