切换导航条
此项目
正在载入...
登录
allied-creation
/
performance
·
提交
转到一个项目
GitLab
转到群组
项目
活动
文件
提交
管道
0
构建
0
图表
里程碑
问题
0
合并请求
0
成员
标记
维基
派生
网络
创建新的问题
下载为
邮件补丁
差异文件
浏览文件
作者
tangxvhui
2 years ago
提交
8939578198d27340d8dee2d9ae869751fc6e0d4b
1 个父辈
e44fec74
调整短信的发送时间
隐藏空白字符变更
内嵌
并排对比
正在显示
1 个修改的文件
包含
3 行增加
和
3 行删除
pkg/application/notify/sms_confirm_evaluation_score.go
pkg/application/notify/sms_confirm_evaluation_score.go
查看文件 @
8939578
...
...
@@ -19,6 +19,8 @@ func (notices notifyConfirmEvaluationScore) from() string {
}
func
(
notices
notifyConfirmEvaluationScore
)
makeNotify
(
param
*
domain
.
SummaryEvaluation
)
*
domain
.
LogSms
{
nextTime
:=
time
.
Now
()
.
Add
(
6
*
time
.
Hour
)
executeAt
:=
notices
.
getTimeExecuteAt
(
nextTime
)
newSms
:=
domain
.
LogSms
{
Id
:
0
,
Phone
:
param
.
TargetUser
.
Account
,
...
...
@@ -32,7 +34,7 @@ func (notices notifyConfirmEvaluationScore) makeNotify(param *domain.SummaryEval
Status
:
domain
.
SmsWait
,
From
:
notices
.
from
(),
Index
:
param
.
Id
,
ExecuteAt
:
notices
.
getTimeExecuteAt
(
time
.
Now
())
,
ExecuteAt
:
executeAt
,
CreatedAt
:
time
.
Now
(),
}
return
&
newSms
...
...
@@ -75,8 +77,6 @@ func (notices notifyConfirmEvaluationScore) ifSend(index int) (bool, error) {
//计算下一条短信
smsMessage
:=
notices
.
makeNotify
(
summaryEvaluationData
)
nextTime
:=
nowTime
.
Add
(
6
*
time
.
Hour
)
smsMessage
.
ExecuteAt
=
notices
.
getTimeExecuteAt
(
nextTime
)
logSmsRepo
:=
factory
.
CreateLogSmsRepository
(
map
[
string
]
interface
{}{
"transactionContext"
:
transactionContext
})
err
=
logSmsRepo
.
Save
(
smsMessage
)
if
err
!=
nil
{
...
...
请
注册
或
登录
后发表评论