区域组织维护,动作发展分析

This commit is contained in:
曹辉 2022-08-22 14:31:49 +08:00
parent 9b788f6f74
commit 41fe30c3d9
4 changed files with 487 additions and 21 deletions

View File

@ -0,0 +1,10 @@
import request from '@/utils/request'
// 查询
export function analysis(query) {
return request({
url: '/physical/action/analysis',
method: 'get',
params: query
})
}

View File

@ -119,9 +119,9 @@
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['system:area:remove']"
v-if="scope.row.parentId != 0"
>删除</el-button
>
<!-- v-if="scope.row.id != 1" -->
</template>
</el-table-column>
</el-table>
@ -132,7 +132,7 @@
<el-form-item
label="所属上级区域"
prop="parentId"
v-if="areaList.length != 0"
v-if="areaList.length != 0 && form.parentId != 0"
>
<treeselect
:normalizer="normalizer"
@ -141,13 +141,6 @@
v-model="form.parentId"
/>
</el-form-item>
<!-- <treeselect
v-else-if="form.id != 20"
:normalizer="normalizer"
:options="areaList"
placeholder="请选择所属上级区域"
v-model="form.parentId"
/> -->
<el-form-item label="区域名称" prop="name">
<el-input v-model="form.name" placeholder="请输入区域名称" />
</el-form-item>
@ -323,6 +316,7 @@ export default {
this.form = response.data;
this.open = true;
this.title = "修改区域管理";
console.log(this.form);
});
},
/** 提交按钮 */

View File

