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
16cf47e3
Commit
16cf47e3
authored
Nov 08, 2020
by
兰国旗
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
closedNeedAndAddPathUrl
parent
63598c4a
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
38 additions
and
15 deletions
+38
-15
center-channel/app/base/api/impl/opreceive/need2.js
+1
-1
center-channel/app/base/service/impl/common/baseCenterOrderSve.js
+16
-3
center-channel/app/base/service/impl/utilsSve/utilsNeedSve2.js
+21
-11
No files found.
center-channel/app/base/api/impl/opreceive/need2.js
View file @
16cf47e3
...
@@ -41,7 +41,7 @@ class Need2 extends APIBase {
...
@@ -41,7 +41,7 @@ class Need2 extends APIBase {
opResult
=
await
this
.
utilsNeedSve
.
needClose
(
pobj
,
pobj
.
actionBody
);
opResult
=
await
this
.
utilsNeedSve
.
needClose
(
pobj
,
pobj
.
actionBody
);
break
;
break
;
case
"needCloseIcp"
:
//关闭需求
case
"needCloseIcp"
:
//关闭需求
opResult
=
await
this
.
utilsNeedSve
.
needCloseIcp
(
pobj
,
pobj
.
actionBody
);
opResult
=
await
this
.
utilsNeedSve
2
.
needCloseIcp
(
pobj
,
pobj
.
actionBody
);
break
;
break
;
case
"needDetailByChannelNo"
:
case
"needDetailByChannelNo"
:
opResult
=
await
this
.
utilsNeedSve
.
needDetailByChannelNo
(
pobj
,
pobj
.
actionBody
);
opResult
=
await
this
.
utilsNeedSve
.
needDetailByChannelNo
(
pobj
,
pobj
.
actionBody
);
...
...
center-channel/app/base/service/impl/common/baseCenterOrderSve.js
View file @
16cf47e3
...
@@ -230,17 +230,30 @@ class BaseCenterOrderService extends AppServiceBase {
...
@@ -230,17 +230,30 @@ class BaseCenterOrderService extends AppServiceBase {
console
.
log
(
"pushRes++++"
,
pushRes
)
console
.
log
(
"pushRes++++"
,
pushRes
)
if
(
pushRes
&&
pushRes
.
status
==
0
&&
pushRes
.
data
)
{
if
(
pushRes
&&
pushRes
.
status
==
0
&&
pushRes
.
data
)
{
var
resData
=
pushRes
.
data
;
var
resData
=
pushRes
.
data
;
if
(
resData
.
result
)
{
if
(
resData
.
planId
)
{
var
reqObj2
=
{
var
reqObj2
=
{
actionType
:
"receiveProgrammeNo"
,
actionType
:
"receiveProgrammeNo"
,
appInfo
:
appInfo
,
appInfo
:
appInfo
,
actionBody
:
{
actionBody
:
{
solutionNo
:
solutionNo
,
solutionNo
:
solutionNo
,
solutionBizId
:
resData
.
result
solutionBizId
:
resData
.
planId
}
}
};
};
var
a
=
await
self
.
reqCenterOrderApi
(
reqObj2
);
//保存渠道方案id
var
a
=
await
self
.
reqCenterOrderApi
(
reqObj2
);
//保存渠道方案id
return
pushRes
;
console
.
log
(
"保存渠道方案id aaaa++ "
,
a
)
if
(
a
&&
a
.
status
==
0
&&
resData
.
path
)
{
var
reqObj3
=
{
actionType
:
"receiveIcpConfirmUrl"
,
appInfo
:
appInfo
,
actionBody
:
{
solutionNo
:
solutionNo
,
confirmUrl
:
resData
.
path
}
};
var
url
=
await
self
.
reqCenterOrderApi
(
reqObj3
);
//保存用户确认方案url
console
.
log
(
'save confirmUrl ++ '
,
url
)
return
pushRes
;
}
}
}
}
}
}
}
...
...
center-channel/app/base/service/impl/utilsSve/utilsNeedSve2.js
View file @
16cf47e3
...
@@ -259,16 +259,19 @@ class UtilsNeedService2 extends AppServiceBase {
...
@@ -259,16 +259,19 @@ class UtilsNeedService2 extends AppServiceBase {
* @param {*} actionBody
* @param {*} actionBody
*/
*/
async
needCloseIcp
(
pobj
,
actionBody
)
{
async
needCloseIcp
(
pobj
,
actionBody
)
{
if
(
!
actionBody
.
channelNeedNo
)
{
console
.
log
(
'guanbi icp xuqiu pobj+++'
,
pobj
)
return
system
.
getResult
(
null
,
"actionBody.channelNeedNo can not be empty,100395"
);
if
(
actionBody
.
uapp_id
==
uappId
.
ali
){
}
if
(
!
actionBody
.
channelNeedNo
)
{
if
(
!
actionBody
.
note
)
{
return
system
.
getResult
(
null
,
"actionBody.channelNeedNo can not be empty,100395"
);
return
system
.
getResult
(
null
,
"actionBody.note can not be empty,100395"
);
}
if
(
!
actionBody
.
note
)
{
return
system
.
getResult
(
null
,
"actionBody.note can not be empty,100395"
);
}
}
}
var
self
=
this
;
var
self
=
this
;
pobj
.
actionBody
.
intentionBizId
=
pobj
.
actionBody
.
channelNeedNo
;
pobj
.
actionBody
.
intentionBizId
=
pobj
.
actionBody
.
channelNeedNo
;
pobj
.
actionType
=
"abolishIcpProgrammeByNeed"
pobj
.
actionType
=
"abolishIcpProgrammeByNeed"
var
reqUrl
=
this
.
centerOrderUrl
+
"action/
qc
api/springBoard"
;
var
reqUrl
=
this
.
centerOrderUrl
+
"action/
base
api/springBoard"
;
var
result
=
await
this
.
restPostUrl
(
pobj
,
reqUrl
);
var
result
=
await
this
.
restPostUrl
(
pobj
,
reqUrl
);
this
.
logCtl
.
info
({
this
.
logCtl
.
info
({
appid
:
pobj
.
appInfo
?
pobj
.
appInfo
.
uapp_id
||
""
:
""
,
appid
:
pobj
.
appInfo
?
pobj
.
appInfo
.
uapp_id
||
""
:
""
,
...
@@ -279,9 +282,10 @@ class UtilsNeedService2 extends AppServiceBase {
...
@@ -279,9 +282,10 @@ class UtilsNeedService2 extends AppServiceBase {
resultInfo
:
JSON
.
stringify
(
result
),
resultInfo
:
JSON
.
stringify
(
result
),
optitle
:
"abolishIcpProgrammeByNeed推送蜂擎获取的接口信息->aliBusiness2Delivery"
,
optitle
:
"abolishIcpProgrammeByNeed推送蜂擎获取的接口信息->aliBusiness2Delivery"
,
});
});
console
.
log
(
'result close'
,
result
)
if
(
result
.
status
==
0
)
{
if
(
result
.
status
==
0
)
{
if
(
result
.
data
)
{
if
(
result
.
data
&&
result
.
data
.
orderNo
)
{
pobj
.
actionBody
.
orderNo
=
result
.
data
;
pobj
.
actionBody
.
orderNo
=
result
.
data
.
orderNo
;
var
orderrtn
=
await
self
.
utilsOrderSve
.
delOrder
(
pobj
,
pobj
.
actionBody
);
var
orderrtn
=
await
self
.
utilsOrderSve
.
delOrder
(
pobj
,
pobj
.
actionBody
);
if
(
orderrtn
.
status
<
0
)
{
if
(
orderrtn
.
status
<
0
)
{
return
system
.
getResultFail
(
-
5022
,
"订单关闭失败"
);
return
system
.
getResultFail
(
-
5022
,
"订单关闭失败"
);
...
@@ -308,9 +312,15 @@ class UtilsNeedService2 extends AppServiceBase {
...
@@ -308,9 +312,15 @@ class UtilsNeedService2 extends AppServiceBase {
resultInfo
:
""
,
resultInfo
:
""
,
optitle
:
"updateChanceStatus推送蜂擎获取的接口信息->aliBusiness2Delivery"
,
optitle
:
"updateChanceStatus推送蜂擎获取的接口信息->aliBusiness2Delivery"
,
});
});
// 推送ali
// 推送ali
var
a
=
await
self
.
aliclient
.
reqbyget
({
action
:
"CloseIntention"
,
reqbody
:
{
BizId
:
actionBody
.
channelNeedNo
,
Note
:
actionBody
.
note
},
apiVersion
:
"2019-05-08"
});
if
(
result
.
data
.
uapp_id
==
uappId
.
ali
){
console
.
log
(
a
);
var
a
=
await
self
.
aliclient
.
reqbyget
({
action
:
"CloseIntention"
,
reqbody
:
{
BizId
:
actionBody
.
channelNeedNo
,
Note
:
actionBody
.
note
},
apiVersion
:
"2019-05-08"
});
}
// 推送baidu
if
(
result
.
data
.
uapp_id
==
uappId
.
baidu
){
var
a
=
await
self
.
baiduclient
.
baiduReqbyget
({
path
:
"/api/bla/provider/requirement/update"
,
reqbody
:
{
requirementId
:
actionBody
.
channelNeedNo
,
status
:
"CLOSED"
,
note
:
actionBody
.
note
}});
}
console
.
log
(
"closed need a+++"
,
a
);
self
.
utilsPushSve
.
aliBusiness2Fq
(
pobj
,
"pushCloseICPNeed"
);
self
.
utilsPushSve
.
aliBusiness2Fq
(
pobj
,
"pushCloseICPNeed"
);
return
system
.
getResultSuccess
();
return
system
.
getResultSuccess
();
}
else
{
}
else
{
...
...
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