send_code($mobile, sms_helper::register,false); } public function testEvidence(){ // $type = 'balance_warning'; // $ret = QueueClient::push('sendSMS', ['mobile'=>17801048874,'type'=>$type,'datas' => [date("m月d日H时") , 500]]); // $type = 'evidence'; // $ret = QueueClient::push('sendSMS', ['mobile'=>17801048874,'type'=>$type,'datas' => [date("m月d日H时") , 'yezi' , 500]]); $merchants = Model('merchant')->getMerchantList([],'','','merchant.*,member.available_predeposit'); foreach ($merchants as $merchant){ if(($merchant['available_predeposit'] < $merchant['alarm_amount'] && !empty($merchant['contact_phone']))|| $merchant['available_predeposit'] < 10000) { QueueClient::push('sendSMS', ['mobile'=>$merchant['contact_phone'],'type'=>'balance_warning','datas' => [date("m月d日H时") , $merchant['available_predeposit']]]); } } } public function testInvitee() { $sms = new Sms(); $mobile = '13911129867'; //$params[Sms::tpl_reg_user_bonus] = ['amount' => 1.0]; //$params[Sms::tpl_reg_inviter] = ['user_name' => '张莉','level' => 1,'amount' => 5]; $params[Sms::tpl_reg_invitee] = ['user_name' => '张莉','inviter_name' => "桑贵苏",'level' => 3,'amount' => 2]; $params[Sms::tpl_order_complete_inviter] = ['level' => 1,'name' => '桑贵苏','amount' => 2]; $params[Sms::tpl_order_complete_invitee] = ['name' => '桑贵苏','amount' => 2]; foreach ($params as $sms_type => $sms_param) { $status = $sms->send_oper($mobile,$sms_type,$sms_param); } } public function testOrderSms() { $pay_sn = 570510757490858481; $order = new async\order($pay_sn); $logistics_no = 10000; $logistics_company = "顺丰"; $order->onSended($logistics_no,$logistics_company); echo 0; } }