Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Z
zhichan
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
蒋勇
zhichan
Commits
90b3c112
Commit
90b3c112
authored
Mar 20, 2020
by
王栋源
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wdy
parent
79247f95
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
41 additions
and
11 deletions
+41
-11
igirl-channel-gateway/app/base/service/impl/utilsSve/utilsNeedSve.js
+40
-10
igirl-channel-gateway/app/config/routes/api.js
+1
-1
No files found.
igirl-channel-gateway/app/base/service/impl/utilsSve/utilsNeedSve.js
View file @
90b3c112
...
@@ -150,37 +150,67 @@ class UtilsNeedSve extends AppServiceBase {
...
@@ -150,37 +150,67 @@ class UtilsNeedSve extends AppServiceBase {
};
};
}
}
var
userpin
=
""
;
var
userpin
=
""
;
if
(
pobj
.
mobil
e
)
{
if
(
pobj
.
phon
e
)
{
//获取用户userpin
//获取用户userpin
var
userparam
=
{
var
userparam
=
{
actionType
:
"getLoginByUserName"
,
actionType
:
"getLoginByUserName"
,
actionBody
:
{
actionBody
:
{
"channelUserId"
:
pobj
.
mobil
e
,
"channelUserId"
:
pobj
.
phon
e
,
"mobile"
:
pobj
.
mobil
e
,
"mobile"
:
pobj
.
phon
e
,
"userName"
:
pobj
.
mobil
e
"userName"
:
pobj
.
phon
e
}
}
};
};
var
self
=
this
;
// pobj.actionBody.channelUserId = pobj.mobile;//渠道用户id,没有则用手机号
// pobj.actionBody.channelUserId = pobj.mobile;//渠道用户id,没有则用手机号
// pobj.actionBody.mobile = pobj.mobile;//用户手机号
// pobj.actionBody.mobile = pobj.mobile;//用户手机号
var
url
=
settings
.
centerChannelUrl
()
+
"/
web
/auth/accessAuth/springBoard"
;
var
url
=
settings
.
centerChannelUrl
()
+
"/
api
/auth/accessAuth/springBoard"
;
var
userpinResultTmp
=
await
this
.
execlient
.
execPostTK
(
userparam
,
url
,
tokenInfo
.
data
.
token
);
var
userpinResultTmp
=
await
this
.
execlient
.
execPostTK
(
userparam
,
url
,
tokenInfo
.
data
.
token
);
if
(
userpinResultTmp
.
status
!=
0
&&
userpinResultTmp
.
status
!=
2060
)
{
if
(
userpinResultTmp
.
status
!=
0
&&
userpinResultTmp
.
status
!=
2060
)
{
return
system
.
getResultFail
(
-
99
,
"获取userpin失败"
);
return
{
"requestId"
:
self
.
getUUID
(),
"success"
:
false
,
"errorMsg"
:
"网络错误"
,
"errorCode"
:
"ok"
};
}
}
userpin
=
userpinResultTmp
.
data
.
userpin
;
userpin
=
userpinResultTmp
.
data
.
userpin
;
if
(
!
userpin
)
{
if
(
!
userpin
)
{
return
system
.
getResultFail
(
-
88
,
"获取userpin失败!!"
);
return
{
"requestId"
:
self
.
getUUID
(),
"success"
:
false
,
"errorMsg"
:
"网络错误"
,
"errorCode"
:
"ok"
};
}
}
}
}
//带userpin请求
//带userpin请求
url
=
settings
.
centerChannelUrl
()
+
"/
web/opreceive/need
/springBoard"
;
url
=
settings
.
centerChannelUrl
()
+
"/
api/opreceive/ic
/springBoard"
;
var
token
=
tokenInfo
.
data
.
token
;
var
token
=
tokenInfo
.
data
.
token
;
var
rtn
=
rtn
=
await
this
.
execlient
.
execDataPostByTokenUserPin
(
sobj
,
url
,
token
,
userpin
);
var
rtn
=
rtn
=
await
this
.
execlient
.
execDataPostByTokenUserPin
(
sobj
,
url
,
token
,
userpin
);
if
(
!
rtn
||
!
rtn
.
stdout
)
{
if
(
!
rtn
||
!
rtn
.
stdout
)
{
return
system
.
getResult
(
null
,
"execPost is empty"
);
return
{
"requestId"
:
self
.
getUUID
(),
"success"
:
false
,
"errorMsg"
:
"网络错误"
,
"errorCode"
:
"ok"
};
}
}
var
result
=
JSON
.
parse
(
rtn
.
stdout
);
var
result
=
JSON
.
parse
(
rtn
.
stdout
);
return
result
;
if
(
result
.
status
==
0
)
{
return
{
"requestId"
:
result
.
requestId
,
"success"
:
true
,
"errorMsg"
:
""
,
"errorCode"
:
"ok"
};
}
else
{
return
{
"requestId"
:
result
.
requestId
,
"success"
:
false
,
"errorMsg"
:
result
.
msg
,
"errorCode"
:
"ok"
};
}
}
}
}
}
...
...
igirl-channel-gateway/app/config/routes/api.js
View file @
90b3c112
...
@@ -68,7 +68,7 @@ module.exports = function (app) {
...
@@ -68,7 +68,7 @@ module.exports = function (app) {
try
{
try
{
var
client_ip
=
system
.
get_client_ip
(
req
);
var
client_ip
=
system
.
get_client_ip
(
req
);
req
.
body
.
action_type
=
"paySuccess"
;
req
.
body
.
action_type
=
"paySuccess"
;
var
result
=
await
utilsNeedSve
.
reqcenterchannel
(
req
.
body
,
client_ip
);
var
result
=
await
utilsNeedSve
.
paySuccess
(
req
.
body
,
client_ip
);
logCtl
.
info
({
logCtl
.
info
({
optitle
:
(
new
Date
()).
Format
(
"yyyy-MM-dd hh:mm:ss"
)
+
"回调处理订单结果:,method="
+
req
.
body
.
trxcode
,
optitle
:
(
new
Date
()).
Format
(
"yyyy-MM-dd hh:mm:ss"
)
+
"回调处理订单结果:,method="
+
req
.
body
.
trxcode
,
op
:
"center-channel/tlpay/opBackNotify"
,
op
:
"center-channel/tlpay/opBackNotify"
,
...
...
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