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
6aa83998
Commit
6aa83998
authored
Mar 20, 2020
by
宋毅
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tj
parent
ca2a44bb
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
44 additions
and
2 deletions
+44
-2
center-order/app/base/api/impl/action/need.js
+5
-2
center-order/app/base/db/impl/dbneed/needinfoDao.js
+32
-0
center-order/app/base/service/impl/dbneed/needinfoSve.js
+7
-0
No files found.
center-order/app/base/api/impl/action/need.js
View file @
6aa83998
...
...
@@ -31,13 +31,16 @@ class IcAPI extends APIBase {
var
opResult
=
null
;
switch
(
action_type
)
{
case
"submitNeed"
:
//提交需求
opResult
=
await
this
.
needinfoSve
.
submitNeed
(
pobj
,
pobj
.
actionBody
,
req
);
opResult
=
await
this
.
needinfoSve
.
submitNeed
(
pobj
,
pobj
.
actionBody
,
req
);
break
;
case
"getItemByNeedNo"
:
//获取需求详情
opResult
=
await
this
.
needinfoSve
.
getItemByNeedNo
(
pobj
);
break
;
case
"getItemByChannelNeedNo"
:
//获取需求详情
opResult
=
await
this
.
needinfoSve
.
getItemByChannelNeedNo
(
pobj
);
break
;
case
"needClose"
:
//需求关闭
opResult
=
await
this
.
needinfoSve
.
needClose
(
pobj
,
pobj
.
actionBody
,
req
);
opResult
=
await
this
.
needinfoSve
.
needClose
(
pobj
,
pobj
.
actionBody
,
req
);
break
;
default
:
opResult
=
system
.
getResult
(
null
,
"action_type参数错误"
);
...
...
center-order/app/base/db/impl/dbneed/needinfoDao.js
View file @
6aa83998
...
...
@@ -36,5 +36,37 @@ class NeedinfoDao extends Dao {
raw
:
true
});
}
async
getItemByChannelNeedNo
(
channelNeedNo
)
{
return
await
this
.
model
.
findOne
({
where
:
{
channelNeedNo
:
channelNeedNo
},
attributes
:
[
"id"
,
"uapp_id"
,
"needNo"
,
"channelNeedNo"
,
"channelUserId"
,
"followManUserId"
,
"followManMobile"
,
"city"
,
"province"
,
"publishContent"
,
"publishName"
,
"publishMobile"
,
"notes"
,
"followContent"
,
"disposeNotes"
,
"status"
,
"typeCode"
,
"typeName"
,
"channelTypeCode"
,
"channelTypeName"
,
"publisherOnlyCode"
,
"followManName"
,
"followManOnlyCode"
],
raw
:
true
});
}
}
module
.
exports
=
NeedinfoDao
;
center-order/app/base/service/impl/dbneed/needinfoSve.js
View file @
6aa83998
...
...
@@ -15,6 +15,13 @@ class NeedinfoService extends ServiceBase {
}
return
system
.
getResultSuccess
(
item
);
}
async
getItemByChannelNeedNo
(
pobj
)
{
var
item
=
await
this
.
dao
.
getItemByChannelNeedNo
(
pobj
.
actionBody
.
needNo
);
if
(
!
item
)
{
return
system
.
getResult
(
null
,
"需求数据为空,30210"
);
}
return
system
.
getResultSuccess
(
item
);
}
async
needinfo2fq
(
pobj
)
{
pobj
.
actionBody
.
needNo
=
await
this
.
getBusUid
(
"n"
);
pobj
.
actionBody
.
uapp_id
=
pobj
.
appInfo
.
id
;
...
...
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