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
5f0f84d4
Commit
5f0f84d4
authored
Jan 14, 2020
by
赵庆
Browse files
Options
Browse Files
Download
Plain Diff
gsb
parents
83396dbe
982c4865
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
40 additions
and
15 deletions
+40
-15
bpo-web/app/base/api/impl/econtractApi.js
+28
-15
bpo-web/app/base/service/impl/econtractSve.js
+12
-0
No files found.
bpo-web/app/base/api/impl/econtractApi.js
View file @
5f0f84d4
...
@@ -514,6 +514,12 @@ class EcontractApi {
...
@@ -514,6 +514,12 @@ class EcontractApi {
var
userMobile
=
obj
.
userMobile
||
""
;
var
userMobile
=
obj
.
userMobile
||
""
;
var
nonceStr
=
obj
.
nonceStr
||
""
;
var
nonceStr
=
obj
.
nonceStr
||
""
;
let
exists
=
await
this
.
bankthreelogSve
.
findOne
({
userName
:
userName
,
userIdNo
:
userIdNo
,
userBankNo
:
userBankNo
,
userMobile
:
userMobile
,
});
var
sign
=
obj
.
sign
||
""
;
var
sign
=
obj
.
sign
||
""
;
var
btl
=
await
this
.
bankthreelogSve
.
create
({
var
btl
=
await
this
.
bankthreelogSve
.
create
({
appId
:
appId
,
appId
:
appId
,
...
@@ -560,6 +566,15 @@ class EcontractApi {
...
@@ -560,6 +566,15 @@ class EcontractApi {
mobile
:
userMobile
,
mobile
:
userMobile
,
};
};
if
(
exists
)
{
btl
.
result
=
true
;
btl
.
save
();
return
{
code
:
0
,
msg
:
"success"
};
}
var
tt
=
await
this
.
utilesignbaoSve
.
bankfour
(
bankParams
,
"econtractapi.bankthree"
)
||
{};
var
tt
=
await
this
.
utilesignbaoSve
.
bankfour
(
bankParams
,
"econtractapi.bankthree"
)
||
{};
// {"code":-110,"message":"手机号格式错误","data":{}}
// {"code":-110,"message":"手机号格式错误","data":{}}
//1成功,-110提示验证信息有误,-120亲,提供的信息不正确,请验证后再试!
//1成功,-110提示验证信息有误,-120亲,提供的信息不正确,请验证后再试!
...
@@ -1249,6 +1264,7 @@ class EcontractApi {
...
@@ -1249,6 +1264,7 @@ class EcontractApi {
var
signList
=
[];
var
signList
=
[];
var
unSignList
=
[];
var
unSignList
=
[];
var
accountMap
=
{};
var
accountMap
=
{};
var
accountMap2
=
{};
// 4 查签约用户
// 4 查签约用户
if
(
templateIds
.
idsO
.
length
>
0
)
{
if
(
templateIds
.
idsO
.
length
>
0
)
{
var
idsOCOunt
=
await
this
.
usereaccountSve
.
getSignAccounts
(
templateIds
.
idsO
,
idNoList
,
idNameList
);
var
idsOCOunt
=
await
this
.
usereaccountSve
.
getSignAccounts
(
templateIds
.
idsO
,
idNoList
,
idNameList
);
...
@@ -1259,32 +1275,29 @@ class EcontractApi {
...
@@ -1259,32 +1275,29 @@ class EcontractApi {
if
(
templateIds
.
idsT
.
length
>
0
)
{
if
(
templateIds
.
idsT
.
length
>
0
)
{
var
idsTCount
=
await
this
.
usereaccountSve
.
getSignAccounts_dk
(
templateIds
.
idsT
,
idNoList
,
idNameList
);
var
idsTCount
=
await
this
.
usereaccountSve
.
getSignAccounts_dk
(
templateIds
.
idsT
,
idNoList
,
idNameList
);
for
(
var
idT
of
idsTCount
)
{
for
(
var
idT
of
idsTCount
)
{
accountMap
[
idT
.
userName
+
"_"
+
idT
.
personsSign
]
=
1
;
accountMap
2
[
idT
.
userName
+
"_"
+
idT
.
personsSign
]
=
1
;
}
}
}
}
// 5 比对用户是否签约
// 5 比对用户是否签约
for
(
var
u
of
userList
)
{
for
(
var
u
of
userList
)
{
if
(
accountMap
[
u
.
idName
+
"_"
+
u
.
idNo
])
{
if
(
accountMap
[
u
.
idName
+
"_"
+
u
.
idNo
]
||
accountMap2
[
u
.
idName
+
"_"
+
u
.
idNo
]
)
{
signList
.
push
(
u
);
signList
.
push
(
u
);
}
else
{
}
else
{
unSignList
.
push
(
u
);
unSignList
.
push
(
u
);
}
}
}
}
// var hash = {};
var
hash
=
{};
// signList = signList.reduce(function(item, next) {
signList
=
signList
.
reduce
(
function
(
item
,
next
)
{
// hash[next.idNo] ? '' : hash[next.idNo] = true && item.push(next);
hash
[
next
.
idNo
]
?
''
:
hash
[
next
.
idNo
]
=
true
&&
item
.
push
(
next
);
// return item
return
item
// }, []);
},
[]);
//
// unSignList = unSignList.reduce(function(item, next) {
unSignList
=
unSignList
.
reduce
(
function
(
item
,
next
)
{
// hash[next.idNo] ? '' : hash[next.idNo] = true && item.push(next);
hash
[
next
.
idNo
]
?
''
:
hash
[
next
.
idNo
]
=
true
&&
item
.
push
(
next
);
// return item
return
item
// }, []);
},
[]);
return
{
return
{
code
:
0
,
code
:
0
,
msg
:
""
,
msg
:
""
,
...
...
bpo-web/app/base/service/impl/econtractSve.js
View file @
5f0f84d4
...
@@ -20,6 +20,9 @@ class EcontractService extends ServiceBase {
...
@@ -20,6 +20,9 @@ class EcontractService extends ServiceBase {
this
.
emessageDao
=
system
.
getObject
(
"db.emessageDao"
);
this
.
emessageDao
=
system
.
getObject
(
"db.emessageDao"
);
this
.
ecompanybusiDao
=
system
.
getObject
(
"db.ecompanybusiDao"
);
this
.
ecompanybusiDao
=
system
.
getObject
(
"db.ecompanybusiDao"
);
this
.
userDao
=
system
.
getObject
(
"db.userDao"
);
this
.
userDao
=
system
.
getObject
(
"db.userDao"
);
this
.
bankthreelogDao
=
system
.
getObject
(
"db.bankthreelogDao"
);
this
.
esealSve
=
system
.
getObject
(
"service.esealSve"
);
this
.
esealSve
=
system
.
getObject
(
"service.esealSve"
);
this
.
ejobapplySve
=
system
.
getObject
(
"service.ejobapplySve"
);
this
.
ejobapplySve
=
system
.
getObject
(
"service.ejobapplySve"
);
...
@@ -1289,11 +1292,19 @@ class EcontractService extends ServiceBase {
...
@@ -1289,11 +1292,19 @@ class EcontractService extends ServiceBase {
// e签宝流程
// e签宝流程
if
(
isNeedCreate
)
{
if
(
isNeedCreate
)
{
let
banklog
=
await
this
.
bankthreelogDao
.
findOne
({
userName
:
eaccount
.
userName
,
userIdNo
:
eaccount
.
personsSign
,
userBankNo
:
eaccount
.
bankno
,
result
:
1
,
});
if
(
!
banklog
)
{
var
bankthreeParams
=
{
var
bankthreeParams
=
{
name
:
eaccount
.
userName
,
name
:
eaccount
.
userName
,
idno
:
eaccount
.
personsSign
,
idno
:
eaccount
.
personsSign
,
cardno
:
eaccount
.
bankno
cardno
:
eaccount
.
bankno
};
};
var
threeResult
=
await
this
.
utilesignbaoSve
.
bankthree
(
bankthreeParams
,
"bankinfoAuth"
);
var
threeResult
=
await
this
.
utilesignbaoSve
.
bankthree
(
bankthreeParams
,
"bankinfoAuth"
);
// {"code":-110,"message":"手机号格式错误","data":{}}
// {"code":-110,"message":"手机号格式错误","data":{}}
//1成功,-110提示验证信息有误,-120亲,提供的信息不正确,请验证后再试!
//1成功,-110提示验证信息有误,-120亲,提供的信息不正确,请验证后再试!
...
@@ -1304,6 +1315,7 @@ class EcontractService extends ServiceBase {
...
@@ -1304,6 +1315,7 @@ class EcontractService extends ServiceBase {
if
(
threeResult
.
code
==
-
110
)
{
if
(
threeResult
.
code
==
-
110
)
{
return
this
.
returnjson
(
-
1
,
"银行三要素验证失败"
);
return
this
.
returnjson
(
-
1
,
"银行三要素验证失败"
);
}
}
}
var
uidStr
=
await
this
.
getUidStr
(
8
,
36
);
var
uidStr
=
await
this
.
getUidStr
(
8
,
36
);
var
thirdId
=
etemplate
.
id
+
"_"
+
eaccount
.
id
+
uidStr
;
var
thirdId
=
etemplate
.
id
+
"_"
+
eaccount
.
id
+
uidStr
;
...
...
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