Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
5
51business
Project
Project
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
方斌
51business
Commits
a8a6105b
Commit
a8a6105b
authored
Jun 05, 2020
by
任国军
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add notify log
parent
309287ad
Pipeline
#24557
passed with stage
in 4 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
wechat.js
app/controller/course/v5/wechat.js
+1
-1
course_v5.js
app/router/course_v5.js
+2
-2
No files found.
app/controller/course/v5/wechat.js
View file @
a8a6105b
...
@@ -93,7 +93,6 @@ class WechatController extends Controller {
...
@@ -93,7 +93,6 @@ class WechatController extends Controller {
xmlData
+=
'<return_code><![CDATA[SUCCESS]]></return_code>'
;
xmlData
+=
'<return_code><![CDATA[SUCCESS]]></return_code>'
;
xmlData
+=
'<return_msg><![CDATA[OK]]></return_msg>'
;
xmlData
+=
'<return_msg><![CDATA[OK]]></return_msg>'
;
xmlData
+=
'</xml>'
;
xmlData
+=
'</xml>'
;
ctx
.
body
=
xmlData
;
ctx
.
logger
.
info
(
'notify_headers: '
+
JSON
.
stringify
(
ctx
.
request
.
header
));
ctx
.
logger
.
info
(
'notify_headers: '
+
JSON
.
stringify
(
ctx
.
request
.
header
));
...
@@ -127,6 +126,7 @@ class WechatController extends Controller {
...
@@ -127,6 +126,7 @@ class WechatController extends Controller {
}
}
ctx
.
set
(
'Content-Type'
,
'text/xml'
);
ctx
.
set
(
'Content-Type'
,
'text/xml'
);
ctx
.
body
=
xmlData
;
return
ctx
.
body
;
return
ctx
.
body
;
}
}
}
}
...
...
app/router/course_v5.js
View file @
a8a6105b
...
@@ -4,7 +4,7 @@ module.exports = app => {
...
@@ -4,7 +4,7 @@ module.exports = app => {
const
router
=
app
.
router
.
namespace
(
app
.
config
.
projectRootPath
+
'/course/v5'
);
const
router
=
app
.
router
.
namespace
(
app
.
config
.
projectRootPath
+
'/course/v5'
);
// const miniAuth = app.middleware.miniAuthV5();// 因为不跟现有的用户中心系统,所以使用单独的登录中间件
// const miniAuth = app.middleware.miniAuthV5();// 因为不跟现有的用户中心系统,所以使用单独的登录中间件
const
auth
=
app
.
middleware
.
verifyAuth
;
const
auth
=
app
.
middleware
.
verifyAuth
;
const
xmlparse
=
app
.
middleware
.
xmlparse
();
//
const xmlparse = app.middleware.xmlparse();
router
.
post
(
'third'
,
'/verification_code'
,
'course.v5.user.sendVerificationCode'
);
// 发送验证码
router
.
post
(
'third'
,
'/verification_code'
,
'course.v5.user.sendVerificationCode'
);
// 发送验证码
router
.
post
(
'third'
,
'/login/phone'
,
'course.v5.user.loginByPhone'
);
// 手机号登录
router
.
post
(
'third'
,
'/login/phone'
,
'course.v5.user.loginByPhone'
);
// 手机号登录
...
@@ -26,7 +26,7 @@ module.exports = app => {
...
@@ -26,7 +26,7 @@ module.exports = app => {
router
.
get
(
'third'
,
'/wechat/callbackAction'
,
'course.v5.wechat.check'
);
router
.
get
(
'third'
,
'/wechat/callbackAction'
,
'course.v5.wechat.check'
);
router
.
post
(
'third'
,
'/wechat/callbackAction'
,
'course.v5.wechat.callbackAction'
);
router
.
post
(
'third'
,
'/wechat/callbackAction'
,
'course.v5.wechat.callbackAction'
);
router
.
post
(
'third'
,
'/wechat/test'
,
'course.v5.wechat.test'
);
router
.
post
(
'third'
,
'/wechat/test'
,
'course.v5.wechat.test'
);
router
.
post
(
'third'
,
'/wechat/pay/notify'
,
xmlparse
,
'course.v5.wechat.payNotify'
);
router
.
post
(
'third'
,
'/wechat/pay/notify'
,
'course.v5.wechat.payNotify'
);
router
.
post
(
'third'
,
'/questionnaire'
,
auth
({
is_force
:
1
}),
'course.v5.option.addQuestionnaire'
);
// 填写问卷
router
.
post
(
'third'
,
'/questionnaire'
,
auth
({
is_force
:
1
}),
'course.v5.option.addQuestionnaire'
);
// 填写问卷
router
.
get
(
'third'
,
'/questionnaire'
,
'course.v5.option.getQuestionnaire'
);
// 获取问卷
router
.
get
(
'third'
,
'/questionnaire'
,
'course.v5.option.getQuestionnaire'
);
// 获取问卷
router
.
post
(
'third'
,
'/channel/unlimited_code'
,
'course.v5.option.addUnlimitedCodeByChannel'
);
// 保存渠道小程序码
router
.
post
(
'third'
,
'/channel/unlimited_code'
,
'course.v5.option.addUnlimitedCodeByChannel'
);
// 保存渠道小程序码
...
...
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