Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
W
WX_h5
Project
Project
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
godwithdh
WX_h5
Commits
4e105c52
Commit
4e105c52
authored
Mar 30, 2020
by
张锡奇
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
upload
parent
2b03b25c
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
110 additions
and
2 deletions
+110
-2
empAna.vue
src/view/tiip/IntReportForms/empAna.vue
+96
-2
abnormal.vue
src/view/tiip/kanban/abnormal.vue
+14
-0
No files found.
src/view/tiip/IntReportForms/empAna.vue
View file @
4e105c52
...
@@ -124,7 +124,7 @@ export default {
...
@@ -124,7 +124,7 @@ export default {
resize
(
chart
){
resize
(
chart
){
var
option
=
chart
.
getOption
()
var
option
=
chart
.
getOption
()
if
(
!
option
)
return
;
if
(
!
option
)
return
;
option
.
dataZoom
[
0
].
end
=
option
.
dataZoom
[
0
].
start
+
(
window
.
innerWidth
*
0.9
)
/
option
.
xAxis
[
0
].
data
.
length
//
option.dataZoom[0].end=option.dataZoom[0].start+(window.innerWidth*0.9)/option.xAxis[0].data.length
chart
.
setOption
(
option
)
chart
.
setOption
(
option
)
chart
.
resize
()
chart
.
resize
()
},
},
...
@@ -159,6 +159,7 @@ export default {
...
@@ -159,6 +159,7 @@ export default {
nPaydAmount
:
v
.
nPaydAmount
,
nPaydAmount
:
v
.
nPaydAmount
,
sMonth
:
v
.
sMonth
,
sMonth
:
v
.
sMonth
,
iSalesId
:
v
.
sSalesName
,
iSalesId
:
v
.
sSalesName
,
nReceivedAmount
:
v
.
nReceivedAmount
}
}
})
})
this
.
chartData2
=
this
.
tempChartData2
.
filter
(
v
=>
this
.
chartData1
.
length
>
0
&&
v
.
iSalesId
==
this
.
chartData1
[
0
].
iSalesId
);
this
.
chartData2
=
this
.
tempChartData2
.
filter
(
v
=>
this
.
chartData1
.
length
>
0
&&
v
.
iSalesId
==
this
.
chartData1
[
0
].
iSalesId
);
...
@@ -173,7 +174,7 @@ export default {
...
@@ -173,7 +174,7 @@ export default {
}
}
})
})
this
.
chartData3
=
this
.
tempChartData3
.
filter
(
v
=>
this
.
chartData1
.
length
>
0
&&
v
.
iSalesId
==
this
.
chartData1
[
0
].
iSalesId
)
this
.
chartData3
=
this
.
tempChartData3
.
filter
(
v
=>
this
.
chartData1
.
length
>
0
&&
v
.
iSalesId
==
this
.
chartData1
[
0
].
iSalesId
)
this
.
setChart
1
(
this
.
myChart3
,
this
.
chartData3
,
1
)
this
.
setChart
2
(
this
.
myChart3
,
this
.
chartData3
,
1
)
}
}
},
},
setChart
(
myChart
,
value
){
setChart
(
myChart
,
value
){
...
@@ -252,6 +253,99 @@ export default {
...
@@ -252,6 +253,99 @@ export default {
myChart
.
setOption
(
options
);
myChart
.
setOption
(
options
);
},
},
setChart1
(
myChart
,
value
,
id
){
setChart1
(
myChart
,
value
,
id
){
let
options
=
{
tooltip
:
{
trigger
:
'axis'
,
axisPointer
:
{
type
:
'cross'
,
label
:
{
backgroundColor
:
'#283b56'
}
}
},
grid
:
{
top
:
"40"
,
bottom
:
"20"
,
left
:
'2%'
,
// 与容器左侧的距离
right
:
'5%'
,
// 与容器右侧的距离
containLabel
:
true
},
legend
:
{
data
:[
'比例'
,
'回款金额'
]
},
toolbox
:
{
show
:
true
,
feature
:
{
dataView
:
{
readOnly
:
false
},
restore
:
{},
saveAsImage
:
{}
}
},
xAxis
:
[
{
type
:
'category'
,
boundaryGap
:
true
,
data
:
this
.
chartData2
.
map
(
x
=>
x
.
sMonth
)
},
{
type
:
'category'
,
boundaryGap
:
true
,
data
:
this
.
chartData2
.
map
(
x
=>
x
.
sMonth
)
},
],
yAxis
:
[
{
type
:
'value'
,
scale
:
true
,
name
:
'比例'
,
},
{
type
:
'value'
,
scale
:
true
,
name
:
'回款金额'
,
axisLabel
:
{
margin
:
2
,
formatter
:
function
(
value
,
index
)
{
if
(
value
>=
1000
&&
value
<
10000
){
value
=
Math
.
round
(
value
/
10
)
/
100
+
"千"
;
}
else
if
(
value
>=
10000
&&
value
<
10000000
)
{
value
=
Math
.
round
(
value
/
100
)
/
100
+
"万"
;
}
else
if
(
value
>=
10000000
)
{
value
=
Math
.
round
(
value
/
1000
)
/
10000
+
"千万"
;
}
return
value
;
}
},
}
],
series
:
[
{
name
:
'比例'
,
type
:
'bar'
,
data
:
this
.
chartData2
.
map
(
x
=>
x
.
nPaydAmount
)
},
{
name
:
'回款金额'
,
type
:
'line'
,
xAxisIndex
:
1
,
yAxisIndex
:
1
,
data
:
this
.
chartData2
.
map
(
x
=>
x
.
nReceivedAmount
)
}
],
dataZoom
:
[{
type
:
'inside'
,
show
:
true
,
//flase直接隐藏图形
xAxisIndex
:
[
0
],
left
:
'9%'
,
//滚动条靠左侧的百分比
start
:
0
,
//滚动条的起始位置
end
:
(
window
.
innerWidth
*
0.9
)
/
value
.
length
//滚动条的截止位置(按比例分割你的柱状图x轴长度)
}]
};
myChart
.
setOption
(
options
);
},
setChart2
(
myChart
,
value
,
id
){
let
options
=
{
let
options
=
{
tooltip
:
{
tooltip
:
{
trigger
:
'axis'
,
trigger
:
'axis'
,
...
...
src/view/tiip/kanban/abnormal.vue
View file @
4e105c52
...
@@ -43,12 +43,26 @@
...
@@ -43,12 +43,26 @@
<td
@
click=
"routerPushOperateDetail('销售退货')"
>
<td
@
click=
"routerPushOperateDetail('销售退货')"
>
<div>
{{
Number
(
value
[
'销售退货'
]
||
0
).
toLocaleString
()
}}
</div>
<div>
{{
Number
(
value
[
'销售退货'
]
||
0
).
toLocaleString
()
}}
</div>
</td>
</td>
<td
style=
"width:100px;"
>
<div>
销售退货率
</div>
</td>
<td
style=
"text-decoration:none;"
>
<div>
{{
Number
(
value
[
'销售退货率'
]
||
0
).
toLocaleString
()
*
100
+
'%'
}}
</div>
</td>
</tr>
<tr>
<td
style=
"width:100px;"
>
<td
style=
"width:100px;"
>
<div>
采购退货
</div>
<div>
采购退货
</div>
</td>
</td>
<td
@
click=
"routerPushOperateDetail('采购退货')"
>
<td
@
click=
"routerPushOperateDetail('采购退货')"
>
<div>
{{
Number
(
value
[
'采购退货'
]
||
0
).
toLocaleString
()
}}
</div>
<div>
{{
Number
(
value
[
'采购退货'
]
||
0
).
toLocaleString
()
}}
</div>
</td>
</td>
<td
style=
"width:100px;"
>
<div>
采购退货率
</div>
</td>
<td
style=
"text-decoration:none;"
>
<div>
{{
Number
(
value
[
'采购退货率'
]
||
0
).
toLocaleString
()
*
100
+
'%'
}}
</div>
</td>
</tr>
</tr>
<tr>
<tr>
<td
>
<td
>
...
...
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