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
82a716ca
Commit
82a716ca
authored
Mar 20, 2020
by
宋毅
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tj
parent
44c4d5fd
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
27 additions
and
15 deletions
+27
-15
center-channel/app/base/service/impl/common/centerorderSve.js
+12
-8
center-channel/app/base/service/impl/utilsSve/utilsFqAliyunSve.js
+1
-1
center-channel/app/base/service/impl/utilsSve/utilsNeedSve.js
+5
-6
center-channel/app/base/service/impl/utilsSve/utilsPushSve.js
+9
-0
No files found.
center-channel/app/base/service/impl/common/centerorderSve.js
View file @
82a716ca
...
@@ -8,6 +8,7 @@ class CenterorderService {
...
@@ -8,6 +8,7 @@ class CenterorderService {
this
.
aliclient
=
system
.
getObject
(
"util.aliyunClient"
);
this
.
aliclient
=
system
.
getObject
(
"util.aliyunClient"
);
this
.
cacheManager
=
system
.
getObject
(
"db.common.cacheManager"
);
this
.
cacheManager
=
system
.
getObject
(
"db.common.cacheManager"
);
this
.
utilsOrderSve
=
system
.
getObject
(
"service.utilsSve.utilsOrderSve"
);
this
.
utilsOrderSve
=
system
.
getObject
(
"service.utilsSve.utilsOrderSve"
);
this
.
utilsPushSve
=
system
.
getObject
(
"service.utilsSve.utilsPushSve"
);
};
};
//调用center-order
//调用center-order
async
reqCenterOrderApi
(
pobj
,
reqUrl
)
{
async
reqCenterOrderApi
(
pobj
,
reqUrl
)
{
...
@@ -109,8 +110,8 @@ class CenterorderService {
...
@@ -109,8 +110,8 @@ class CenterorderService {
var
sobj
=
{
var
sobj
=
{
actionType
:
"getaliicProduce"
,
actionType
:
"getaliicProduce"
,
actionBody
:
pobj
.
actionBody
,
actionBody
:
pobj
.
actionBody
,
appInfo
:
pobj
.
appInfo
,
appInfo
:
pobj
.
appInfo
,
actionProcess
:
pobj
.
actionProcess
actionProcess
:
pobj
.
actionProcess
}
}
var
url
=
settings
.
centerAppUrl
()
+
"action/opProduct/springBoard"
;
var
url
=
settings
.
centerAppUrl
()
+
"action/opProduct/springBoard"
;
...
@@ -122,7 +123,7 @@ class CenterorderService {
...
@@ -122,7 +123,7 @@ class CenterorderService {
if
(
data
.
status
!=
0
)
{
if
(
data
.
status
!=
0
)
{
return
system
.
getResultFail
(
-
5010
,
"产品查询失败"
);
return
system
.
getResultFail
(
-
5010
,
"产品查询失败"
);
}
}
pobj
.
actionBody
=
data
.
data
;
pobj
.
actionBody
=
data
.
data
;
// var needNo="";
// var needNo="";
// if(solutiondata.data){
// if(solutiondata.data){
...
@@ -135,7 +136,7 @@ class CenterorderService {
...
@@ -135,7 +136,7 @@ class CenterorderService {
channelOrderNo
:
pobj
.
actionBody
.
orderNo
,
channelOrderNo
:
pobj
.
actionBody
.
orderNo
,
orderStatus
:
2
orderStatus
:
2
}
}
var
orderrtn
=
await
this
.
utilsOrderSve
.
addOrder
(
pobj
,
pobj
.
actionBody
);
var
orderrtn
=
await
this
.
utilsOrderSve
.
addOrder
(
pobj
,
pobj
.
actionBody
);
if
(
!
orderrtn
||
!
orderrtn
.
stdout
)
{
if
(
!
orderrtn
||
!
orderrtn
.
stdout
)
{
return
system
.
getResultFail
(
-
5012
,
"订单创建失败"
);
return
system
.
getResultFail
(
-
5012
,
"订单创建失败"
);
}
}
...
@@ -144,10 +145,10 @@ class CenterorderService {
...
@@ -144,10 +145,10 @@ class CenterorderService {
return
system
.
getResultFail
(
-
5012
,
"订单创建失败"
);
return
system
.
getResultFail
(
-
5012
,
"订单创建失败"
);
}
}
if
(
pobj
.
actionBody
.
solutionBizId
)
{
if
(
pobj
.
actionBody
.
solutionBizId
)
{
pobj
.
actionType
=
"receiveSolutionPayInfo"
;
pobj
.
actionType
=
"receiveSolutionPayInfo"
;
}
else
{
}
else
{
pobj
.
actionType
=
"createSolutionByOrder"
;
pobj
.
actionType
=
"createSolutionByOrder"
;
}
}
var
url
=
settings
.
centerOrderUrl
()
+
"action/icapi/springBoard"
;
var
url
=
settings
.
centerOrderUrl
()
+
"action/icapi/springBoard"
;
var
solutionrtn
=
await
this
.
execClient
.
execPost
(
pobj
,
url
);
var
solutionrtn
=
await
this
.
execClient
.
execPost
(
pobj
,
url
);
...
@@ -158,6 +159,9 @@ class CenterorderService {
...
@@ -158,6 +159,9 @@ class CenterorderService {
if
(
solutiondata
.
status
!=
0
)
{
if
(
solutiondata
.
status
!=
0
)
{
return
system
.
getResultFail
(
-
5011
,
"方案查询失败"
);
return
system
.
getResultFail
(
-
5011
,
"方案查询失败"
);
}
}
if
(
solutionrtn
.
status
==
0
)
{
this
.
utilsPushSve
.
aliBusiness2Fq
(
pobj
,
"pushOrderBusiness"
);
}
return
system
.
getResultSuccess
();
return
system
.
getResultSuccess
();
}
}
}
}
...
...
center-channel/app/base/service/impl/utilsSve/utilsFqAliyunSve.js
View file @
82a716ca
...
@@ -45,7 +45,7 @@ class UtilsFqAliyunSve extends AppServiceBase {
...
@@ -45,7 +45,7 @@ class UtilsFqAliyunSve extends AppServiceBase {
var
result
=
this
.
opAliyunClientPost
(
pobj
,
"pushOrderBusiness"
,
interface_params_info
.
opUrl
,
interface_params_info
.
key
,
interface_params_info
.
secret
,
params
);
var
result
=
this
.
opAliyunClientPost
(
pobj
,
"pushOrderBusiness"
,
interface_params_info
.
opUrl
,
interface_params_info
.
key
,
interface_params_info
.
secret
,
params
);
}
}
async
pushAli
IcNeedBusiness
(
pobj
)
{
//推送阿里工商需求商机
async
pushAli
Business2Fq
(
pobj
)
{
//推送阿里工商需求商机
if
(
!
pobj
.
interface_params
)
{
if
(
!
pobj
.
interface_params
)
{
return
""
;
return
""
;
}
}
...
...
center-channel/app/base/service/impl/utilsSve/utilsNeedSve.js
View file @
82a716ca
...
@@ -21,11 +21,7 @@ class UtilsNeedSve extends AppServiceBase {
...
@@ -21,11 +21,7 @@ class UtilsNeedSve extends AppServiceBase {
var
reqUrl
=
this
.
centerOrderUrl
+
"action/need/springBoard"
;
var
reqUrl
=
this
.
centerOrderUrl
+
"action/need/springBoard"
;
var
result
=
await
this
.
restPostUrl
(
pobj
,
reqUrl
);
var
result
=
await
this
.
restPostUrl
(
pobj
,
reqUrl
);
if
(
result
.
status
==
0
)
{
if
(
result
.
status
==
0
)
{
pobj
.
actionType
=
"getAppInterface"
;
this
.
utilsPushSve
.
aliBusiness2Fq
(
pobj
,
"pushNeedBusiness"
);
var
url
=
settings
.
centerAppUrl
()
+
"action/opProduct/springBoard"
;
var
productItemInterfaceResult
=
await
this
.
restPostUrl
(
pobj
,
url
);
pobj
.
interface_info
=
productItemInterfaceResult
.
data
;
this
.
utilsPushSve
.
pushBusInfo
(
pobj
,
"pushNeedBusiness"
,
1
);
}
}
return
result
;
return
result
;
}
}
...
@@ -52,7 +48,10 @@ class UtilsNeedSve extends AppServiceBase {
...
@@ -52,7 +48,10 @@ class UtilsNeedSve extends AppServiceBase {
return
system
.
getResult
(
null
,
"actionBody.intentionBizId can not be empty,100380"
);
return
system
.
getResult
(
null
,
"actionBody.intentionBizId can not be empty,100380"
);
}
}
var
reqUrl
=
this
.
centerOrderUrl
+
"action/need/springBoard"
;
var
reqUrl
=
this
.
centerOrderUrl
+
"action/need/springBoard"
;
return
await
this
.
restPostUrl
(
pobj
,
reqUrl
);
var
result
=
await
this
.
restPostUrl
(
pobj
,
reqUrl
);
if
(
result
.
status
==
0
)
{
this
.
utilsPushSve
.
aliBusiness2Fq
(
pobj
,
"pushCloseNeed"
);
}
}
}
}
}
module
.
exports
=
UtilsNeedSve
;
module
.
exports
=
UtilsNeedSve
;
...
...
center-channel/app/base/service/impl/utilsSve/utilsPushSve.js
View file @
82a716ca
...
@@ -7,6 +7,15 @@ class UtilsPushService extends AppServiceBase {
...
@@ -7,6 +7,15 @@ class UtilsPushService extends AppServiceBase {
super
();
super
();
this
.
pushlogSve
=
system
.
getObject
(
"service.common.pushlogSve"
);
this
.
pushlogSve
=
system
.
getObject
(
"service.common.pushlogSve"
);
};
};
async
aliBusiness2Fq
(
pobj
,
opType
)
{
pobj
.
actionType
=
"getAppInterface"
;
var
reqUrl
=
settings
.
centerAppUrl
()
+
"action/opProduct/springBoard"
;
var
productItemInterfaceResult
=
await
this
.
restPostUrl
(
pobj
,
reqUrl
);
pobj
.
interface_info
=
productItemInterfaceResult
.
data
;
this
.
pushBusInfo
(
pobj
,
opType
,
1
);
}
async
pushBusInfo
(
pobj
,
opType
,
isDelProductInfo
)
{
//推送业务信息
async
pushBusInfo
(
pobj
,
opType
,
isDelProductInfo
)
{
//推送业务信息
var
interface_list
=
pobj
.
actionBody
.
product_info
?
pobj
.
actionBody
.
product_info
.
interface_info
:
pobj
.
interface_info
;
var
interface_list
=
pobj
.
actionBody
.
product_info
?
pobj
.
actionBody
.
product_info
.
interface_info
:
pobj
.
interface_info
;
if
(
!
interface_list
)
{
if
(
!
interface_list
)
{
...
...
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