From 60be35fec8bced93ae8b5c55fc554291a819adf9 Mon Sep 17 00:00:00 2001
From: zhangxiaoxu123456 <zxx19900626>
Date: 星期日, 24 四月 2022 12:13:59 +0800
Subject: [PATCH] 人事人才
---
src/pages/show/personnelTalents/personnelTalentsChild/PersonnelTalents_UnitPersonnel.vue | 300 +++++++++++++++++++++++++++++++----------------------------
1 files changed, 159 insertions(+), 141 deletions(-)
diff --git a/src/pages/show/personnelTalents/personnelTalentsChild/PersonnelTalents_UnitPersonnel.vue b/src/pages/show/personnelTalents/personnelTalentsChild/PersonnelTalents_UnitPersonnel.vue
index ebf0307..818b86f 100644
--- a/src/pages/show/personnelTalents/personnelTalentsChild/PersonnelTalents_UnitPersonnel.vue
+++ b/src/pages/show/personnelTalents/personnelTalentsChild/PersonnelTalents_UnitPersonnel.vue
@@ -2,7 +2,7 @@
<div class="PersonnelTalents_unitPersonnel--warp">
<div class="PT_unitPersonnel--table">
<el-table
- :max-height="640"
+ :max-height="tableHeight"
:data="tableData"
stripe
border
@@ -36,17 +36,18 @@
<el-table-column label="鍏ㄧ渷鎺掍綅" prop="quanshengpaiming2"></el-table-column>
</el-table-column>
</el-table>
- <!-- 鍗曢�夋 -->
- <div class="PT_unitPersonnel--echart-box">
- <div class="PT_navEchart--title">
- <el-radio-group v-model="checkedCategory">
- <el-radio v-for="categoryItem in careGory" :label="categoryItem" :key="categoryItem">{{ categoryItem }}
- </el-radio>
- </el-radio-group>
- </div>
- <div class="PT_unitPersonnel--Echarts"></div>
- </div>
</div>
+ <!-- 鍗曢�夋 -->
+ <div class="PT_unitPersonnel--echart-box">
+ <div class="PT_navEchart--title">
+ <el-radio-group v-model="checkedCategory">
+ <el-radio v-for="categoryItem in careGory" :label="categoryItem" :key="categoryItem">{{ categoryItem }}
+ </el-radio>
+ </el-radio-group>
+ </div>
+ <div class="PT_unitPersonnel--Echarts"></div>
+ </div>
+
</div>
</template>
@@ -140,7 +141,8 @@
},
],
checkedCategory: '浜嬩笟鍗曚綅',
- careGory: CARE_GORY
+ careGory: CARE_GORY,
+ tableHeight: window.innerHeight - nowSize(900)
}
},
mounted() {
@@ -168,122 +170,131 @@
}
},
Init_echarts() {
- const option = {
- color: ['#FF5151', '#51FF5D', '#FFD151'],
- title: {
- text: '鍘嗗勾鍏ㄥ競灞呮皯浜哄潎鍙敮閰嶆敹鍏ュ垎鏋愬浘',
- left: 'center',
- top: '5%',
- textStyle: {
- color: '#FFFFFF',
- fontSize: nowSize(30)
- }
- },
- itemStyle: {
- normal: {
- lineStyle: {
- width: 3, //鎶樼嚎瀹藉害
- }
- }
- },
- tooltip: {
- trigger: 'axis'
- },
- legend: {
- right: '2%',
- top: 'center',
- orient: 'vertical',
- itemWidth: nowSize(30),
- itemHeight: nowSize(4),
- itemGap: nowSize(80),
- textStyle: {
- color: '#FFFFFF',
- fontSize: nowSize(24),
- }
- },
- grid: {
- left: '22%',
- top: '25%',
- right: '25%',
- bottom: '2%',
- containLabel: true
- },
- xAxis: {
- name: '鍗曚綅锛氬勾',
- nameTextStyle: {
- color: '#FFFFFF',
- fontSize: nowSize(24)
- },
- nameGap: nowSize(92),// 鍧愭爣杞村悕绉颁笌杞寸嚎涔嬮棿鐨勮窛绂汇��
- type: 'category',
- boundaryGap: false,// 鍧愭爣杞翠袱绔暀鐧�
- data: ['2017骞�', '2018骞�', '2019骞�', '2020骞�', '2021骞�'],
- axisLabel: {
- show: true,
- textStyle: {
- color: '#fff',
- fontSize: nowSize(24)
- },
- },
- axisLine: {
- lineStyle: {
- color: '#999999',
- width: 1, //杩欓噷鏄潗鏍囪酱鐨勫搴�,鍙互鍘绘帀
- type: 'solid'
- }
- },
- splitLine: {
- show: false
- }
- },
- yAxis: {
- name: '鍗曚綅锛氬勾',
- nameTextStyle: {
- color: '#FFFFFF',
- fontSize: nowSize(24)
- },
- nameGap: nowSize(30),// 鍧愭爣杞村悕绉颁笌杞寸嚎涔嬮棿鐨勮窛绂汇��
- type: 'value',
- axisLabel: {
- show: true,
- textStyle: {
- color: '#fff',
- fontSize: nowSize(24)
- },
- },
- axisLine: {
- lineStyle: {
- color: '#999999',
- width: 1, //杩欓噷鏄潗鏍囪酱鐨勫搴�,鍙互鍘绘帀
- type: "solid"
- }
- },
- splitLine: {
- show: false
- },
- },
- series: [
- {
- name: '灞呮皯浜哄潎鍙敮閰嶆敹鍏�',
- type: 'line',
- data: [120, 132, 101, 134, 90, 230]
- },
- {
- name: '鍩庨晣灞呮皯',
- type: 'line',
- data: [220, 182, 191, 234, 290, 330]
- },
- {
- name: '鍐滄潙灞呮皯',
- type: 'line',
- data: [150, 232, 201, 154, 190, 330]
- }
- ]
- };
const myChart = this.$echarts.init(document.querySelector('.PT_unitPersonnel--Echarts'));
+ const option = {
+ color: ['#FF5151', '#51FF5D', '#FFD151'],
+ title: {
+ text: '鍘嗗勾鍏ㄥ競灞呮皯浜哄潎鍙敮閰嶆敹鍏ュ垎鏋愬浘',
+ left: 'center',
+ top: '5%',
+ textStyle: {
+ color: '#FFFFFF',
+ fontSize: nowSize(30)
+ }
+ },
+ itemStyle: {
+ normal: {
+ lineStyle: {
+ width: 3, //鎶樼嚎瀹藉害
+ }
+ }
+ },
+ tooltip: {
+ trigger: 'axis'
+ },
+ legend: {
+ right: '2%',
+ top: 'center',
+ orient: 'vertical',
+ itemWidth: nowSize(30),
+ itemHeight: nowSize(4),
+ itemGap: nowSize(80),
+ textStyle: {
+ color: '#FFFFFF',
+ fontSize: nowSize(24),
+ }
+ },
+ grid: {
+ left: '2%',
+ top: '25%',
+ right: '18%',
+ bottom: '0',
+ containLabel: true
+ },
+ xAxis: {
+ name: '鍗曚綅锛氬勾',
+ nameTextStyle: {
+ color: '#FFFFFF',
+ fontSize: nowSize(24)
+ },
+ nameGap: nowSize(92),// 鍧愭爣杞村悕绉颁笌杞寸嚎涔嬮棿鐨勮窛绂汇��
+ type: 'category',
+ boundaryGap: false,// 鍧愭爣杞翠袱绔暀鐧�
+ data: ['2017骞�', '2018骞�', '2019骞�', '2020骞�', '2021骞�'],
+ axisLabel: {
+ show: true,
+ textStyle: {
+ color: '#fff',
+ fontSize: nowSize(24)
+ },
+ },
+ axisLine: {
+ lineStyle: {
+ color: '#999999',
+ width: 1, //杩欓噷鏄潗鏍囪酱鐨勫搴�,鍙互鍘绘帀
+ type: 'solid'
+ }
+ },
+ splitLine: {
+ show: false
+ }
+ },
+ yAxis: {
+ name: '鍗曚綅锛氬勾',
+ nameTextStyle: {
+ color: '#FFFFFF',
+ fontSize: nowSize(24)
+ },
+ nameGap: nowSize(30),// 鍧愭爣杞村悕绉颁笌杞寸嚎涔嬮棿鐨勮窛绂汇��
+ type: 'value',
+ axisLabel: {
+ show: true,
+ textStyle: {
+ color: '#fff',
+ fontSize: nowSize(24)
+ },
+ },
+ axisLine: {
+ lineStyle: {
+ color: '#999999',
+ width: 1, //杩欓噷鏄潗鏍囪酱鐨勫搴�,鍙互鍘绘帀
+ type: "solid"
+ }
+ },
+ splitLine: {
+ show: false
+ },
+ },
+ series: [
+ {
+ name: '灞呮皯浜哄潎鍙敮閰嶆敹鍏�',
+ type: 'line',
+ data: [120, 132, 101, 134, 90, 230]
+ },
+ {
+ name: '鍩庨晣灞呮皯',
+ type: 'line',
+ data: [220, 182, 191, 234, 290, 330]
+ },
+ {
+ name: '鍐滄潙灞呮皯',
+ type: 'line',
+ data: [150, 232, 201, 154, 190, 330]
+ }
+ ]
+ };
option && myChart.setOption(option)
+ },
+ getHeight() {
+ this.tableHeight = window.innerHeight - nowSize(900)
}
- }
+ },
+ created() {
+ window.addEventListener('resize',this.getHeight)
+ },
+ destroy() {
+ window.addEventListener('resize',this.getHeight)
+ }
}
</script>
<style lang="scss">
@@ -346,6 +357,7 @@
border-bottom: 1px solid #8E8E8E;
}
}
+
.PT_navEchart--title {
.el-radio {
width: 1.171875rem;
@@ -357,7 +369,7 @@
}
.el-radio__input {
- margin-bottom: 5px;
+ margin-bottom: 0.01953125rem;
&.is-checked {
.el-radio__inner {
@@ -374,9 +386,9 @@
}
.el-radio__inner {
- width: 40px;
- height: 40px;
- margin-right: 17px;
+ width: 0.15625rem;
+ height: 0.15625rem;
+ margin-right: 0.06640625rem;
background: transparent;
border-radius: 1%;
box-sizing: content-box;
@@ -397,30 +409,36 @@
.PersonnelTalents_unitPersonnel--warp {
width: 100%;
height: 100%;
+
.PT_unitPersonnel--table {
width: 100%;
- height: 100%;
}
- .PT_unitPersonnel--Echarts {
+
+ .PT_unitPersonnel--echart-box {
width: 100%;
- height:100%;
- //height: 600px;
- display: inline-block;
- }
- .PT_unitPersonnel--echart-box{
- width: 100%;
- margin-top: 0.234375rem /* 60/256 */;
- height: calc(100% - 640Px - 0.254375rem /* 60/256 */);
+ margin-top: 0.234375rem /* 60/256 */
+ ;
+ height: calc(100% - 2.34375rem /* 600/256 */ - 0.254375rem /* 60/256 */
+ );
position: relative;
+
.PT_navEchart--title {
- width: 1.171875rem;
+ width: 1px;
display: inline-block;
position: absolute;
- left: 100px;
+ left: 0.390625rem;
top: 50%;
transform: translateY(-50%);
}
+
+ .PT_unitPersonnel--Echarts {
+ width: 85%;
+ height: 100%;
+ position: absolute;
+ left: 1.2890625rem;
+ display: inline-block;
+ }
}
}
--
Gitblit v1.9.1