|
@@ -2,6 +2,7 @@
|
|
|
|
|
|
namespace app\api\controller;
|
|
|
|
|
|
+use Alicode\Alisms;
|
|
|
use app\admin\model\Banner;
|
|
|
use app\common\controller\Api;
|
|
|
|
|
@@ -46,9 +47,19 @@ class Index extends Api
|
|
|
$this->success('积分规则',$data);
|
|
|
}
|
|
|
public function order_sms(){
|
|
|
- $MODEL = new Chuyutimedtask();
|
|
|
$data=['mobile'=>'15588500892','score'=>100];
|
|
|
- $MODEL->order_sms($data);
|
|
|
+ $TemplateCode = "SMS_262400702";
|
|
|
+ $phoneNumber = $data['mobile'];
|
|
|
+ $TemplateParam = json_encode(['code' => $data['score']]);
|
|
|
+ $sendSmsRequest = [
|
|
|
+ "TemplateCode" => $TemplateCode,
|
|
|
+ "phoneNumber" => $phoneNumber,
|
|
|
+ "TemplateParam" => $TemplateParam
|
|
|
+ ];
|
|
|
+
|
|
|
+ $res = Alisms::sendSmsCode($sendSmsRequest);
|
|
|
+ print_r($res);
|
|
|
+
|
|
|
}
|
|
|
|
|
|
}
|