zz há 6 anos atrás
pai
commit
cf82c1dde2
1 ficheiros alterados com 0 adições e 58 exclusões
  1. 0 58
      app/Console/Commands/BookTest.php

+ 0 - 58
app/Console/Commands/BookTest.php

@@ -73,7 +73,6 @@ class BookTest extends Command
         //$this->sendOrderStats105();
         //$this->you2();
         //$this->transfromUserOrder();
-        $this->successPayPushMsg();
     }
 
 
@@ -576,61 +575,4 @@ class BookTest extends Command
 
         }
     }
-
-
-    protected function successPayPushMsg()
-    {
-        try {
-            $uid = 10008;
-            $order_id = 10910163;
-            $product_info = ProductService::getProductSingle(2);
-            $force_sub_info = DB::table('force_subscribe_users')->where('uid',$uid)->where('is_subscribed', 1)->get();
-            $data = UserService::getById($uid);
-            if (!in_array($data->distribution_channel_id, [5, 123])) {
-                //return false;
-            }
-            if ($force_sub_info) {
-                //$content_format = "您好,你已经成功充值\r\n\r\n会员:%s\r\n会员ID:%s\r\n充值金额:%s\r\n充值状态:充值成功\r\n如有疑问,请点击用户中心-联系客服\r\n\r\n><a href='%s'>点击继续阅读上次阅读</a>";
-                if (SubstituteOrderService::getByOrderId($order_id)) {
-                    $content_format = "代充值客服消息:\r\n\r\n你好,您的好友为你代付成功\r\n会员:%s\r\n会员ID:%s\r\n代付金额:%s\r\n充值状态:充值成功\r\n如有疑问,请点击用户中心-联系客服\r\n\r\n><a href='%s'>点击继续阅读上次阅读</a>";
-                } else {
-                    $content_format = "您好,你已经成功充值\r\n\r\n会员:%s\r\n会员ID:%s\r\n充值金额:%s\r\n充值状态:充值成功\r\n如有疑问,请点击用户中心-联系客服\r\n\r\n><a href='%s'>点击继续阅读上次阅读</a>";
-                }
-                if ($product_info->type == 'YEAR_ORDER') {
-                    $money_text = $product_info->price . '元(尊贵的年费VIP会员)';
-                } elseif ($product_info->type == 'TICKET_RECHARGE') {
-                    if ($product_info->given) {
-                        $money_text = $product_info->price . '元(' . ($product_info->price * 100) . '书币+赠送' . $product_info->given . '书币)';
-                    } else {
-                        $money_text = $product_info->price . '元(' . ($product_info->price * 100) . '书币)';
-                    }
-                } else {
-                    $money_text = '未知';
-                }
-                $delay = 0;
-                $url = env('PROTOCOL') . '://site' . encodeDistributionChannelId($data->distribution_channel_id) . '.' . env('CUSTOM_HOST') . '.com/continue';;
-                $content = sprintf($content_format, $data->nickname ? $data->nickname : '匿名', $uid, $money_text, $url);
-                foreach ($force_sub_info as $item){
-                    $res['openid'] = $item->openid;
-                    $res['appid'] = $item->appid;
-                    $res['content'] = $content;
-                    $res['type'] = 'one_task';
-                    $res['send_time'] = date("Y-m-d H:i:s");
-                    $res['task_id'] = md5('pay_success_push');
-                    $send_data = array(
-                        'send_time' => date("Y-m-d H:i:s"),
-                        'data' => $res
-                    );
-                    Log::info($send_data);
-                    dispatch((new SendTexts($send_data))->onConnection('rabbitmq')->delay($delay)->onQueue('send_texts_list'));
-                }
-
-            }
-        } catch (\Exception $e) {
-            Log::info('pay_success_push error');
-            Log::info($e);
-        }
-        return true;
-    }
-
 }