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
80eace4c
Commit
80eace4c
authored
Jan 06, 2021
by
任晓松
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
需求统计
parent
22c80d0c
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
center-order/app/base/service/impl/dbneed/opneedinfoSve.js
+2
-2
No files found.
center-order/app/base/service/impl/dbneed/opneedinfoSve.js
View file @
80eace4c
...
@@ -213,14 +213,14 @@ class NeedinfoService extends ServiceBase {
...
@@ -213,14 +213,14 @@ class NeedinfoService extends ServiceBase {
*/
*/
async
getStatisticsByProduct
(
pobj
){
async
getStatisticsByProduct
(
pobj
){
let
ac
=
pobj
.
actionBody
;
let
ac
=
pobj
.
actionBody
;
let
sql
=
`select typeCode,
status
,count(*) count from n_need_info where typeCode is not null `
;
let
sql
=
`select typeCode,
uapp_id
,count(*) count from n_need_info where typeCode is not null `
;
let
whereParams
=
{};
let
whereParams
=
{};
if
(
ac
.
start
&&
ac
.
end
){
if
(
ac
.
start
&&
ac
.
end
){
sql
+=
` and created_at >= :start and created_at <= :end `
;
sql
+=
` and created_at >= :start and created_at <= :end `
;
whereParams
.
start
=
ac
.
start
;
whereParams
.
start
=
ac
.
start
;
whereParams
.
end
=
ac
.
end
;
whereParams
.
end
=
ac
.
end
;
}
}
sql
+=
` GROUP BY typeCode,
status
`
;
sql
+=
` GROUP BY typeCode,
uapp_id
`
;
let
result
=
await
this
.
customQuery
(
sql
,
whereParams
);
let
result
=
await
this
.
customQuery
(
sql
,
whereParams
);
return
system
.
getResultSuccess
(
result
);
return
system
.
getResultSuccess
(
result
);
}
}
...
...
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