酒吧房类型修改
This commit is contained in:
@@ -20,7 +20,7 @@ class Gift extends Model
|
||||
1 => '普通礼物',
|
||||
2 => '盲盒礼物',
|
||||
3 => '礼包礼物',
|
||||
4 => '酒吧房礼物'
|
||||
6 => '酒吧房礼物'
|
||||
];
|
||||
//送礼流水来源:1聊天送礼物 2房间语聊送礼 3直播送礼 4动态打赏
|
||||
public $GiveGiftFromStr = [
|
||||
|
||||
@@ -790,7 +790,10 @@ class GiveGift extends Model
|
||||
// 优化:基于剩余数量的加权随机选择
|
||||
$gift_bag_details = db::name("vs_gift_bag_detail")->where($where)->select();
|
||||
if (empty($gift_bag_details)) {
|
||||
return ['code' => 0, 'msg' => '当前盲盒无可用礼物', 'data' => []];
|
||||
db::name("vs_gift_bag")->where('id',$gift_bag_id)->setInc('periods');
|
||||
db::name("vs_gift_bag_detail")->where('gift_bag_id',$gift_bag_id)->update(['remaining_number'=>db::raw('quantity')]);
|
||||
$gift_bag_details = db::name("vs_gift_bag_detail")->where($where)->select();
|
||||
// return ['code' => 0, 'msg' => '当前盲盒无可用礼物', 'data' => []];
|
||||
}
|
||||
// 实现加权随机算法:剩余数量越多,被抽中的概率越大
|
||||
$total_remaining = 0;
|
||||
|
||||
@@ -158,7 +158,7 @@ class PerformPerSecond
|
||||
continue;
|
||||
}
|
||||
}
|
||||
if(in_array($value['yun_order_status'],[261,5077])){
|
||||
if(in_array($value['yun_order_status'],[261,5077,255])){
|
||||
continue;
|
||||
}
|
||||
echo "提现订单查询:".$value['order_sn']."\n";
|
||||
@@ -166,6 +166,12 @@ class PerformPerSecond
|
||||
$result = $yun_pay->queryOrder($value['type']);
|
||||
if($result['code'] == 1){
|
||||
if($result['data']['code']==0){
|
||||
if($value['type']==3){
|
||||
if($result['data']['msg']=="已受理"){
|
||||
print_r($result);
|
||||
continue;
|
||||
}
|
||||
}
|
||||
db::name('vs_user_withdrawal')->where('order_sn',$value['order_sn'])->update([
|
||||
'status' => 6,
|
||||
'pay_time' => time(),
|
||||
@@ -186,7 +192,7 @@ class PerformPerSecond
|
||||
'received_tax_amount' => $result['data']['received_tax_amount'] ?? 0,
|
||||
]);
|
||||
// if(in_array($result['data']['code'],[5077,261]) && $value['yun_order_status'] == null){
|
||||
if(in_array($result['data']['code'],[5077,261]) && !in_array($value['yun_order_status'],[5077,261])){
|
||||
if(in_array($result['data']['code'],[5077,261,255]) && !in_array($value['yun_order_status'],[5077,261,255])){
|
||||
// if($result['data']['code']==5077 && $value['yun_order_status'] == null){
|
||||
//该支付宝账户不存在或未开通手机号转账功能。如有疑问,请收款用户联系支付宝客服咨询。
|
||||
//退还金币
|
||||
|
||||
Reference in New Issue
Block a user