切换导航条
此项目
正在载入...
登录
郭盛
/
areial
·
提交
转到一个项目
GitLab
转到仪表盘
项目
活动
文件
提交
管道
0
构建
0
图表
里程碑
问题
0
合并请求
0
成员
标记
维基
派生
网络
创建新的问题
下载为
邮件补丁
差异文件
浏览文件
作者
郭盛
5 years ago
提交
4411f7bd9229070258ffbc75f3bd71bd0b145651
1 个父辈
a4f66c7f
1 个管道 的构建
失败
耗费 6 秒
修改发短信
变更
2
构建
1
隐藏空白字符变更
内嵌
并排对比
正在显示
2 个修改的文件
包含
30 行增加
和
5 行删除
application/admin/controller/Iphone.php
public/api.html
application/admin/controller/Iphone.php
查看文件 @
4411f7b
...
...
@@ -5,6 +5,7 @@ namespace app\admin\controller;
use
app\api\controller\Pay
;
use
app\common\controller\Backend
;
use
think\Db
;
use
app\nsms\nsms
;
/**
* 苹果用户购买素材订单
...
...
@@ -141,8 +142,7 @@ class Iphone extends Backend
$content
=
"【仁甲看见SHOP】,感谢您购买仁甲看见SHOP素材。图片标题:
$pic[title],云盘地址:$pic[url]
"
;
//发送短信
$send
=
new
Pay
();
$send
->
sms
(
$mobile
,
$content
);
$this
->
sms
(
$mobile
,
$content
);
}
elseif
(
empty
(
$data
[
'pic_id'
])){
$video_id
=
unserialize
(
$data
[
'video_id'
]);
...
...
@@ -157,8 +157,7 @@ class Iphone extends Backend
$content
=
"【仁甲看见SHOP】,感谢您购买仁甲看见SHOP素材。视频标题:
$video[title],云盘地址:$video[eight_url]
"
;
}
//发送短信
$send
=
new
Pay
();
$send
->
sms
(
$mobile
,
$content
);
$this
->
sms
(
$mobile
,
$content
);
}
$update
=
$user_info
[
'money'
]
-
$data
[
'total'
];
Db
::
name
(
'user'
)
->
where
(
'id'
,
$user_info
[
'id'
])
->
update
([
'money'
=>
$update
]);
...
...
@@ -190,4 +189,30 @@ class Iphone extends Backend
$this
->
view
->
assign
(
"row"
,
$row
);
return
$this
->
view
->
fetch
();
}
//发送短信
public
function
sms
(
$mobile
,
$content
){
$note
=
array
(
'content'
=>
$content
,
//短信内容
'mobile'
=>
$mobile
,
//手机号码
'productid'
=>
'676767'
,
//模板id
'xh'
=>
''
//小号
);
$result
=
$this
->
send_sms
(
$note
);
return
$result
;
}
function
send_sms
(
$data
){
//todo 短信账号密码
// require_once EXTEND_PATH . 'nsms/nsms.php';
$url
=
"http://www.ztsms.cn/sendNSms.do"
;
$username
=
'hangpai'
;
$password
=
'Cxz307312'
;
$sendAPI
=
new
nsms
(
$url
,
$username
,
$password
);
$sendAPI
->
data
=
$data
;
/*初始化数据包*/
$return
=
$sendAPI
->
sendSMS
(
'POST'
);
return
$return
;
}
}
...
...
public/api.html
查看文件 @
4411f7b
...
...
@@ -7962,7 +7962,7 @@
<div
class=
"row mt0 footer"
>
<div
class=
"col-md-6"
align=
"left"
>
Generated on 2020-08-12 1
4:29:05
</div>
Generated on 2020-08-12 1
7:28:57
</div>
<div
class=
"col-md-6"
align=
"right"
>
<a
href=
"https://www.fastadmin.net"
target=
"_blank"
>
FastAdmin
</a>
</div>
...
...
请
注册
或
登录
后发表评论