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
38010abe
Commit
38010abe
authored
Jul 06, 2020
by
zhaoxiqing
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'esign-api' of
http://gitlab.gongsibao.com/jiangyong/zhichan
into esign-api
parents
70551bc7
fa523fef
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
17 deletions
+18
-17
esign-api/app/base/api/api.base.js
+1
-1
esign-api/app/base/service/impl/sign/signSve.js
+17
-16
No files found.
esign-api/app/base/api/api.base.js
View file @
38010abe
...
...
@@ -9,7 +9,7 @@ class APIBase extends DocBase {
this
.
merchantSve
=
system
.
getObject
(
"service.merchant.merchantSve"
);
this
.
oplogSve
=
system
.
getObject
(
"service.common.oplogSve"
);
this
.
SIGN_GNAME
=
[
'sign'
];
this
.
EXCEPT_KEYS
=
[
'sign'
,
'requestid'
];
this
.
EXCEPT_KEYS
=
[
'sign'
,
'requestid'
,
'simpleFormFields'
];
}
getUUID
()
{
var
uuid
=
uuidv4
();
...
...
esign-api/app/base/service/impl/sign/signSve.js
View file @
38010abe
...
...
@@ -6,7 +6,7 @@ class AuthService extends ServiceBase {
super
();
this
.
feeSve
=
system
.
getObject
(
"service.fee.feeSve"
);
this
.
orderSve
=
system
.
getObject
(
"service.order.orderSve"
);
this
.
order
authlogSve
=
system
.
getObject
(
"service.order.orderauth
logSve"
);
this
.
order
signlogSve
=
system
.
getObject
(
"service.order.ordersign
logSve"
);
this
.
enginesignSve
=
system
.
getObject
(
"service.engine.enginesignSve"
);
this
.
tradelogDao
=
system
.
getObject
(
"db.common.tradelogDao"
);
}
...
...
@@ -188,7 +188,7 @@ class AuthService extends ServiceBase {
return
system
.
getResultFail
(
1000000
,
"模板ID不能为空"
);
}
if
(
!
simpleFormFields
)
{
return
system
.
getResultFail
(
1000000
,
"
文本域不能为空
"
);
return
system
.
getResultFail
(
1000000
,
"
模板关联参数错误
"
);
}
return
this
.
operatorSign
(
params
,
async
(
p
)
=>
{
// 调用创建账户API
...
...
@@ -233,21 +233,22 @@ class AuthService extends ServiceBase {
}
// 2. 调用签约引擎接口
let
res
=
await
operatorMethod
(
params
);
let
contract
=
res
.
data
||
{};
if
(
isFee
)
{
// 生成订单
// let logres = await this.orderauthlogSve.saveEorderAuthLog({
// order_id: orderProduct.id,
// product_id: orderProduct.product_id,
// platform_name: app.name,
// platform_id: app.id,
// spended_num: trade.trade_amt,
// user_name: params.idName, // 使用方
// actual_spend_name: app.merchant_name,// 实际使用方
// engine_trade_id: trade.id,
// pass: pass ? 1 : 0
// });
// console.log(logres);
let
logres
=
await
this
.
ordersignlogSve
.
saveEorderSignLog
({
order_id
:
orderProduct
.
id
,
product_id
:
orderProduct
.
product_id
,
platform_name
:
app
.
name
,
platform_id
:
app
.
id
,
user_name
:
contract
.
idName
,
// 使用方
spended_num
:
trade
.
trade_amt
,
actual_spend_name
:
app
.
merchant_name
,
// 实际使用方
engine_contract_name
:
contract
.
name
,
engine_contract_id
:
contract
.
docid
,
engine_trade_id
:
trade
.
id
,
});
console
.
log
(
logres
);
}
// 4. 返回认证结果
return
system
.
getResultSuccess
(
res
.
data
,
res
.
msg
);
...
...
@@ -275,7 +276,7 @@ class AuthService extends ServiceBase {
account_id
:
orderProduct
.
engine_account_id
,
trade_amt
:
trade_amt
,
trade_no
:
tradeLog
.
id
,
trade_desc
:
"二要素验证
"
,
trade_desc
:
params
.
desc
||
"
"
,
});
if
(
tradeRes
.
status
!==
0
)
{
tradeLog
.
result
=
2
;
...
...
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