Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Z
zjxcxServer
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
node_server
zjxcxServer
Commits
edfdd05f
Commit
edfdd05f
authored
May 08, 2023
by
lixinming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
短信
parent
6165a062
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
2 deletions
+15
-2
systemTask.ts
src/biz/systemTask.ts
+11
-0
main.ts
src/main.ts
+4
-2
No files found.
src/biz/systemTask.ts
View file @
edfdd05f
...
...
@@ -42,6 +42,17 @@ async function fuHuaQiTask() {
}
export
function
initSMSTask
()
{
smsTask
();
setInterval
(
async
function
()
{
await
smsTask
();
},
3600
*
1000
);
console
.
log
(
`systemTask init success`
);
}
/**
* 短信任务 每月倒数第七天发送
*/
...
...
src/main.ts
View file @
edfdd05f
import
{
initSMS
}
from
"./biz/sms"
;
import
{
initSystemTask
,
sms
Task
}
from
"./biz/systemTask"
;
import
{
initSystemTask
,
initSMS
Task
}
from
"./biz/systemTask"
;
import
{
initConfig
,
systemConfig
}
from
"./config/serverConfig"
;
import
{
initDB
}
from
"./db/mongo/dbInit"
;
import
{
httpServer
}
from
"./net/http_server"
;
...
...
@@ -15,8 +15,10 @@ async function lanuch() {
await
initBasicData
();
/**初始化系统任务 */
await
initSystemTask
();
/**
腾讯云短信
*/
/**
初始化腾讯云短信配置
*/
await
initSMS
();
/**初始化短信任务 */
await
initSMSTask
();
/**创建http服务 */
httpServer
.
createServer
(
systemConfig
.
port
);
...
...
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