Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
gh
/
data-view
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 beb57e01
authored
Jul 04, 2022
by
王志慧
Browse Files
Options
Browse Files
Tag
Download
Plain Diff
Merge branch 'dev_v1.0.0' of
http://192.168.3.233:8090/gh/data-view
into dev_v1.0.0
2 parents
3ccbcc9f
e1267c00
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
45 additions
and
22 deletions
src/assets/css/index.scss
src/components/LineChart.vue
src/utils/util.js
src/views/afterSales/analyze.vue
src/views/afterSales/mileage.vue
src/views/salesData/flow.vue
src/views/salesData/trend.vue
src/assets/css/index.scss
View file @
beb57e0
...
@@ -91,6 +91,8 @@ img {
...
@@ -91,6 +91,8 @@ img {
padding
:
0
.5vh
8px
;
padding
:
0
.5vh
8px
;
user-select
:
none
;
user-select
:
none
;
box-sizing
:
border-box
;
box-sizing
:
border-box
;
height
:
3
.1vh
;
overflow
:
hidden
;
}
}
.title-icon
{
.title-icon
{
...
...
src/components/LineChart.vue
View file @
beb57e0
...
@@ -198,16 +198,17 @@ p {
...
@@ -198,16 +198,17 @@ p {
padding
:
0.5vh
0.87vh
;
padding
:
0.5vh
0.87vh
;
border-top
:
1px
solid
#373739
;
border-top
:
1px
solid
#373739
;
.rank-title-block
{
.rank-title-block
{
flex
:
0
0
55px
;
//
flex
:
0
0
55px
;
width
:
55px
;
.rank-title
{
.rank-title
{
box-sizing
:
border-box
;
box-sizing
:
border-box
;
width
:
100%
;
width
:
100%
;
text-align
:
center
;
text-align
:
center
;
font-size
:
0.6em
;
//
font-size
:
0.6em
;
font-size
:
9px
;
background
:
#353535
;
background
:
#353535
;
padding
:
0.2vh
5px
;
padding
:
0.2vh
5px
;
height
:
1.8vh
;
height
:
1.8vh
;
line-height
:
1.8vh
;
opacity
:
0.7
;
opacity
:
0.7
;
cursor
:
pointer
;
cursor
:
pointer
;
}
}
...
@@ -236,7 +237,7 @@ p {
...
@@ -236,7 +237,7 @@ p {
padding-bottom
:
0
;
padding-bottom
:
0
;
}
}
}
}
.rank-line
:
top-child
{
.rank-line
:
first-of-type
{
border-width
:
0
;
border-width
:
0
;
}
}
}
}
...
...
src/utils/util.js
View file @
beb57e0
...
@@ -201,6 +201,15 @@ const getNMonth = (n, fmt = 'yyyy-MM-dd') => {
...
@@ -201,6 +201,15 @@ const getNMonth = (n, fmt = 'yyyy-MM-dd') => {
return
new
Date
(
new
Date
().
setMonth
(
new
Date
().
getMonth
()
+
n
)).
format
(
fmt
)
return
new
Date
(
new
Date
().
setMonth
(
new
Date
().
getMonth
()
+
n
)).
format
(
fmt
)
}
}
const
debounce
=
function
(
func
,
wait
=
200
)
{
let
timeout
return
function
(
event
)
{
clearTimeout
(
timeout
)
timeout
=
setTimeout
(()
=>
{
func
.
call
(
this
,
event
)
},
wait
)
}
}
const
utils
=
{
const
utils
=
{
removeLocalStorage
,
removeLocalStorage
,
setClipboardData
,
setClipboardData
,
...
@@ -228,7 +237,8 @@ const utils = {
...
@@ -228,7 +237,8 @@ const utils = {
numAddSymbol
,
numAddSymbol
,
getCurrentDate
,
getCurrentDate
,
getNDate
,
getNDate
,
getNMonth
getNMonth
,
debounce
}
}
Object
.
keys
(
utils
).
map
(
key
=>
{
Object
.
keys
(
utils
).
map
(
key
=>
{
...
...
src/views/afterSales/analyze.vue
View file @
beb57e0
...
@@ -182,17 +182,19 @@ export default {
...
@@ -182,17 +182,19 @@ export default {
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
.title
{
.title
{
padding
:
1vh
0.556vw
;
padding
:
1vh
8px
;
height
:
4vh
;
}
}
.analyze-content
{
.analyze-content
{
display
:
flex
;
display
:
flex
;
padding
:
0
8px
1.8vh
;
padding
:
0
8px
;
box-sizing
:
border-box
;
box-sizing
:
border-box
;
.bg
{
.bg
{
background-color
:
#262525
;
background-color
:
#262525
;
}
}
.content-left
{
.content-left
{
flex
:
1
;
flex
:
1
;
height
:
100%
;
}
}
.contetn-right
{
.contetn-right
{
width
:
50%
;
width
:
50%
;
...
...
src/views/afterSales/mileage.vue
View file @
beb57e0
...
@@ -113,7 +113,8 @@ export default {
...
@@ -113,7 +113,8 @@ export default {
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
.title
{
.title
{
padding
:
1vh
0.556vw
;
padding
:
1vh
8px
;
height
:
4vh
;
}
}
.ranking-container
{
.ranking-container
{
flex
:
1
;
flex
:
1
;
...
...
src/views/salesData/flow.vue
View file @
beb57e0
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
* @Author: huyue
* @Author: huyue
* @Date: 2022-06-23 15:05:21
* @Date: 2022-06-23 15:05:21
* @LastEditors: huyue
* @LastEditors: huyue
* @LastEditTime: 2022-07-0
1 14:26:28
* @LastEditTime: 2022-07-0
4 17:32:35
-->
-->
<
template
>
<
template
>
<div>
<div>
...
@@ -42,6 +42,7 @@
...
@@ -42,6 +42,7 @@
<
script
>
<
script
>
import
{
changeMixin
}
from
'@/mixins'
import
{
changeMixin
}
from
'@/mixins'
import
datas
from
'../../utils/data'
import
datas
from
'../../utils/data'
import
utils
from
'../../utils/util'
import
*
as
echarts
from
'echarts'
import
*
as
echarts
from
'echarts'
export
default
{
export
default
{
name
:
'Flow'
,
name
:
'Flow'
,
...
@@ -183,9 +184,14 @@ export default {
...
@@ -183,9 +184,14 @@ export default {
}
}
this
.
echartsFunnel
.
setOption
(
this
.
option
)
this
.
echartsFunnel
.
setOption
(
this
.
option
)
// 鼠标划入
// 鼠标划入
this
.
echartsFunnel
.
on
(
'mouseover'
,
data
=>
{
utils
.
debounce
(
this
.
getSaleTrans
(
this
.
paramsData
,
data
.
data
.
type
)
this
.
echartsFunnel
.
on
(
'mouseover'
,
data
=>
{
})
this
.
getSaleTrans
(
this
.
paramsData
,
data
.
data
.
type
)
})
)
// this.echartsFunnel.on('mouseover', data => {
// this.getSaleTrans(this.paramsData, data.data.type)
// })
},
},
getSaleTrans
(
val
,
queryItem
=
'enter'
)
{
getSaleTrans
(
val
,
queryItem
=
'enter'
)
{
const
params
=
{
const
params
=
{
...
...
src/views/salesData/trend.vue
View file @
beb57e0
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
* @Author: huyue
* @Author: huyue
* @Date: 2022-06-23 15:05:21
* @Date: 2022-06-23 15:05:21
* @LastEditors: huyue
* @LastEditors: huyue
* @LastEditTime: 2022-0
6-30 19:38:58
* @LastEditTime: 2022-0
7-04 17:40:52
-->
-->
<
template
>
<
template
>
<div>
<div>
...
@@ -80,13 +80,13 @@ export default {
...
@@ -80,13 +80,13 @@ export default {
}
}
})
})
this
.
$set
(
this
,
'hasData'
,
!
flag
.
every
(
i
=>
!
i
))
this
.
$set
(
this
,
'hasData'
,
!
flag
.
every
(
i
=>
!
i
))
this
.
draw
()
this
.
draw
(
val
.
reportType
)
})
})
.
catch
(()
=>
{
.
catch
(()
=>
{
this
.
hasData
=
false
this
.
hasData
=
false
})
})
},
},
draw
()
{
draw
(
reportType
)
{
this
.
option
=
{
this
.
option
=
{
tooltip
:
{
tooltip
:
{
trigger
:
'axis'
,
trigger
:
'axis'
,
...
@@ -164,7 +164,8 @@ export default {
...
@@ -164,7 +164,8 @@ export default {
lineStyle
:
{
lineStyle
:
{
color
:
'#606266'
color
:
'#606266'
}
}
}
},
splitNumber
:
4
},
},
series
:
[
series
:
[
{
{
...
@@ -173,7 +174,6 @@ export default {
...
@@ -173,7 +174,6 @@ export default {
symbol
:
'circle'
,
symbol
:
'circle'
,
smooth
:
true
,
smooth
:
true
,
showSymbol
:
false
,
showSymbol
:
false
,
stack
:
'Total'
,
data
:
[]
data
:
[]
},
},
{
{
...
@@ -182,7 +182,6 @@ export default {
...
@@ -182,7 +182,6 @@ export default {
symbol
:
'circle'
,
symbol
:
'circle'
,
smooth
:
true
,
smooth
:
true
,
showSymbol
:
false
,
showSymbol
:
false
,
stack
:
'Total'
,
data
:
[]
data
:
[]
},
},
{
{
...
@@ -191,7 +190,6 @@ export default {
...
@@ -191,7 +190,6 @@ export default {
symbol
:
'circle'
,
symbol
:
'circle'
,
smooth
:
true
,
smooth
:
true
,
showSymbol
:
false
,
showSymbol
:
false
,
stack
:
'Total'
,
data
:
[]
data
:
[]
},
},
{
{
...
@@ -200,7 +198,6 @@ export default {
...
@@ -200,7 +198,6 @@ export default {
symbol
:
'circle'
,
symbol
:
'circle'
,
showSymbol
:
false
,
showSymbol
:
false
,
smooth
:
true
,
smooth
:
true
,
stack
:
'Total'
,
data
:
[]
data
:
[]
},
},
{
{
...
@@ -209,12 +206,16 @@ export default {
...
@@ -209,12 +206,16 @@ export default {
symbol
:
'circle'
,
symbol
:
'circle'
,
showSymbol
:
false
,
showSymbol
:
false
,
smooth
:
true
,
smooth
:
true
,
stack
:
'Total'
,
data
:
[]
data
:
[]
}
}
]
]
}
}
this
.
option
.
xAxis
.
data
=
this
.
dataList
[
0
].
map
(
item
=>
item
.
statDate
)
const
xData
=
[]
this
.
option
.
xAxis
.
data
=
xData
this
.
dataList
[
0
].
map
(
e
=>
{
const
month
=
new
Date
(
e
.
statDate
).
getMonth
()
xData
.
push
(
reportType
==
0
?
`
${
month
==
0
?
'1月'
:
`
${
Number
(
month
)
+
1
}
月`
}
`
:
e
.
statDate
)
})
this
.
list
.
forEach
((
i
,
index
)
=>
{
this
.
list
.
forEach
((
i
,
index
)
=>
{
this
.
option
.
series
[
index
].
data
=
this
.
dataList
[
index
].
map
(
item
=>
item
.
num
)
this
.
option
.
series
[
index
].
data
=
this
.
dataList
[
index
].
map
(
item
=>
item
.
num
)
})
})
...
...
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