Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
h5
/
glsk-data-view-pd
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit cb47d68d
authored
Sep 14, 2023
by
匡雅琴
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
接口调整
1 parent
89009da1
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
37 additions
and
89 deletions
src/views/internal/components/BarOption.js
src/views/internal/components/DigitalLink.vue
src/views/internal/components/DigitalMarketingLeft.vue
src/views/internal/components/DigitalMarketingRight.vue
src/views/internal/components/ViewClue.vue
src/views/internal/components/ViewEdun.vue
src/views/internal/components/ViewIntersts.vue
src/views/internal/components/BarOption.js
View file @
cb47d68
...
@@ -32,7 +32,7 @@ function getBarOptions(obj, colorList, isMultiple, barwidth, formatYAxis) {
...
@@ -32,7 +32,7 @@ function getBarOptions(obj, colorList, isMultiple, barwidth, formatYAxis) {
color
:
'#1d2a38'
color
:
'#1d2a38'
}
}
},
},
//
splitNumber: 4,
splitNumber
:
4
,
axisLabel
:
{
axisLabel
:
{
// 这种做法就是在y轴的数据的值旁边拼接单位,貌似也挺方便的
// 这种做法就是在y轴的数据的值旁边拼接单位,貌似也挺方便的
formatter
:
function
(
value
)
{
formatter
:
function
(
value
)
{
...
...
src/views/internal/components/DigitalLink.vue
View file @
cb47d68
...
@@ -5,7 +5,7 @@
...
@@ -5,7 +5,7 @@
<StatisticsBox
:list=
"digitalLinkList"
></StatisticsBox>
<StatisticsBox
:list=
"digitalLinkList"
></StatisticsBox>
<div
class=
"down-content"
>
<div
class=
"down-content"
>
<PullDownSelect
:selectList=
"selectList"
@
selectVal=
"selectVal"
></PullDownSelect>
<PullDownSelect
:selectList=
"selectList"
@
selectVal=
"selectVal"
></PullDownSelect>
<BarChart
ref=
"linkChartRef"
domId=
"linkChart"
:label=
"'statDate'"
:colorList=
"colorList"
:valueName=
"'num'"
></BarChart>
<BarChart
ref=
"linkChartRef"
height=
"22vh"
domId=
"linkChart"
:label=
"'statDate'"
:colorList=
"colorList"
:valueName=
"'num'"
></BarChart>
</div>
</div>
</div>
</div>
</div>
</div>
...
...
src/views/internal/components/DigitalMarketingLeft.vue
View file @
cb47d68
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
<div
class=
"marketing-left"
>
<div
class=
"marketing-left"
>
<PullDownSelect
ref=
"leftDownSelect"
:selectList=
"selectList"
@
selectVal=
"selectVal"
></PullDownSelect>
<PullDownSelect
ref=
"leftDownSelect"
:selectList=
"selectList"
@
selectVal=
"selectVal"
></PullDownSelect>
<inner-tab
class=
"inner-tab"
v-if=
"tabShow"
:list=
"tabList"
:width=
"6.4"
:itemPadding=
"0.5"
@
changeTab=
"changeTab"
></inner-tab>
<inner-tab
class=
"inner-tab"
v-if=
"tabShow"
:list=
"tabList"
:width=
"6.4"
:itemPadding=
"0.5"
@
changeTab=
"changeTab"
></inner-tab>
<BarChart
v-if=
"chartShow"
ref=
"trendChartRef"
domId=
"trendChart"
:label=
"'statMonth'"
:height=
"'18vh'
"
:colorList=
"colorList"
:valueName=
"valueName"
></BarChart>
<BarChart
v-if=
"chartShow"
ref=
"trendChartRef"
domId=
"trendChart"
:label=
"'statMonth'"
height=
"22vh
"
:colorList=
"colorList"
:valueName=
"valueName"
></BarChart>
<LineChart
v-if=
"!chartShow"
ref=
"monthIncomeLineChartRef"
domId=
"monthIncomeLineChart"
:height=
"'18vh'"
:valName=
"valName"
></LineChart>
<LineChart
v-if=
"!chartShow"
ref=
"monthIncomeLineChartRef"
domId=
"monthIncomeLineChart"
:height=
"'18vh'"
:valName=
"valName"
></LineChart>
</div>
</div>
</
template
>
</
template
>
...
@@ -67,57 +67,20 @@ export default {
...
@@ -67,57 +67,20 @@ export default {
},
},
methods
:
{
methods
:
{
// selectVal(val) {
// console.log(val)
// // this.tabShow = false
// switch (val.val) {
// case 'registerNum':
// this.chartShow = true
// this.valueName = 'registerNum'
// this.$refs.trendChartRef.drawBar(this.marketingTrendList)
// break
// case 'activeNum':
// this.chartShow = true
// this.valueName = 'activeNum'
// this.$nextTick(() => {
// this.$refs.trendChartRef.drawBar(this.marketingTrendList)
// })
// break
// case 'output':
// this.valName = 'output'
// this.chartShow = false
// this.tabShow = true
// this.$refs.monthIncomeLineChartRef.drawLine(this.marketingTrendList)
// break
// case 'activityNum':
// this.chartShow = true
// this.valueName = 'activityNum'
// this.$refs.trendChartRef.drawBar(this.marketingCrowdFundingTrendList)
// break
// case 'orderNum':
// this.chartShow = true
// // this.valueName = 'orderNum'
// this.$refs.trendChartRef.drawBar(this.marketingCrowdFundingTrendList)
// break
// case 'avgPrice':
// this.chartShow = true
// this.valueName = 'avgPrice'
// this.$refs.trendChartRef.drawBar(this.marketingCrowdFundingTrendList)
// // this.tabShow = true
// break
// }
// },
selectVal
(
val
)
{
selectVal
(
val
)
{
const
actions
=
{
const
actions
=
{
registerNum
:
()
=>
{
registerNum
:
()
=>
{
this
.
chartShow
=
true
this
.
chartShow
=
true
this
.
tabShow
=
false
this
.
valueName
=
'registerNum'
this
.
valueName
=
'registerNum'
this
.
$refs
.
trendChartRef
.
drawBar
(
this
.
marketingTrendList
)
this
.
$nextTick
(()
=>
{
this
.
$refs
.
trendChartRef
.
drawBar
(
this
.
marketingTrendList
)
})
},
},
activeNum
:
()
=>
{
activeNum
:
()
=>
{
this
.
chartShow
=
true
this
.
chartShow
=
true
this
.
valueName
=
'activeNum'
this
.
valueName
=
'activeNum'
this
.
tabShow
=
false
this
.
$nextTick
(()
=>
{
this
.
$nextTick
(()
=>
{
this
.
$refs
.
trendChartRef
.
drawBar
(
this
.
marketingTrendList
)
this
.
$refs
.
trendChartRef
.
drawBar
(
this
.
marketingTrendList
)
})
})
...
...
src/views/internal/components/DigitalMarketingRight.vue
View file @
cb47d68
...
@@ -114,6 +114,7 @@ export default {
...
@@ -114,6 +114,7 @@ export default {
// 1.3售后众筹
// 1.3售后众筹
this
.
crowfundDistrType
=
'merData'
this
.
crowfundDistrType
=
'merData'
this
.
marketingDistributionList
=
this
.
marketingCrowdFundingDistr
.
merData
.
trendData
this
.
marketingDistributionList
=
this
.
marketingCrowdFundingDistr
.
merData
.
trendData
this
.
ratio
=
this
.
marketingCrowdFundingDistr
.
merData
.
ratio
}
}
break
break
case
1
:
case
1
:
...
@@ -125,12 +126,14 @@ export default {
...
@@ -125,12 +126,14 @@ export default {
// 1.3售后众筹
// 1.3售后众筹
this
.
crowfundDistrType
=
'orderData'
this
.
crowfundDistrType
=
'orderData'
this
.
marketingDistributionList
=
this
.
marketingCrowdFundingDistr
.
orderData
.
trendData
this
.
marketingDistributionList
=
this
.
marketingCrowdFundingDistr
.
orderData
.
trendData
this
.
ratio
=
this
.
marketingCrowdFundingDistr
.
merData
.
ratio
}
}
break
break
case
2
:
case
2
:
// 只有1.3售后众筹
// 只有1.3售后众筹
this
.
crowfundDistrType
=
'incomeData'
this
.
crowfundDistrType
=
'incomeData'
this
.
marketingDistributionList
=
this
.
marketingCrowdFundingDistr
.
incomeData
.
trendData
this
.
marketingDistributionList
=
this
.
marketingCrowdFundingDistr
.
incomeData
.
trendData
this
.
ratio
=
this
.
marketingCrowdFundingDistr
.
merData
.
ratio
break
break
}
}
this
.
$nextTick
(()
=>
{
this
.
$nextTick
(()
=>
{
...
...
src/views/internal/components/ViewClue.vue
View file @
cb47d68
...
@@ -112,6 +112,7 @@ export default {
...
@@ -112,6 +112,7 @@ export default {
console
.
log
(
val
)
console
.
log
(
val
)
this
.
rationality
=
val
.
value
this
.
rationality
=
val
.
value
const
_dataList
=
this
.
manageClueSalesAmountRationalityList
[
val
.
value
].
trendData
const
_dataList
=
this
.
manageClueSalesAmountRationalityList
[
val
.
value
].
trendData
this
.
ratio
=
this
.
manageClueSalesAmountRationalityList
[
val
.
value
].
ratio
this
.
$refs
.
rationalityChartRef
.
drawBar
(
_dataList
)
this
.
$refs
.
rationalityChartRef
.
drawBar
(
_dataList
)
},
},
// 只有当是销售数(output)时才会触发此事件
// 只有当是销售数(output)时才会触发此事件
...
...
src/views/internal/components/ViewEdun.vue
View file @
cb47d68
...
@@ -36,39 +36,28 @@ export default {
...
@@ -36,39 +36,28 @@ export default {
ratio
:
0
,
ratio
:
0
,
startPrice
:
''
,
startPrice
:
''
,
endPrice
:
''
,
endPrice
:
''
,
queryItem
:
'brandnum'
EDqueryItem
:
''
,
ESalesAmountRationalitydataList
:
[]
}
}
},
},
created
()
{
created
()
{
// 按年统计客户销售金额的合理性
// 按年统计客户销售金额的合理性
this
.
getManageESalesAmountRationality
()
this
.
getManageESalesAmountRationality
(
'brandData'
)
// 月收入趋势
// 月收入趋势
this
.
getManageETrend
()
this
.
getManageETrend
()
},
},
mounted
()
{
mounted
()
{
// this.$refs.edunChartRef.drawBar()
// this.$refs.edunLineChartRef.drawLine()
},
},
methods
:
{
methods
:
{
// changeTab(val) {
// switch (val) {
// case 0:
// this.queryItem = 'brandnum'
// this.getManageESalesAmountRationality('brandnum')
// break
// case 1:
// this.queryItem = 'output'
// this.getManageESalesAmountRationality('output')
// break
// }
// },
changeTab
(
val
)
{
changeTab
(
val
)
{
const
queryItems
=
[
'brandnum'
,
'output'
]
const
queryItems
=
[
'brandData'
,
'incomeData'
]
this
.
queryItem
=
queryItems
[
val
]
this
.
EDqueryItem
=
queryItems
[
val
]
this
.
getManageESalesAmountRationality
(
this
.
queryItem
)
const
_dataList
=
this
.
ESalesAmountRationalitydataList
[
this
.
EDqueryItem
].
trendData
this
.
ratio
=
this
.
ESalesAmountRationalitydataList
[
this
.
EDqueryItem
].
ratio
this
.
$refs
.
edunChartRef
.
drawBar
(
_dataList
)
},
},
selectPrice
(
val
)
{
selectPrice
(
val
)
{
console
.
log
(
val
)
console
.
log
(
val
)
...
@@ -78,13 +67,14 @@ export default {
...
@@ -78,13 +67,14 @@ export default {
},
},
async
getManageESalesAmountRationality
(
queryItem
)
{
async
getManageESalesAmountRationality
(
queryItem
)
{
const
params
=
{
const
params
=
{
queryItem
:
queryItem
||
this
.
queryItem
,
// brandnum--品牌总数;output--总金额
startPrice
:
this
.
startPrice
,
startPrice
:
this
.
startPrice
,
endPrice
:
this
.
endPrice
endPrice
:
this
.
endPrice
}
}
const
_data
=
await
this
.
api
.
internal
.
getManageESalesAmountRationality
(
params
)
const
_data
=
await
this
.
api
.
internal
.
getManageESalesAmountRationality
(
params
)
const
_dataList
=
_data
.
data
.
dataList
[
0
].
finishedProductTrendList
const
_queryItem
=
queryItem
||
this
.
EDqueryItem
this
.
ratio
=
_data
.
data
.
dataList
[
0
].
ratio
this
.
ESalesAmountRationalitydataList
=
_data
.
data
.
dataList
[
0
]
const
_dataList
=
_data
.
data
.
dataList
[
0
][
_queryItem
].
trendData
this
.
ratio
=
_data
.
data
.
dataList
[
0
][
_queryItem
].
ratio
this
.
$refs
.
edunChartRef
.
drawBar
(
_dataList
)
this
.
$refs
.
edunChartRef
.
drawBar
(
_dataList
)
},
},
async
getManageETrend
()
{
async
getManageETrend
()
{
...
...
src/views/internal/components/ViewIntersts.vue
View file @
cb47d68
...
@@ -38,50 +38,41 @@ export default {
...
@@ -38,50 +38,41 @@ export default {
attrName
:
'num'
attrName
:
'num'
},
},
ratio
:
0
,
ratio
:
0
,
queryItem
:
'num
'
,
equityItem
:
'
'
,
startPrice
:
''
,
startPrice
:
''
,
endPrice
:
''
endPrice
:
''
,
manageMemberSalesAmountList
:
[]
}
}
},
},
created
()
{
created
()
{
// 按年统计客户销售金额的合理性
// 按年统计客户销售金额的合理性
this
.
getManageMemberSalesAmountRationality
()
this
.
getManageMemberSalesAmountRationality
(
'merData'
)
// 月收入趋势
// 月收入趋势
this
.
getManageMemberTrend
()
this
.
getManageMemberTrend
()
},
},
mounted
()
{
mounted
()
{
// this.$refs.equityChartRef.drawBar()
// this.$refs.equityLineChartRef.drawLine()
},
},
methods
:
{
methods
:
{
changeTab
(
val
)
{
changeTab
(
val
)
{
switch
(
val
)
{
const
queryItems
=
[
'merData'
,
'customerData'
,
'incomeData'
]
case
0
:
this
.
equityItem
=
queryItems
[
val
]
this
.
getManageMemberSalesAmountRationality
(
'num'
)
const
_dataList
=
this
.
manageMemberSalesAmountList
[
this
.
equityItem
].
trendData
this
.
queryItem
=
'num'
this
.
ratio
=
this
.
manageMemberSalesAmountList
[
this
.
equityItem
].
ratio
break
this
.
$refs
.
equityChartRef
.
drawBar
(
_dataList
)
case
1
:
this
.
getManageMemberSalesAmountRationality
(
'customerNum'
)
this
.
queryItem
=
'customerNum'
break
case
2
:
this
.
getManageMemberSalesAmountRationality
(
'output'
)
this
.
queryItem
=
'output'
break
}
},
},
async
getManageMemberSalesAmountRationality
(
queryItem
)
{
async
getManageMemberSalesAmountRationality
(
queryItem
)
{
const
params
=
{
const
params
=
{
queryItem
:
queryItem
||
this
.
queryItem
,
// num--门店数;customerNum--会员人数;output--销售收入
startPrice
:
this
.
startPrice
,
startPrice
:
this
.
startPrice
,
endPrice
:
this
.
endPrice
endPrice
:
this
.
endPrice
}
}
const
_data
=
await
this
.
api
.
internal
.
getManageMemberSalesAmountRationality
(
params
)
const
_data
=
await
this
.
api
.
internal
.
getManageMemberSalesAmountRationality
(
params
)
const
_dataList
=
_data
.
data
.
dataList
[
0
].
finishedProductTrendList
const
_queryItem
=
queryItem
||
this
.
equityItem
this
.
ratio
=
_data
.
data
.
dataList
[
0
].
ratio
this
.
manageMemberSalesAmountList
=
_data
.
data
.
dataList
[
0
]
const
_dataList
=
_data
.
data
.
dataList
[
0
][
_queryItem
].
trendData
this
.
ratio
=
_data
.
data
.
dataList
[
0
][
_queryItem
].
ratio
this
.
$refs
.
equityChartRef
.
drawBar
(
_dataList
)
this
.
$refs
.
equityChartRef
.
drawBar
(
_dataList
)
},
},
async
getManageMemberTrend
()
{
async
getManageMemberTrend
()
{
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment