diff --git a/src/views/screenAdaptation/pages/moralEducationCenter/studentClassTeacherManage/studentManage.vue b/src/views/screenAdaptation/pages/moralEducationCenter/studentClassTeacherManage/studentManage.vue index 1028812..c7e38de 100644 --- a/src/views/screenAdaptation/pages/moralEducationCenter/studentClassTeacherManage/studentManage.vue +++ b/src/views/screenAdaptation/pages/moralEducationCenter/studentClassTeacherManage/studentManage.vue @@ -2,7 +2,7 @@
- +
@@ -52,14 +52,15 @@
- {{typeof genderBoy == 'string' ? genderBoy : ' '}}生 + + 男生
{{numrBoy}}人
- - {{!isNaN(boybili) ? boybili : 0}}% + style="height: 100%"> +
@@ -67,14 +68,15 @@
- {{typeof genderGril == 'string' ? genderGril : ' '}}生 + + 女生
{{numGril}}人
- - {{!isNaN(grilbili) ? grilbili : 0}}% + style="height: 100%"> +
@@ -206,10 +208,10 @@ import CommonBox from '../../secondPages/commonBox.vue'; // import CommonModal from './commomModal.vue' import CommonInfo from '../../../common/commonInfo.vue' - import {Carousel, Table, Row, Col, Collapse, Spin, Empty} from 'ant-design-vue'; + import {Carousel, Table, Row, Col, Collapse, Spin, Empty, Progress} from 'ant-design-vue'; import {swiper, swiperSlide} from 'vue-awesome-swiper' //import 'swiper/css/swiper.css' - import * as echarts from 'echarts' + // import * as echarts from 'echarts' import ImgPreview from '../../../common/imgPreview.vue'; export default { @@ -235,8 +237,8 @@ numGril: 0, genderBoy: '', numrBoy: 0, - boybili: 0, - grilbili: 0, + boyRatio: 0, + grilRatio: 0, spinning: false, currentKey: '0', rightTopShow: true, @@ -260,7 +262,7 @@ headText: '', tableData: [], columns: [ - {title: '年级', dataIndex: 'ENTRANCE_YEAR', key: 'ENTRANCE_YEAR', align: "center",}, + {title: '年级', dataIndex: 'entrance_year', key: 'entrance_year', align: "center",},//ENTRANCE_YEAR {title: '人数', dataIndex: 'total', key: 'total', align: "center",}, {title: '男生', dataIndex: 'nan_total', key: 'nan_total', align: "center",}, {title: '女生', dataIndex: 'nv_total', key: 'nv_total', align: "center",}, @@ -271,7 +273,7 @@ headText: '', tableData: [], columns: [ - {title: '年级', dataIndex: 'ENTRANCE_YEAR', key: 'ENTRANCE_YEAR', align: "center",}, + {title: '年级', dataIndex: 'entrance_year', key: 'entrance_year', align: "center",}, {title: '人数', dataIndex: 'total', key: 'total', align: "center",}, {title: '男生', dataIndex: 'nan_total', key: 'nan_total', align: "center",}, {title: '女生', dataIndex: 'nv_total', key: 'nv_total', align: "center",}, @@ -281,7 +283,7 @@ headText: '', tableData: [], columns: [ - {title: '年级', dataIndex: 'ENTRANCE_YEAR', key: 'ENTRANCE_YEAR', align: "center",}, + {title: '年级', dataIndex: 'entrance_year', key: 'entrance_year', align: "center",}, {title: '人数', dataIndex: 'total', key: 'total', align: "center",}, {title: '男生', dataIndex: 'nan_total', key: 'nan_total', align: "center",}, {title: '女生', dataIndex: 'nv_total', key: 'nv_total', align: "center",}, @@ -307,7 +309,7 @@ //学生管理数据1获取 this.getStudentManageData1() //学生管理数据2获取 - this.getStudentManageData2() + // this.getStudentManageData2() //学生管理数据3获取 this.getStudentManageData3() //学生管理数据4获取 @@ -360,6 +362,7 @@ for (let i = 0; i < temp.length; i++) { this.allStudeantTotal += temp[i].total } + this.getStudentManageData2() } }) }, @@ -390,10 +393,8 @@ this.numGril = this.studentManageData2[0].total this.genderBoy = this.studentManageData2[1].XB_NAME this.numrBoy = this.studentManageData2[1].total - this.boybili = parseInt(Number(this.numrBoy) / Number(this.allStudeantTotal) * 100) + 1 - this.grilbili = parseInt(Number(this.numGril) / Number(this.allStudeantTotal) * 100) - this.getEchartsBoy() - this.getEchartsGirl() + this.boyRatio = parseInt(Number(this.numrBoy) / Number(this.allStudeantTotal) * 100) + 1 + this.grilRatio = parseInt(Number(this.numGril) / Number(this.allStudeantTotal) * 100) } }) }, @@ -537,85 +538,85 @@ collapseChange(key) { this.currentKey = key }, - getEchartsBoy() { - echarts.init(document.getElementById('myechartsBoy')).setOption({ - tooltip: { - trigger: 'item', - }, - series: [ - { - type: 'pie', - radius: ['75%', '100%'], - center: ['50%', '50%'], - avoidLabelOverlap: false, - color: ['#93A0BD', '#2196f3'], - labelLine: { - show: false - }, - label: { - show: false, - position: 'center', - //formatter: '{d}%' - }, - tooltip: { - trigger: 'item', - }, - data: [ - { - value: this.allStudeantTotal, - label: { - normal: { - show: true, - } - } - - }, - { - value: this.numrBoy, - label: { - normal: { - show: true, - } - } - } - ] - } - ] - }) - }, - getEchartsGirl() { - echarts.init(document.getElementById('myechartsGril')).setOption({ - tooltip: { - trigger: 'item', - }, - series: [ - { - type: 'pie', - radius: ['75%', '100%'], - center: ['50%', '50%'], - avoidLabelOverlap: false, - color: ['#93A0BD', '#EC808D'], - labelLine: { - show: false - }, - tooltip: { - trigger: 'item', - }, - data: [ - { - value: this.allStudeantTotal, - label: { - normal: { - show: true, - } - } - }, - {value: this.numGril} - ] - } - ] - }) - }, + // getEchartsBoy() { + // echarts.init(document.getElementById('myechartsBoy')).setOption({ + // tooltip: { + // trigger: 'item', + // }, + // series: [ + // { + // type: 'pie', + // radius: ['75%', '100%'], + // center: ['50%', '50%'], + // avoidLabelOverlap: false, + // color: ['#93A0BD', '#2196f3'], + // labelLine: { + // show: false + // }, + // label: { + // show: false, + // position: 'center', + // //formatter: '{d}%' + // }, + // tooltip: { + // trigger: 'item', + // }, + // data: [ + // { + // value: this.allStudeantTotal, + // label: { + // normal: { + // show: true, + // } + // } + // + // }, + // { + // value: this.numrBoy, + // label: { + // normal: { + // show: true, + // } + // } + // } + // ] + // } + // ] + // }) + // }, + // getEchartsGirl() { + // echarts.init(document.getElementById('myechartsGril')).setOption({ + // tooltip: { + // trigger: 'item', + // }, + // series: [ + // { + // type: 'pie', + // radius: ['75%', '100%'], + // center: ['50%', '50%'], + // avoidLabelOverlap: false, + // color: ['#93A0BD', '#EC808D'], + // labelLine: { + // show: false + // }, + // tooltip: { + // trigger: 'item', + // }, + // data: [ + // { + // value: this.allStudeantTotal, + // label: { + // normal: { + // show: true, + // } + // } + // }, + // {value: this.numGril} + // ] + // } + // ] + // }) + // }, getCustomRow() { let obj = {style: {}}; obj['style']['color'] = '#fff'; @@ -672,6 +673,7 @@ ACarousel: Carousel, ASpin: Spin, AEmpty: Empty, + AProgress: Progress, //学生荣誉轮播图 swiper, swiperSlide, @@ -818,7 +820,9 @@ position: absolute; top: 80px; right: 0; - + /deep/ .ant-progress-text { + color: white; + } .boy, .gril { position: relative; width: 140px; @@ -850,7 +854,6 @@ .boy { margin-right: 40px; - .border { position: absolute; display: inline-block;