Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
X
xuexin_api
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
data_server
xuexin_api
Commits
ea615704
Commit
ea615704
authored
May 10, 2019
by
何娜
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
学信API url优化
parent
91d022c5
Pipeline
#7353
failed with stage
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
3 deletions
+4
-3
order.js
app/controller/order.js
+1
-1
router.js
app/router.js
+1
-1
notifyUrl.js
app/schedule/notifyUrl.js
+2
-1
No files found.
app/controller/order.js
View file @
ea615704
...
...
@@ -58,7 +58,7 @@ class OrderController extends Controller {
async
fetchOrderId
()
{
const
{
ctx
,
service
}
=
this
;
try
{
const
{
appKey
}
=
ctx
.
params
;
const
{
appKey
}
=
ctx
.
query
;
// const appKeyInfo = await service.partner.fetchInfo(appKey);
// ctx.logger.info(appKey, ',appKeyInfo,', appKeyInfo);
// if (!(appKeyInfo && appKeyInfo.valid === true && appKeyInfo.enableIt === true)) {
...
...
app/router.js
View file @
ea615704
...
...
@@ -8,7 +8,7 @@ module.exports = app => {
const
chsiRouter
=
router
.
namespace
(
app
.
config
.
projectRootPath
);
chsiRouter
.
get
(
'/get
orderSn/:appKey
'
,
controller
.
order
.
fetchOrderId
);
// 合作方获取订单号
chsiRouter
.
get
(
'/get
OrderSn
'
,
controller
.
order
.
fetchOrderId
);
// 合作方获取订单号
// taxRouter.post('/getCode', controller.task.fetchCapture);// 获取验证码
...
...
app/schedule/notifyUrl.js
View file @
ea615704
...
...
@@ -11,6 +11,7 @@ module.exports = {
try
{
const
{
host
,
customerUrl
}
=
ctx
.
app
.
config
.
signatureAPI
;
const
notifyMap
=
new
Map
();
ctx
.
logger
.
info
(
'host'
,
host
,
'customerUrl'
,
customerUrl
)
const
ret
=
await
ctx
.
curl
(
host
+
customerUrl
,
{
charset
:
'utf-8'
,
timeout
:
[
'30s'
,
'30s'
],
...
...
@@ -24,8 +25,8 @@ module.exports = {
notifyMap
.
set
(
customer
.
appKey
,
{
notifyUrl
:
customer
.
callBackUrl
});
}
});
ctx
.
app
.
notifyMap
=
notifyMap
;
}
ctx
.
app
.
notifyMap
=
notifyMap
;
}
catch
(
e
)
{
ctx
.
logger
.
error
(
'【schedule/notifyUrlTask】catch error:'
,
JSON
.
stringify
(
e
));
}
...
...
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