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
f6c0281c
Commit
f6c0281c
authored
Jan 11, 2021
by
任晓松
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
订单统计
parent
0582abd3
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
175 additions
and
1 deletions
+175
-1
center-channel/app/base/api/impl/action/opNeed.js
+3
-0
center-channel/app/base/api/impl/opaction/order.js
+6
-0
center-channel/app/base/service/impl/utilsSve/utilsOpNeedSve.js
+41
-0
center-channel/app/base/service/impl/utilsSve/utilsOrderSve.js
+124
-0
center-channel/app/config/businessConfig.js
+1
-1
No files found.
center-channel/app/base/api/impl/action/opNeed.js
View file @
f6c0281c
...
@@ -60,6 +60,9 @@ class OpNeed extends APIBase {
...
@@ -60,6 +60,9 @@ class OpNeed extends APIBase {
case
"getStatisticsByProduct"
:
case
"getStatisticsByProduct"
:
opResult
=
await
this
.
utilsOpNeedSve
.
getStatisticsByProduct
(
pobj
);
opResult
=
await
this
.
utilsOpNeedSve
.
getStatisticsByProduct
(
pobj
);
break
;
break
;
case
"getStatisticsByArea"
:
opResult
=
await
this
.
utilsOpNeedSve
.
getStatisticsByArea
(
pobj
);
break
;
case
"getNeedFunnelStatistics"
:
case
"getNeedFunnelStatistics"
:
opResult
=
await
this
.
utilsOpNeedSve
.
getNeedFunnelStatistics
(
pobj
);
opResult
=
await
this
.
utilsOpNeedSve
.
getNeedFunnelStatistics
(
pobj
);
break
;
break
;
...
...
center-channel/app/base/api/impl/opaction/order.js
View file @
f6c0281c
...
@@ -35,6 +35,12 @@ class ProductAPI extends WEBBase {
...
@@ -35,6 +35,12 @@ class ProductAPI extends WEBBase {
case
"getOrderInfo"
:
//获取订单列表信息
case
"getOrderInfo"
:
//获取订单列表信息
opResult
=
await
this
.
utilsOrderSve
.
getOrderInfo
(
pobj
,
pobj
.
actionBody
);
opResult
=
await
this
.
utilsOrderSve
.
getOrderInfo
(
pobj
,
pobj
.
actionBody
);
break
;
break
;
case
"getOrderStatisticsByUappId"
:
opResult
=
await
this
.
utilsOrderSve
.
getOrdersStatisticsByUappId
(
pobj
);
break
;
case
"getOrderStatisticsByProduct"
:
opResult
=
await
this
.
utilsOrderSve
.
getOrdersStatisticsByProduct
(
pobj
);
break
;
case
"getOrderDetails"
:
//获取订单详情信息
case
"getOrderDetails"
:
//获取订单详情信息
opResult
=
await
this
.
utilsOrderSve
.
getOrderDetails
(
pobj
,
pobj
.
actionBody
);
opResult
=
await
this
.
utilsOrderSve
.
getOrderDetails
(
pobj
,
pobj
.
actionBody
);
break
;
break
;
...
...
center-channel/app/base/service/impl/utilsSve/utilsOpNeedSve.js
View file @
f6c0281c
...
@@ -405,6 +405,47 @@ class UtilsOpNeedService extends AppServiceBase {
...
@@ -405,6 +405,47 @@ class UtilsOpNeedService extends AppServiceBase {
return
system
.
getResultSuccess
(
reArr
);
return
system
.
getResultSuccess
(
reArr
);
}
}
/**
* 需求统计(地区维度)
* @param pobj
* @returns {Promise<void>}
*/
async
getStatisticsByArea
(
pobj
){
let
url
=
this
.
centerOrderUrl
+
"action/opNeed/springBoard"
;
let
result
=
await
this
.
restPostUrl
(
pobj
,
url
);
if
(
result
.
status
!=
0
){
return
system
.
getResultFail
(
-
1
);
}
let
data
=
result
.
data
;
let
temp
=
""
;
let
arr
=
[];
let
reArr
=
[];
for
(
let
i
=
0
;
i
<
data
.
length
;
i
++
){
if
((
temp
!=
data
[
i
].
province
&&
temp
!=
""
)){
let
obj
=
{
province
:
temp
,
data
:
arr
}
reArr
.
push
(
obj
);
arr
=
[];
}
let
dArr
=
{
type_cod
:
data
[
i
].
typeCode
,
count
:
data
[
i
].
count
}
arr
.
push
(
dArr
);
temp
=
data
[
i
].
province
;
if
(
i
==
data
.
length
-
1
){
let
obj
=
{
province
:
temp
,
data
:
arr
}
reArr
.
push
(
obj
);
}
}
return
system
.
getResultSuccess
(
reArr
);
}
urlSplit
(
url
)
{
urlSplit
(
url
)
{
var
arr
=
url
.
split
(
"?"
)[
1
];
//根据?跟个url
var
arr
=
url
.
split
(
"?"
)[
1
];
//根据?跟个url
...
...
center-channel/app/base/service/impl/utilsSve/utilsOrderSve.js
View file @
f6c0281c
...
@@ -132,6 +132,130 @@ class UtilsOrderService extends AppServiceBase {
...
@@ -132,6 +132,130 @@ class UtilsOrderService extends AppServiceBase {
var
result
=
await
this
.
restPostUrl
(
pobj
,
reqUrl
);
var
result
=
await
this
.
restPostUrl
(
pobj
,
reqUrl
);
return
result
;
return
result
;
}
}
/**
* 各渠道需求统计
* @param pobj
* @returns {Promise<void>}
*/
async
getOrdersStatisticsByUappId
(
pobj
){
let
url
=
this
.
centerOrderUrl
+
"action/order/springBoard"
;
let
result
=
await
this
.
restPostUrl
(
pobj
,
url
);
if
(
result
.
status
!=
0
){
return
system
.
getResultFail
(
-
1
);
}
let
data
=
result
.
data
;
let
temp
=
0
;
let
arr
=
[];
let
reArr
=
[];
for
(
let
i
=
0
;
i
<
data
.
length
;
i
++
){
if
((
temp
!=
data
[
i
].
uapp_id
&&
temp
!=
0
)){
let
obj
=
{
uapp_id
:
temp
,
data
:
arr
}
reArr
.
push
(
obj
);
arr
=
[];
}
let
dArr
=
{
time
:
data
[
i
].
time
,
count
:
data
[
i
].
count
}
arr
.
push
(
dArr
);
temp
=
data
[
i
].
uapp_id
;
if
(
i
==
data
.
length
-
1
){
let
obj
=
{
uapp_id
:
temp
,
data
:
arr
}
reArr
.
push
(
obj
);
}
}
reArr
.
sort
((
a
,
b
)
=>
{
return
a
.
uapp_id
-
b
.
uapp_id
;
})
let
temp2
=
0
;
let
arr2
=
[];
let
final
=
[];
for
(
let
i
=
0
;
i
<
reArr
.
length
;
i
++
){
if
((
temp2
!=
reArr
[
i
].
uapp_id
&&
temp2
!=
0
)){
let
o
=
{
uapp_id
:
temp2
,
data
:
arr2
};
final
.
push
(
o
);
arr2
=
[];
}
console
.
log
(
reArr
[
i
].
data
)
arr2
=
arr2
.
concat
(
reArr
[
i
].
data
);
temp2
=
reArr
[
i
].
uapp_id
;
if
(
i
==
reArr
.
length
-
1
){
let
obj
=
{
uapp_id
:
temp2
,
data
:
arr2
}
final
.
push
(
obj
);
}
}
return
system
.
getResultSuccess
(
final
);
}
/**
* 需求统计(产品维度)
* @param pobj
* @returns {Promise<void>}
*/
async
getOrdersStatisticsByProduct
(
pobj
){
let
url
=
this
.
centerOrderUrl
+
"action/order/springBoard"
;
let
result
=
await
this
.
restPostUrl
(
pobj
,
url
);
if
(
result
.
status
!=
0
){
return
system
.
getResultFail
(
-
1
);
}
let
data
=
result
.
data
;
let
temp
=
""
;
let
arr
=
[];
let
reArr
=
[];
for
(
let
i
=
0
;
i
<
data
.
length
;
i
++
){
if
(
data
[
i
].
typeCode
==
'10202010202001'
){
data
[
i
].
typeCode
=
'zzsbzc'
;
}
if
(
data
[
i
].
typeCode
==
'10202010202002'
){
data
[
i
].
typeCode
=
'fzsbzc'
;
}
if
(
data
[
i
].
typeCode
==
'10202010202003'
){
data
[
i
].
typeCode
=
'dbsbzc'
;
}
if
(
data
[
i
].
typeCode
==
'10202010204002'
){
data
[
i
].
typeCode
=
'icpsq'
;
}
if
(
data
[
i
].
typeCode
==
'10202010204001'
){
data
[
i
].
typeCode
=
'edisq'
;
}
if
((
temp
!=
data
[
i
].
typeCode
&&
temp
!=
""
)){
let
obj
=
{
type_code
:
temp
,
data
:
arr
}
reArr
.
push
(
obj
);
arr
=
[];
}
let
dArr
=
{
uapp_id
:
data
[
i
].
uapp_id
,
count
:
data
[
i
].
count
}
arr
.
push
(
dArr
);
temp
=
data
[
i
].
typeCode
;
if
(
i
==
data
.
length
-
1
){
let
obj
=
{
type_code
:
temp
,
data
:
arr
}
reArr
.
push
(
obj
);
}
}
return
system
.
getResultSuccess
(
reArr
);
}
async
getOrderDetails
(
pobj
,
actionBody
)
{
async
getOrderDetails
(
pobj
,
actionBody
)
{
var
reqUrl
=
this
.
centerOrderUrl
+
"action/order/springBoard"
;
var
reqUrl
=
this
.
centerOrderUrl
+
"action/order/springBoard"
;
var
result
=
await
this
.
restPostUrl
(
pobj
,
reqUrl
);
var
result
=
await
this
.
restPostUrl
(
pobj
,
reqUrl
);
...
...
center-channel/app/config/businessConfig.js
View file @
f6c0281c
...
@@ -17,7 +17,7 @@ module.exports = {
...
@@ -17,7 +17,7 @@ module.exports = {
"ncSubmitMaterial"
,
"ncNotification"
,
"ncSubmitSolution"
,
"ncCloseNeed"
,
"ncClosePlan"
,
"ncSubmitMaterial"
,
"ncNotification"
,
"ncSubmitSolution"
,
"ncCloseNeed"
,
"ncClosePlan"
,
"rtSubmitMaterial"
,
"rtNotification"
,
"rtSubmitSolution"
,
"rtCloseNeed"
,
"rtClosePlan"
,
"rtSubmitMaterial"
,
"rtNotification"
,
"rtSubmitSolution"
,
"rtCloseNeed"
,
"rtClosePlan"
,
"getParamsFor360"
,
"addOrderWeb"
,
"getPayRecords"
,
"getLoginInfo"
,
"putUserMobileByVcode"
,
"getParamsFor360"
,
"addOrderWeb"
,
"getPayRecords"
,
"getLoginInfo"
,
"putUserMobileByVcode"
,
"putUserPwdByMobile"
,
"icpNotifyNew"
,
"putUserPwdByMobile"
,
"icpNotifyNew"
,
"getOrderStatisticsByUappId"
,
"getOrderStatisticsByProduct"
,
//百度工商注册
//百度工商注册
"regGetInfoByChannelNeedNo"
,
"submitRegNeed"
,
"regFeedbackSubmit"
,
"regOrderStatus"
,
"regOrderClose"
,
"regGetInfoByChannelNeedNo"
,
"submitRegNeed"
,
"regFeedbackSubmit"
,
"regOrderStatus"
,
"regOrderClose"
,
"getSolutionByChannelOrderNo"
,
"regSubmitSolution"
,
"regNeedClose"
,
"getSolutionByChannelOrderNo"
,
"regSubmitSolution"
,
"regNeedClose"
,
...
...
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