Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
8
8timerapiv200
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
8timerv2
8timerapiv200
Commits
f2a88eeb
Commit
f2a88eeb
authored
Apr 28, 2020
by
邓实川
Committed by
chenzg
Jul 05, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
优化
parent
1fa4baa3
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
3 deletions
+7
-3
src/main/java/cn/timer/api/controller/LoginController.java
+5
-3
src/main/java/cn/timer/api/utils/aliyun/AliyunSMS.java
+2
-0
No files found.
src/main/java/cn/timer/api/controller/LoginController.java
View file @
f2a88eeb
...
...
@@ -150,6 +150,7 @@ public class LoginController {
remainder
=
quantity
.
getRemainder
();
date
=
quantity
.
getExpireDate
();
}
if
(
entRegisterDto
.
getTc
()
!=
4
)
{
//如果不是注册,则判断套餐余额
if
(
quantity
==
null
||
remainder
==
null
||
remainder
<=
0
)
{
// 判断充了钱没
return
ResultUtil
.
error
(
"请充值后使用短信功能!"
);
}
...
...
@@ -157,6 +158,7 @@ public class LoginController {
System
.
err
.
println
(
"企业 "
+
orgCode
+
" :短信套餐已过期"
);
return
ResultUtil
.
error
(
"短信套餐已到期!"
);
}
}
// 6位随机数验证码
try
{
...
...
@@ -179,9 +181,9 @@ public class LoginController {
.
getJSONObject
(
"SmsSendDetailDTOs"
).
getJSONArray
(
"SmsSendDetailDTO"
).
get
(
0
);
String
phoneNum
=
jsonObject
.
getString
(
"PhoneNum"
);
String
content
=
jsonObject
.
getString
(
"Content"
);
//
String templateCode = jsonObject.getString("TemplateCode");
//
String sendStatus = jsonObject.getString("SendStatus");
//
String sendDate = jsonObject.getString("SendDate");
//
String templateCode = jsonObject.getString("TemplateCode");
//
String sendStatus = jsonObject.getString("SendStatus");
//
String sendDate = jsonObject.getString("SendDate");
QyzxSms
qyzxSms
=
new
QyzxSms
();
qyzxSms
.
setContent
(
content
);
...
...
src/main/java/cn/timer/api/utils/aliyun/AliyunSMS.java
View file @
f2a88eeb
...
...
@@ -78,6 +78,7 @@ public class AliyunSMS {
Date
date
=
quantity
.
getExpireDate
();
String
orderNo
=
quantity
.
getOrderNo
();
if
(
templateCode
!=
4
)
{
if
(
quantity
==
null
||
remainder
==
null
||
remainder
<=
0
)
{
System
.
err
.
println
(
"企业 "
+
orgCode
+
" :套餐余额不足,请充钱"
);
return
null
;
...
...
@@ -86,6 +87,7 @@ public class AliyunSMS {
System
.
err
.
println
(
"企业 "
+
orgCode
+
" :短信套餐已过期"
);
return
null
;
}
}
QyzxUseRecord
qyzxUseRecord
=
new
QyzxUseRecord
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment