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
9ada1384
Commit
9ada1384
authored
Aug 27, 2020
by
linboxuan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
submitIcpIntention,queryIntentionList,confirmIcpIntention add
parent
2a2571be
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
84 additions
and
6 deletions
+84
-6
center-channel/app/base/api/impl/action/opNeed.js
+3
-1
center-channel/app/base/api/impl/opreceive/need.js
+9
-0
center-channel/app/base/service/impl/utilsSve/utilsNeedSve.js
+63
-0
center-channel/app/base/service/impl/utilsSve/utilsOpNeedSve.js
+7
-4
center-channel/app/config/routes/api.js
+2
-1
No files found.
center-channel/app/base/api/impl/action/opNeed.js
View file @
9ada1384
...
...
@@ -43,7 +43,9 @@ class OpNeed extends APIBase {
case
"getItemByNeedNo"
:
//需求详情
opResult
=
await
this
.
utilsOpNeedSve
.
getItemByNeedNo
(
pobj
,
pobj
.
actionBody
);
break
;
case
"test"
:
//2020 0826 lin 测试使用
opResult
=
await
this
.
utilsOpNeedSve
.
test
(
pobj
,
pobj
.
actionBody
);
break
;
// case "getItemByChannelNeedNo"://方案反馈
// opResult = await this.utilsOpNeedSve.getItemByChannelNeedNo(pobj, pobj.actionBody);
...
...
center-channel/app/base/api/impl/opreceive/need.js
View file @
9ada1384
...
...
@@ -76,6 +76,15 @@ class Need extends APIBase {
case
"getaliicpProduce"
:
//方案询价
opResult
=
await
this
.
centerorderSve
.
getaliicpProduce
(
pobj
);
break
;
case
"submitIcpIntention"
:
// 2020 0827 lin 新增 4.1 提交需求
opResult
=
await
this
.
utilsNeedSve
.
submitIcpIntention
(
pobj
,
pobj
.
actionBody
);
break
;
case
"queryIntentionList"
:
// 2020 0827 lin 新增 4.2 需求列表查询
opResult
=
await
this
.
utilsNeedSve
.
queryIntentionList
(
pobj
,
pobj
.
actionBody
);
break
;
case
"confirmIcpIntention"
:
// 2020 0827 lin 新增 4.3 用户需求确认
opResult
=
await
this
.
utilsNeedSve
.
confirmIcpIntention
(
pobj
,
pobj
.
actionBody
);
break
;
case
"testsymq"
:
opResult
=
await
this
.
utilsNeedSve
.
testsymq
(
pobj
);
break
;
...
...
center-channel/app/base/service/impl/utilsSve/utilsNeedSve.js
View file @
9ada1384
...
...
@@ -462,6 +462,69 @@ class UtilsNeedService extends AppServiceBase {
return
system
.
getResultSuccess
(
res
);
}
/**
* 2020 0827 lin 新增 4.1 用户在公司宝前端提交需求
* @param {*} pobj
* @param {*} actionBody
*/
async
submitIcpIntention
(
pobj
,
actionBody
)
{
// 校验文档上必填字段
if
(
!
actionBody
.
UserName
)
{
return
system
.
getResult
(
null
,
"actionBody.UserName can not be empty,100400"
);
}
if
(
!
actionBody
.
Description
)
{
return
system
.
getResult
(
null
,
"actionBody.Description can not be empty,100405"
);
}
if
(
!
actionBody
.
Area
)
{
return
system
.
getResult
(
null
,
"actionBody.Area can not be empty,100410"
);
}
if
(
!
actionBody
.
BizType
)
{
return
system
.
getResult
(
null
,
"actionBody.BizType can not be empty,100415"
);
}
// 调用center-order 生成新的需求
var
reqUrl
=
this
.
centerOrderUrl
+
"action/need/springBoard"
;
var
result
=
await
this
.
restPostUrl
(
pobj
,
reqUrl
);
// 生成成功 通知ali
if
(
result
.
status
==
0
)
{
var
aliResult
=
await
this
.
aliclient
.
reqbyget
({
action
:
"SubmitIcpIntention"
,
reqbody
:
actionBody
,
apiVersion
:
"2019-05-08"
});
console
.
log
(
aliResult
);
}
return
result
;
}
/**
* 2020 0827 lin 新增 4.2 需求列表查询
* @param {*} pobj
* @param {*} actionBody
*/
async
queryIntentionList
(
pobj
,
actionBody
)
{
var
aliResult
=
await
self
.
aliclient
.
reqbyget
({
action
:
"QueryIntentionList"
,
reqbody
:
actionBody
,
apiVersion
:
"2019-05-08"
});
if
(
aliResult
.
code
==
200
)
{
return
system
.
getResultSuccess
();
}
else
{
return
system
.
getResult
(
null
,
"查询失败 10420"
);
}
}
/**
* 2020 0827 lin 新增 4.3 用户需求确认 未测试
* @param {*} pobj
* @param {*} actionBody
*/
async
confirmIcpIntention
(
pobj
,
actionBody
)
{
if
(
!
actionBody
.
intentionBizId
)
{
return
system
.
getResult
(
null
,
"actionBody.intentionBizId can not be empty,100395"
);
}
var
reqUrl
=
this
.
centerOrderUrl
+
"action/need/springBoard"
;
var
result
=
await
this
.
restPostUrl
(
pobj
,
reqUrl
);
if
(
result
.
status
==
0
)
{
this
.
utilsPushSve
.
aliBusiness2Fq
(
pobj
,
"pushCloseNeed"
);
return
system
.
getResultSuccess
();
}
else
{
return
system
.
getResult
(
null
,
"推送失敗 100388"
);
}
}
async
testsymq
(
pobj
)
{
var
a
=
null
;
try
{
...
...
center-channel/app/base/service/impl/utilsSve/utilsOpNeedSve.js
View file @
9ada1384
...
...
@@ -296,10 +296,13 @@ class UtilsOpNeedService extends AppServiceBase {
}
return
jsonarr
;
}
// async opNeedDetailByChannelNo(pobj, actionBody){
// }
//2020 0826 lin 测试使用
async
test
(
pobj
,
actionBody
){
pobj
.
actionType
=
"receiveIcpStatusNotify"
;
var
url
=
settings
.
centerOrderUrl
()
+
"action/qcapi/springBoard"
;
var
rtn
=
await
this
.
restPostUrl
(
pobj
,
url
);
return
rtn
;
}
}
module
.
exports
=
UtilsOpNeedService
;
...
...
center-channel/app/config/routes/api.js
View file @
9ada1384
...
...
@@ -246,7 +246,8 @@ module.exports = function (app) {
"getPaidLogoListByUser"
,
"getCollectibleLogoListByUser"
,
"collectLogo"
,
"getLogoMaterial"
,
"cancelCollectLogo"
,
"icpNotify"
,
"createName"
,
"getNameDetail"
,
"orderConfirm"
,
"orderTotalSum"
,
"collect"
,
"reg"
,
"orderCheck"
,
"getReOrderList"
,
"getOfficalList"
,
"addReviewList"
,
"opSubmitNeed"
,
"opNeedClose"
,
"opNeedList"
,
"getItemByNeedNo"
,
"opNeedDetailByChannelNo"
,
"getNeedListUser"
,
"manualEvaluation"
,
"diagnosisInfo"
,
"check"
,
"enterpriseInfo"
,
"diagnosisDetail"
"manualEvaluation"
,
"diagnosisInfo"
,
"check"
,
"enterpriseInfo"
,
"diagnosisDetail"
,
"submitIcpIntention"
,
"queryIntentionList"
,
"confirmIcpIntention"
];
if
(
lst
.
indexOf
(
req
.
body
.
actionType
)
>=
0
)
{
var
userpin
=
req
.
headers
[
"userpin"
]
||
""
;
...
...
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