@ -0,0 +1,460 @@
<template>
<div class="app-container">
<el-form
ref="queryForm"
size="small"
:inline="true"
v-show="showSearch"
label-width="90px"
>
<el-form-item label="所属幼儿园" prop="categoryName">
<el-button
@click="kindergartenshow = true"
v-if="kindergartenName == '请选择幼儿园'"
style="width: 208px; text-align: left; height: 32px; color: #c0c4cc"
>{{ kindergartenName }}</el-button
>
<el-button
@click="kindergartenshow = true"
style="width: 208px; text-align: left; height: 32px"
v-else
>{{ kindergartenName }}</el-button
>
</el-form-item>
<el-form-item label="班级类型" prop="categoryName" label-width="70px">
<el-select
v-if="analysislist.kindergartenId == ''"
placeholder="请选择"
disabled
@click.native="selecetclick"
v-model="analysislist.classType"
>
</el-select>
<el-select
v-else
v-model="analysislist.classType"
clearable
placeholder="请选择"
>
<el-option
v-for="item in dictValues"
:key="item.name"
:label="item.name"
:value="item.type"
>
</el-option>
</el-select>
</el-form-item>
<el-form-item label="批次成绩" prop="categoryName" label-width="70px">
<el-button
@click="batchCodeshowclick"
style="width: 208px; text-align: left; height: 32px; color: #c0c4cc"
v-if="batchCodeName == '请选择批次'"
>{{ batchCodeName }}</el-button
>
<el-button
@click="batchCodeshowclick"
style="width: 208px; text-align: left; height: 32px"
v-else
>{{ batchCodeName }}</el-button
>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<right-toolbar
:showSearch.sync="showSearch"
@queryTable="getList"
></right-toolbar>
</el-row>
<!-- // -->
<el-dialog
width="500px"
title="选择批次"
:visible.sync="batchCodeshow"
append-to-body
style="margin-top: 20px"
:before-close="batchCodecancel"
>
<el-table :data="testScorelist" align="center" style="margin-top: 0px">
<el-table-column label="请选择" width="70" align="center">
<template slot-scope="scope">
<el-button
type="primary"
style="width: 20px; height: 20px"
v-if="batchCodeId == scope.row.id"
circle
@click="batchCodeclick(scope.row)"
></el-button>
<el-button
v-else
style="width: 15px; height: 15px"
circle
@click="batchCodeclick(scope.row)"
></el-button>
</template>
</el-table-column>
<el-table-column
property="batchCode"
label="批次编号"
width="190"
align="center"
/>
<el-table-column
property="batchName"
label="批次名称"
width="190"
align="center"
/>
</el-table>
<pagination
v-show="total4 > 0"
:total="total4"
:page.sync="testqueryParams.pageNum"
:limit.sync="testqueryParams.pageSize"
@pagination="testScore"
/>
</el-dialog>
<!-- // -->
<el-dialog
width="850px"
title="选择所属幼儿园"
:visible.sync="kindergartenshow"
append-to-body
:before-close="kindergartencancel"
>
<el-table :data="kindergartenList">
<el-table-column label="请选择" width="70" align="center">
<template slot-scope="scope">
<el-button
type="primary"
style="width: 15px; height: 15px"
circle
@click="kindergartenNameclick(scope.row)"
v-if="kindergartenId == scope.row.id"
></el-button>
<el-button
v-else
style="width: 15px; height: 15px"
circle
@click="kindergartenNameclick(scope.row)"
></el-button>
</template>
</el-table-column>
<el-table-column
property="kindergartenName"
label="幼儿园名字"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="kindergartenAddress"
label="幼儿园地址"
width="150"
align="center"
>
</el-table-column>
<el-table-column
label="幼儿园所在组织"
align="center"
prop="organizeName"
width="150"
>
</el-table-column>
<el-table-column
property="contacts"
label="联系人"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="phone"
label="联系电话"
width="150"
align="center"
>
</el-table-column>
</el-table>
<pagination
v-show="total1 > 0"
:total="total1"
:page.sync="kqueryParams.pageNum"
:limit.sync="kqueryParams.pageSize"
@pagination="getList"
/>
</el-dialog>
<el-row v-show="itemshow">
<el-table
:data="physicalActionList"
style="width: 1111px; margin: 20px auto"
>
<el-table-column :label="classTypeName" width="150" align="center">
<el-table-column
prop="itemName"
label="项目"
width="150"
align="center"
>
</el-table-column>
<el-table-column label="男孩" align="center">
<el-table-column
prop="maleAvgScore"
label="平均值"
width="120"
align="center"
>
</el-table-column>
<el-table-column
prop="maleCityAvgScore"
label="全市平均值"
width="120"
align="center"
>
</el-table-column>
<el-table-column
prop="malePassCount"
label="合格人数"
width="120"
align="center"
>
</el-table-column>
<el-table-column
prop="malePassRate"
label="合格率"
width="120"
align="center"
>
<template slot-scope="scope"
>{{ scope.row.malePassRate }}%</template
>
</el-table-column>
</el-table-column>
<el-table-column label="女孩" align="center">
<el-table-column
prop="feMaleAvgScore"
label="平均值"
width="120"
align="center"
>
</el-table-column>
<el-table-column
prop="feMaleCityAvgScore"
label="全市平均值"
width="120"
align="center"
>
</el-table-column>
<el-table-column
prop="feMalePassCount"
label="合格人数"
width="120"
align="center"
>
</el-table-column>
<el-table-column
prop="feMalePassRate"
label="合格率"
width="120"
align="center"
>
<template slot-scope="scope"
>{{ scope.row.feMalePassRate }}%</template
>
</el-table-column>
</el-table-column>
</el-table-column>
</el-table>
</el-row>
<el-row :gutter="20" v-if="itemshow2">
<el-col :span="24" :offset="0">
<el-card>
<div slot="header" style="text-align: center">
<img style="width: 40px" src="@/icons/笑脸.png" alt="" />
<div><!-- card title -->此批次暂无结果分析</div>
</div>
<!-- card body -->
</el-card>
</el-col>
</el-row>
</div>
</template>
<script>
import * as echarts from "echarts";
import {
listKindergartenInfo,
tKindergartenInfo,
} from "@/api/system/kindergartenInfo";
import { getRoleInfo, testScoreBatch } from "@/api/system/quality";
import { analysis } from "@/api/system/development";
export default {
name: "classconstitution",
data() {
return {
itemshow: false,
itemshow2: false,
total1: 0,
total4: 0,
//
kindergartenshow: false,
batchCodeshow: false,
//
ClassType: "class_type",
//
showSearch: true,
//
form: {},
//
kqueryParams: {
pageNum: 1,
pageSize: 10,
organizeId: null,
kindergartenName: null,
kindergartenAddress: null,
kindergartenType: null,
phone: null,
contacts: null,
},
//list
kindergartenList: [],
//
kindergartenName: "请选择幼儿园",
//ID
kindergartenId: "",
//
batchCodeName: "请选择批次",
//ID
batchCodeId: "",
//list
testScorelist: [],
//
analysislist: {
kindergartenId: "",
classType: "",
batchCode: "",
// kindergartenId: "21",
// classType: "SMALL_CLASS",
// batchCode: "PC202208030005",
},
//
testqueryParams: {
pageNum: 1,
pageSize: 10,
},
dictValues: [],
classTypeName: "",
physicalActionList: [],
};
},
created() {
this.getList();
this.class();
// this.analysisinfo();
},
methods: {
selecetclick() {
if (this.analysislist.kindergartenId == "") {
this.$message.error("请先选择幼儿园");
} else {
}
},
//
analysisinfo() {
analysis(this.analysislist).then((res) => {
if (res.data) {
var obj = res.data;
this.physicalActionList = obj.physicalActionList;
this.classTypeName = res.data.classTypeName;
this.itemshow = true;
this.itemshow2 = false;
} else {
this.itemshow = false;
this.itemshow2 = true;
}
});
},
//
batchCodeclick(row) {
this.batchCodeName = row.batchName;
this.batchCodeId = row.id;
this.analysislist.batchCode = row.batchCode;
this.batchCodeshow = false;
this.physicalActionList = [];
this.analysisinfo();
},
//
batchCodeshowclick() {
if (this.analysislist.classType == "") {
this.$message.error("请先选择班级类型");
} else {
this.testScore();
this.batchCodeshow = true;
}
},
//
testScore() {
testScoreBatch(this.testqueryParams).then((res) => {
this.testScorelist = res.rows;
this.total4 = res.total;
});
},
//
batchCodecancel() {
this.batchCodeshow = false;
},
//
kindergartencancel() {
this.kindergartenshow = false;
},
//
kindergartenNameclick(row) {
this.analysislist.kindergartenId = row.id;
this.kindergartenName = row.kindergartenName;
this.kindergartenId = row.id;
this.kindergartenshow = false;
},
//
class() {
tKindergartenInfo(this.ClassType).then((res) => {
res.data.forEach((e) => {
var obj = {
name: e.dictLabel,
type: e.dictValue,
};
this.dictValues.push(obj);
});
});
},
getList() {
//
getRoleInfo().then((res) => {
console.log(res);
});
//list
listKindergartenInfo(this.kqueryParams).then((response) => {
this.kindergartenList = response.rows;
this.total1 = response.total;
// console.log(this.kindergartenList);
});
},
//
reset() {
this.form = {};
this.resetForm("form");
},
},
};
</script>

