提交 | 用户 | 时间
|
850106
|
1 |
<template> |
H |
2 |
<dv-full-screen-container> |
|
3 |
<div id="data-view"> |
|
4 |
<div id="title-bar"> |
|
5 |
<div class="title-text"> |
|
6 |
<img :src="img_title" height="100%"/> |
|
7 |
</div> |
|
8 |
</div> |
|
9 |
<div id="data-body"> |
|
10 |
<product-evaluate v-if="curMode === 'evaluate'"></product-evaluate> |
|
11 |
<product-overview v-if="curMode === 'overview'"></product-overview> |
|
12 |
</div> |
|
13 |
<div id="title-tab"> |
|
14 |
<span style="cursor:pointer"><img :src="img_title_tab_left" @click="changeTab(1)"/></span> |
|
15 |
<span style="cursor:pointer"><img :src="img_title_tab_middle" @click= "back()"/></span> |
|
16 |
<span style="cursor:pointer"><img :src="img_title_tab_right" @click="changeTab(2)"/></span> |
|
17 |
</div> |
|
18 |
</div> |
|
19 |
</dv-full-screen-container> |
|
20 |
</template> |
|
21 |
<script> |
|
22 |
import ProductEvaluate from "@/views/modules/analysis/components/product-evaluate.vue"; |
|
23 |
import ProductOverview from "@/views/modules/analysis/components/product-overview.vue"; |
|
24 |
import {reWriteUrlSVG} from '@/utils/hostUtil' |
|
25 |
|
|
26 |
export default { |
|
27 |
components: {ProductOverview, ProductEvaluate}, |
|
28 |
data() { |
|
29 |
return { |
|
30 |
curMode: 'overview', |
|
31 |
img_title: this.doEeWriteUrlSVG('svg/生产情况分析.svg'), |
|
32 |
img_title_tab_left: this.doEeWriteUrlSVG('svg/生产总览选中.svg'), |
|
33 |
img_title_tab_middle: this.doEeWriteUrlSVG('svg/中间装饰.svg'), |
|
34 |
img_title_tab_right: this.doEeWriteUrlSVG('svg/生产评价未选中.svg') |
|
35 |
} |
|
36 |
}, |
|
37 |
|
|
38 |
methods: { |
|
39 |
doEeWriteUrlSVG(url) { |
|
40 |
return reWriteUrlSVG(url) |
|
41 |
}, |
|
42 |
changeTab(id) { |
|
43 |
if (id == 1) { |
|
44 |
this.curMode = 'overview' |
|
45 |
this.img_title_tab_left = this.doEeWriteUrlSVG('svg/生产总览选中.svg') |
|
46 |
this.img_title_tab_right = this.doEeWriteUrlSVG('svg/生产评价未选中.svg') |
|
47 |
} |
|
48 |
if (id == 2) { |
|
49 |
this.curMode = 'evaluate' |
|
50 |
this.img_title_tab_left = this.doEeWriteUrlSVG('svg/生产总览未选中.svg') |
|
51 |
this.img_title_tab_right = this.doEeWriteUrlSVG('svg/生产评价选中.svg') |
|
52 |
|
|
53 |
} |
|
54 |
}, |
|
55 |
back() { |
|
56 |
this.$router.replace({name: 'analysis-quality'}) |
|
57 |
} |
|
58 |
} |
|
59 |
} |
|
60 |
|
|
61 |
</script> |
|
62 |
<style scoped> |
|
63 |
#dv-full-screen-container { |
|
64 |
box-shadow: 0 0 3px blue; |
|
65 |
background-image: url('./img/bg.png'); |
|
66 |
background-size: 100% 100vh; |
|
67 |
background-repeat: no-repeat; |
|
68 |
} |
|
69 |
|
|
70 |
#data-view { |
|
71 |
width: 100%; |
|
72 |
height: 100vh;; |
|
73 |
padding: 5px; |
|
74 |
display: flex; |
|
75 |
flex-direction: column; |
|
76 |
} |
|
77 |
|
|
78 |
#title-bar { |
|
79 |
width: 100%; |
|
80 |
height: 6vh; |
|
81 |
} |
|
82 |
|
|
83 |
#title-tab { |
|
84 |
width: 100%; |
|
85 |
height: 6vh; |
|
86 |
display: flex; |
|
87 |
flex-direction: row; |
|
88 |
justify-content: center; |
|
89 |
} |
|
90 |
|
|
91 |
.title-text { |
|
92 |
overflow: hidden; |
|
93 |
} |
|
94 |
|
|
95 |
.title-text img { |
|
96 |
width: 100%; |
|
97 |
height: auto; |
|
98 |
object-fit: contain; |
|
99 |
} |
|
100 |
|
|
101 |
#data-body { |
|
102 |
width: 100%; |
|
103 |
height: 88vh; |
|
104 |
display: flex; |
|
105 |
flex-direction: row; |
|
106 |
} |
|
107 |
</style> |