View File

@ -17,14 +17,6 @@
style="width: 300px"
/>
</el-form-item>
<!-- <el-input
v-model="queryParams.parentId"
placeholder="请输入组织名称"
clearable
@keyup.enter.native="handleQuery"
/> -->
<el-form-item label="区域名称" prop="">
<treeselect
:normalizer="normalizer4"
@ -153,10 +145,10 @@
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-if="scope.row.parentId != 0"
v-hasPermi="['system:area:remove']"
v-if="scope.row.id != 1"
>删除</el-button
>
>删除
</el-button>
</template>
</el-table-column>
</el-table>
@ -165,7 +157,11 @@
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="110px">
<el-form-item label="所属上级组织" prop="parentId" v-if="form.id != 1">
<el-form-item
label="所属上级组织"
prop="parentId"
v-if="List.length != 0 && form.parentId != 0"
>
<treeselect
:normalizer="normalizer2"
:options="List"
@ -357,11 +353,13 @@ export default {
getList() {
listArea(this.queryParams).then((response) => {
this.areaList = this.handleTree(response.data);
console.log(this.areaList);
});
this.loading = true;
list(this.queryParams).then((response) => {
this.List = this.handleTree(response.data);
this.List2 = this.List;
console.log(this.List);
this.loading = false;
});
},
@ -447,6 +445,10 @@ export default {
/** 提交按钮 */
submitForm() {
if (this.List.length == 0) {
this.form.parentId = 0;
}
if (this.form.phone == "" || this.form.phone.toString().length == 11) {
this.$refs["form"].validate((valid) => {
if (valid) {