This commit is contained in:
曹辉 2023-04-14 14:46:32 +08:00
parent 106d3b1f56
commit b6468ff3a3
33 changed files with 1311 additions and 3207 deletions

View File

@ -369,7 +369,6 @@ export default {
listKindergartenInfo(this.kqueryParams).then((response) => { listKindergartenInfo(this.kqueryParams).then((response) => {
this.kindergartenList = response.rows; this.kindergartenList = response.rows;
this.total1 = response.total; this.total1 = response.total;
// console.log(this.kindergartenList);
}); });
}, },
kinresetQuery() { kinresetQuery() {
@ -389,7 +388,6 @@ export default {
// //
getRoleInfo().then((res) => { getRoleInfo().then((res) => {
var user = res.data.roleKeys; var user = res.data.roleKeys;
console.log(user);
if (user.includes("enchou")) { if (user.includes("enchou")) {
return; return;
} else if (user.includes("teacher")) { } else if (user.includes("teacher")) {
@ -414,7 +412,6 @@ export default {
listKindergartenInfo(this.kqueryParams).then((response) => { listKindergartenInfo(this.kqueryParams).then((response) => {
this.kindergartenList = response.rows; this.kindergartenList = response.rows;
this.total1 = response.total; this.total1 = response.total;
// console.log(this.kindergartenList);
}); });
}, },
// //

View File

@ -630,7 +630,6 @@ export default {
listKindergartenInfo(this.kqueryParams).then((response) => { listKindergartenInfo(this.kqueryParams).then((response) => {
this.kindergartenList = response.rows; this.kindergartenList = response.rows;
this.total1 = response.total; this.total1 = response.total;
// console.log(this.kindergartenList);
}); });
}, },
// //
@ -683,7 +682,6 @@ export default {
) { ) {
this.$emit("itemlist", this.studentId, this.batchCode); this.$emit("itemlist", this.studentId, this.batchCode);
} }
console.log(this.batchCode, this.studentId);
}, },
// //
batchCodeshowclick() { batchCodeshowclick() {
@ -692,7 +690,6 @@ export default {
}, },
// //
batchCodeclick(row) { batchCodeclick(row) {
console.log(row);
this.batchCode = row.batchCode; this.batchCode = row.batchCode;
this.batchName = row.batchName; this.batchName = row.batchName;
this.batchCodeshow = false; this.batchCodeshow = false;
@ -744,12 +741,10 @@ export default {
listStudentInfo(this.studentqueryParams).then((res) => { listStudentInfo(this.studentqueryParams).then((res) => {
this.studentInfoList = res.rows; this.studentInfoList = res.rows;
this.total3 = res.total; this.total3 = res.total;
// console.log(this.studentInfoList);
}); });
}, },
// //
classshowclick() { classshowclick() {
console.log(this.classqueryParams);
if ( if (
this.classqueryParams.kindergartenId == "" || this.classqueryParams.kindergartenId == "" ||
this.classqueryParams.kindergartenId == null this.classqueryParams.kindergartenId == null
@ -759,7 +754,6 @@ export default {
this.classshow = true; this.classshow = true;
this.classinfo(); this.classinfo();
} }
// console.log(this.classqueryParams);
}, },
// //
studentcancel() { studentcancel() {
@ -779,7 +773,6 @@ export default {
}, },
// //
classclick(row) { classclick(row) {
// console.log(row);
this.className = row.className; this.className = row.className;
this.classId = row.id; this.classId = row.id;
this.studentqueryParams.classId = row.id; this.studentqueryParams.classId = row.id;
@ -812,7 +805,6 @@ export default {
listClassinfo(this.classqueryParams).then((response) => { listClassinfo(this.classqueryParams).then((response) => {
this.classinfoList = response.rows; this.classinfoList = response.rows;
this.total2 = response.total; this.total2 = response.total;
// console.log(this.classinfoList);
}); });
}, },
@ -828,7 +820,6 @@ export default {
this.kindergartenId = res.data.kindergartenId; this.kindergartenId = res.data.kindergartenId;
this.classqueryParams.kindergartenId = res.data.kindergartenId; this.classqueryParams.kindergartenId = res.data.kindergartenId;
this.kindergartenName = String(res.data.kindergartenName); this.kindergartenName = String(res.data.kindergartenName);
console.log(1, this.kindergartenName);
return; return;
} else if (user.includes("parent")) { } else if (user.includes("parent")) {
return; return;
@ -838,7 +829,6 @@ export default {
listKindergartenInfo(this.kqueryParams).then((response) => { listKindergartenInfo(this.kqueryParams).then((response) => {
this.kindergartenList = response.rows; this.kindergartenList = response.rows;
this.total1 = response.total; this.total1 = response.total;
// console.log(this.kindergartenList);
}); });
}, },
// //

View File

@ -167,7 +167,6 @@ export default {
this.analysisinfo(); this.analysisinfo();
}, },
kinbatlist(kindergartenId, batchCode) { kinbatlist(kindergartenId, batchCode) {
console.log(kindergartenId, batchCode);
this.analysisqueryParams.kindergartenId = kindergartenId; this.analysisqueryParams.kindergartenId = kindergartenId;
this.analysisqueryParams.batchCode = batchCode; this.analysisqueryParams.batchCode = batchCode;
if (batchCode == "请选择批次") { if (batchCode == "请选择批次") {
@ -182,7 +181,6 @@ export default {
this.itemshow = false; this.itemshow = false;
} else { } else {
this.analysislist = res.data; this.analysislist = res.data;
console.log(this.analysislist);
this.options(); this.options();
var app = {}; var app = {};
@ -415,7 +413,6 @@ export default {
}); });
// //
getRoleInfo().then((res) => { getRoleInfo().then((res) => {
console.log(res);
var user = res.data.roleKeys; var user = res.data.roleKeys;
if (user.includes("enchou")) { if (user.includes("enchou")) {
return; return;

View File

@ -283,7 +283,6 @@ export default {
this.actionforeach(); this.actionforeach();
this.itemshow = true; this.itemshow = true;
this.itemshow2 = false; this.itemshow2 = false;
// console.log(this.actionlist);
} }
}); });
}, },
@ -303,7 +302,6 @@ export default {
getList() { getList() {
// //
getRoleInfo().then((res) => { getRoleInfo().then((res) => {
console.log(res);
this.classqueryParams.kindergartenId = res.data.kindergartenId; this.classqueryParams.kindergartenId = res.data.kindergartenId;
var user = res.data.roleKeys; var user = res.data.roleKeys;
if (user.includes("enchou")) { if (user.includes("enchou")) {

View File

@ -283,7 +283,6 @@ export default {
// e.code = Number(e.code); // e.code = Number(e.code);
// }); // });
this.areaList = this.handleTree(response.data); this.areaList = this.handleTree(response.data);
console.log(this.areaList);
this.loading = false; this.loading = false;
}); });
}, },
@ -343,7 +342,6 @@ export default {
this.form = response.data; this.form = response.data;
this.open = true; this.open = true;
this.title = "修改区域管理"; this.title = "修改区域管理";
console.log(this.form);
}); });
}, },
/** 提交按钮 */ /** 提交按钮 */
@ -352,7 +350,6 @@ export default {
this.form2.code = this.form.code; this.form2.code = this.form.code;
this.form2.sort = this.form.sort; this.form2.sort = this.form.sort;
this.form2.parentId = this.form.parentId; this.form2.parentId = this.form.parentId;
console.log(this.form);
if (this.areaList.length == 0) { if (this.areaList.length == 0) {
this.form.parentId = 0; this.form.parentId = 0;
} }

View File

@ -325,7 +325,6 @@ export default {
this.ClassListinfo(); this.ClassListinfo();
}, },
kinbatlist(kindergartenId, batchCode, text) { kinbatlist(kindergartenId, batchCode, text) {
console.log(kindergartenId, batchCode, text);
if (text == 1) { if (text == 1) {
if (this.ClassListlist.kindergartenId != "") { if (this.ClassListlist.kindergartenId != "") {
this.classqueryParams.kindergartenId = ""; this.classqueryParams.kindergartenId = "";
@ -345,7 +344,6 @@ export default {
}, },
ClassListinfo() { ClassListinfo() {
ClassList(this.ClassListlist).then((res) => { ClassList(this.ClassListlist).then((res) => {
console.log(res);
var yseries = []; var yseries = [];
var name = ""; var name = "";
var names = []; var names = [];
@ -371,11 +369,8 @@ export default {
list.push(el.categoryId); list.push(el.categoryId);
}); });
}); });
console.log(list);
this.categoryScoreList = res.data.categoryScoreList; this.categoryScoreList = res.data.categoryScoreList;
let yname = []; let yname = [];
console.log(this.categoryScoreList);
this.categoryScoreList.forEach((el) => { this.categoryScoreList.forEach((el) => {
yname.push(el.className); yname.push(el.className);
var listname = list.map((e) => { var listname = list.map((e) => {
@ -389,7 +384,6 @@ export default {
return num; return num;
}); });
this.listname = listname; this.listname = listname;
console.log(list);
var list1 = list.map((e) => { var list1 = list.map((e) => {
var num = 0; var num = 0;
var number = el.categoryScoreList.findIndex( var number = el.categoryScoreList.findIndex(
@ -402,13 +396,10 @@ export default {
num = 0; num = 0;
return num; return num;
} }
console.log(num);
return num; return num;
}); });
el.list = list1; el.list = list1;
}); });
console.log(this.categoryScoreList);
console.log(this.listname);
for (var i = 0; i < this.listname.length; i++) { for (var i = 0; i < this.listname.length; i++) {
name = name =
this.categoryScoreList[0].categoryScoreList[i].categoryName; this.categoryScoreList[0].categoryScoreList[i].categoryName;
@ -426,19 +417,12 @@ export default {
}, },
data: ydata, data: ydata,
}; };
console.log(ydata);
yseries.push(obj); yseries.push(obj);
names.push(name); names.push(name);
} }
this.listname = []; this.listname = [];
console.log(yseries);
var myChart = echarts.init(document.getElementById("chart")); var myChart = echarts.init(document.getElementById("chart"));
var option; var option;
const posList = [ const posList = [
"left", "left",
"right", "right",
@ -573,7 +557,6 @@ export default {
}, },
// //
classclick(row) { classclick(row) {
// console.log(row);
this.className = row.className; this.className = row.className;
this.classId = row.id; this.classId = row.id;
this.ClassListlist.classId = row.id; this.ClassListlist.classId = row.id;
@ -599,7 +582,6 @@ export default {
getList() { getList() {
// //
getRoleInfo().then((res) => { getRoleInfo().then((res) => {
console.log(res);
var user = res.data.roleKeys; var user = res.data.roleKeys;
if (user.includes("enchou")) { if (user.includes("enchou")) {
return; return;

View File

@ -385,9 +385,7 @@ export default {
data() { data() {
// //
var checkMobile = (rule, value, cb) => { var checkMobile = (rule, value, cb) => {
console.log(value);
var str = String(value); var str = String(value);
console.log(str);
// //
const regMobile = const regMobile =
/^1(3[0-9]|4[01456879]|5[0-35-9]|6[2567]|7[0-8]|8[0-9]|9[0-35-9])\d{8}$/ /^1(3[0-9]|4[01456879]|5[0-35-9]|6[2567]|7[0-8]|8[0-9]|9[0-35-9])\d{8}$/
@ -395,7 +393,6 @@ export default {
// /^(?:(?:\+|0086))?1(?:(?:3[\d])|(?:4[5-79])|(?:5[0-35-9])|(?:6[5-7])|(?:7[0-8])|(?:8[\d])|(?:9[0-9]))\d{8}$/; // /^(?:(?:\+|0086))?1(?:(?:3[\d])|(?:4[5-79])|(?:5[0-35-9])|(?:6[5-7])|(?:7[0-8])|(?:8[\d])|(?:9[0-9]))\d{8}$/;
const reg = /^(0[0-9]{2,3}\-)([2-9][0-9]{6,7})+(\-[0-9]{1,4})?$/; const reg = /^(0[0-9]{2,3}\-)([2-9][0-9]{6,7})+(\-[0-9]{1,4})?$/;
const isTel = reg.test(value); const isTel = reg.test(value);
if (str.length == 11) { if (str.length == 11) {
if (regMobile.test(str)) { if (regMobile.test(str)) {
return cb(); return cb();
@ -407,7 +404,6 @@ export default {
} }
cb(new Error("请输入正确的联系电话")); cb(new Error("请输入正确的联系电话"));
}; };
return { return {
// //
loading: true, loading: true,
@ -512,7 +508,6 @@ export default {
this.total2 = response.total; this.total2 = response.total;
}); });
listClassinfo(this.queryParams).then((response) => { listClassinfo(this.queryParams).then((response) => {
console.log(response);
this.classinfoList = response.rows; this.classinfoList = response.rows;
this.total = response.total; this.total = response.total;
this.loading = false; this.loading = false;
@ -600,7 +595,6 @@ export default {
getClassinfo(id).then((response) => { getClassinfo(id).then((response) => {
response.data.phone = Number(response.data.phone); response.data.phone = Number(response.data.phone);
this.form = response.data; this.form = response.data;
console.log(this.form);
this.kindergartenName = this.form.kindergartenName; this.kindergartenName = this.form.kindergartenName;
this.open = true; this.open = true;
this.title = "修改班级信息"; this.title = "修改班级信息";

View File

@ -1,33 +1,15 @@
<template> <template>
<div class="app-container"> <div class="app-container">
<el-form <el-form ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="90px">
ref="queryForm" <student style="width: 500px; display: inline" @itemlist="itemlists"></student>
size="small"
:inline="true"
v-show="showSearch"
label-width="90px"
>
<student
style="width: 500px; display: inline"
@itemlist="itemlists"
></student>
<el-form-item> <el-form-item>
<el-button <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">查看</el-button>
type="primary"
icon="el-icon-search"
size="mini"
@click="handleQuery"
>查看</el-button
>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-row :gutter="10" class="mb8"> <el-row :gutter="10" class="mb8">
<right-toolbar <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
:showSearch.sync="showSearch"
@queryTable="getList"
></right-toolbar>
</el-row> </el-row>
<el-row v-show="itemshow"> <el-row v-show="itemshow">
@ -46,33 +28,22 @@
" "
> >
<div style="display: flex; justify-content: space-around"> <div style="display: flex; justify-content: space-around">
<div class="cell" style="width: 20%"> <div class="cell" style="width: 20%">姓名:{{ sythesizestudent.studentName }}</div>
姓名:{{ sythesizestudent.studentName }} <div
</div> class="cell"
<div class="cell" style="width: 20%"> style="width: 20%"
性别:{{ sythesizestudent.studentSex == "MALE" ? "男" : "女" }} >性别:{{ sythesizestudent.studentSex == "MALE" ? "男" : "女" }}</div>
</div> <div class="cell" style="width: 20%">年龄:{{ sythesizestudent.studentAge }}</div>
<div class="cell" style="width: 20%"> <div class="cell" style="width: 20%">民族:{{ sythesizestudent.nationName }}</div>
年龄:{{ sythesizestudent.studentAge }} <div class="cell" style="width: 20%">ID:{{ sythesizestudent.studentNumber }}</div>
</div>
<div class="cell" style="width: 20%">
民族:{{ sythesizestudent.nationName }}
</div>
<div class="cell" style="width: 20%">
ID:{{ sythesizestudent.studentNumber }}
</div>
</div> </div>
<div style="display: flex; margin-top: 20px"> <div style="display: flex; margin-top: 20px">
<div class="cell" style="width: 60%"> <div class="cell" style="width: 60%">所属幼儿园:{{ sythesizestudent.kindergartenName }}</div>
所属幼儿园:{{ sythesizestudent.kindergartenName }}
</div>
<div class="cell">班级:{{ sythesizestudent.className }}</div> <div class="cell">班级:{{ sythesizestudent.className }}</div>
</div> </div>
<div style="width: 60%; margin-top: 20px"> <div style="width: 60%; margin-top: 20px">
<div class="cell"> <div class="cell">地址:{{ sythesizestudent.kindergartenAddress }}</div>
地址:{{ sythesizestudent.kindergartenAddress }}
</div>
</div> </div>
</div> </div>
</el-card> </el-card>
@ -89,11 +60,7 @@
line-height: 40px; line-height: 40px;
" "
> >
<div <div style="text-align: center; font-size: 18px; margin-bottom: 10px">幼儿综合得分</div>
style="text-align: center; font-size: 18px; margin-bottom: 10px"
>
幼儿综合得分
</div>
<div style="display: inline-block"> <div style="display: inline-block">
<span <span
style=" style="
@ -105,17 +72,17 @@
v-for="(item, index) in sythesizestudent.firstItemCategoryList" v-for="(item, index) in sythesizestudent.firstItemCategoryList"
:key="index" :key="index"
> >
<span :style="index == 0 ? '' : 'margin-right:20px'">{{ <span :style="index == 0 ? '' : 'margin-right:20px'">
{{
index == 0 ? null : "+" index == 0 ? null : "+"
}}</span> }}
<span>
{{ item.categoryName }}( {{ item.categoryScore }})
</span> </span>
<span>{{ item.categoryName }}( {{ item.categoryScore }})</span>
</span> </span>
</div> </div>
<div style="display: inline-block; position: relative"> <div style="display: inline-block; position: relative">
<span style="margin: 0 20px">= </span> <span style="margin: 0 20px">=</span>
<span>综合得分({{ sythesizestudent.totalCategoryScore }})</span> <span>综合得分({{ sythesizestudent.totalCategoryScore }})</span>
<span <span
@ -129,9 +96,7 @@
></span> ></span>
</div> </div>
</div> </div>
<div style="text-align: center; font-size: 18px; margin-top: 20px"> <div style="text-align: center; font-size: 18px; margin-top: 20px">获取徽章</div>
获取徽章
</div>
<div <div
style=" style="
width: 70%; width: 70%;
@ -141,15 +106,8 @@
margin: 20px auto 10px; margin: 20px auto 10px;
" "
> >
<span <span v-for="(item, index) in sythesizestudent.categoryNameList" :key="index">
v-for="(item, index) in sythesizestudent.categoryNameList" <img style="width: 60px; height: 60px" src="@/icons/金牌2.png" alt />
:key="index"
>
<img
style="width: 60px; height: 60px"
src="@/icons/金牌2.png"
alt=""
/>
<div style="margin-top: 10px; font-size: 14px">{{ item }}</div> <div style="margin-top: 10px; font-size: 14px">{{ item }}</div>
</span> </span>
</div> </div>
@ -162,11 +120,7 @@
<span>综合体质分析图</span> <span>综合体质分析图</span>
</div> </div>
<div class="el-table el-table--enable-row-hover el-table--medium"> <div class="el-table el-table--enable-row-hover el-table--medium">
<div <div ref="chart" id="chart" style="width: 1000px; height: 600px; margin: 0 auto"></div>
ref="chart"
id="chart"
style="width: 1000px; height: 600px; margin: 0 auto"
></div>
</div> </div>
</el-card> </el-card>
</el-col> </el-col>
@ -176,9 +130,12 @@
<el-col :span="24" :offset="0"> <el-col :span="24" :offset="0">
<el-card> <el-card>
<div slot="header" style="text-align: center"> <div slot="header" style="text-align: center">
<img style="width: 40px" src="@/icons/笑脸.png" alt="" /> <img style="width: 40px" src="@/icons/笑脸.png" alt />
<div><!-- card title -->该学生此批次暂没成绩</div> <div>
<!-- card title -->
该学生此批次暂没成绩
</div>
</div> </div>
<!-- card body --> <!-- card body -->
</el-card> </el-card>
@ -207,10 +164,10 @@ export default {
// //
synthesizelist: { synthesizelist: {
studentId: "", studentId: "",
batchCode: "", batchCode: ""
// studentId: "27", // studentId: "27",
// batchCode: "PC202208230011", // batchCode: "PC202208230011",
}, }
}; };
}, },
@ -219,7 +176,6 @@ export default {
}, },
methods: { methods: {
itemlists(studentId, batchCode) { itemlists(studentId, batchCode) {
console.log(studentId, batchCode);
this.synthesizelist.studentId = studentId; this.synthesizelist.studentId = studentId;
this.synthesizelist.batchCode = batchCode; this.synthesizelist.batchCode = batchCode;
}, },
@ -229,23 +185,21 @@ export default {
}, },
// //
synthesizeinfo() { synthesizeinfo() {
synthesize(this.synthesizelist).then((res) => { synthesize(this.synthesizelist).then(res => {
if (res.data == [] || !res.data) { if (res.data == [] || !res.data) {
this.itemshow2 = true; this.itemshow2 = true;
this.itemshow = false; this.itemshow = false;
} else { } else {
this.sythesizestudent = res.data; this.sythesizestudent = res.data;
console.log(this.sythesizestudent);
let seriesData = []; let seriesData = [];
let yindicator = []; let yindicator = [];
console.log(res.data);
if (res.data.physiqueCategoryList.length == 1) { if (res.data.physiqueCategoryList.length == 1) {
var obj = { var obj = {
categoryName: "暂无", categoryName: "暂无",
categoryNameAbbreviate: "暂无", categoryNameAbbreviate: "暂无",
categoryScore: null, categoryScore: null,
levelName: "暂无", levelName: "暂无",
maxScore: null, maxScore: null
}; };
res.data.physiqueCategoryList.push(obj); res.data.physiqueCategoryList.push(obj);
res.data.physiqueCategoryList.push(obj); res.data.physiqueCategoryList.push(obj);
@ -257,25 +211,21 @@ export default {
categoryNameAbbreviate: "暂无", categoryNameAbbreviate: "暂无",
categoryScore: null, categoryScore: null,
levelName: "暂无", levelName: "暂无",
maxScore: null, maxScore: null
}; };
res.data.physiqueCategoryList.push(obj); res.data.physiqueCategoryList.push(obj);
res.data.physiqueCategoryList.push(obj); res.data.physiqueCategoryList.push(obj);
} }
res.data.physiqueCategoryList.forEach(el => {
res.data.physiqueCategoryList.forEach((el) => {
console.log(el);
seriesData.push(el.categoryScore); seriesData.push(el.categoryScore);
if (el.levelName == null) { if (el.levelName == null) {
el.levelName = "暂无"; el.levelName = "暂无";
} }
yindicator.push({ yindicator.push({
name: el.categoryName + " " + "(" + el.levelName + "" + ")", name: el.categoryName + " " + "(" + el.levelName + "" + ")",
max: el.maxScore, max: el.maxScore
}); });
}); });
console.log(seriesData, yindicator);
var myChart = echarts.init(document.getElementById("chart")); var myChart = echarts.init(document.getElementById("chart"));
let option = { let option = {
// //
@ -283,51 +233,49 @@ export default {
radar: { radar: {
name: { name: {
show: true, show: true,
color: "black", color: "black"
}, },
center: ["50%", "50%"], center: ["50%", "50%"],
// //
indicator: yindicator, indicator: yindicator,
shape: "polygon", //, circle:,polygon:() shape: "polygon" //, circle:,polygon:()
}, },
series: [ series: [
{ {
type: "radar", type: "radar",
label: { label: {
show: true, show: true,
color: "blue", // color: "blue" //
}, },
areaStyle: {}, // areaStyle: {}, //
data: [ data: [
{ {
name: "成绩区域", name: "成绩区域",
value: seriesData, value: seriesData
}, }
], ],
areaStyle: { areaStyle: {
color: new echarts.graphic.RadialGradient(0.1, 0.6, 1, [ color: new echarts.graphic.RadialGradient(0.1, 0.6, 1, [
{ {
color: "rgba(50, 50, 255, 0.1)", color: "rgba(50, 50, 255, 0.1)",
offset: 0, offset: 0
}, },
{ {
color: "rgba(50, 50, 200, 0.9)", color: "rgba(50, 50, 200, 0.9)",
offset: 1, offset: 1
}, }
]), ])
}, }
}, }
], ]
}; };
// //
myChart.setOption(option); myChart.setOption(option);
this.itemshow2 = false; this.itemshow2 = false;
this.itemshow = true; this.itemshow = true;
console.log(myChart.getDataURL());
// postImage(); // postImage();
// function postImage() { // function postImage() {
// // . // // .
// console.log("1");
// $.ajax({ // $.ajax({
// type: "POST", // type: "POST",
// dataType: "json", // dataType: "json",
@ -339,10 +287,8 @@ export default {
// }); // });
// } // }
} }
// var myChart = echarts.init(document.getElementById("chart")); // var myChart = echarts.init(document.getElementById("chart"));
// var option; // var option;
// option = { // option = {
// color: ["#f6da22", "#bbe2e8", "#6cacde"], // color: ["#f6da22", "#bbe2e8", "#6cacde"],
// legend: { // legend: {
@ -377,9 +323,7 @@ export default {
// }, // },
// ], // ],
// }; // };
// option && myChart.setOption(option); // option && myChart.setOption(option);
// option = { // option = {
// legend: { // legend: {
// top: "bottom", // top: "bottom",
@ -422,14 +366,12 @@ export default {
// }, // },
// ], // ],
// }; // };
// option && myChart.setOption(option); // option && myChart.setOption(option);
}); });
}, },
getList() { getList() {
// //
getRoleInfo().then((res) => { getRoleInfo().then(res => {
console.log(res);
this.classqueryParams.kindergartenId = res.data.kindergartenId; this.classqueryParams.kindergartenId = res.data.kindergartenId;
var user = res.data.roleKeys; var user = res.data.roleKeys;
if (user.includes("enchou")) { if (user.includes("enchou")) {
@ -449,8 +391,8 @@ export default {
reset() { reset() {
this.form = {}; this.form = {};
this.resetForm("form"); this.resetForm("form");
}, }
}, }
}; };
</script> </script>
<style scoped='scss'> <style scoped='scss'>

View File

@ -114,7 +114,6 @@ export default {
created() {}, created() {},
methods: { methods: {
itemlists(studentId, batchCode) { itemlists(studentId, batchCode) {
console.log(studentId, batchCode);
this.analysisqueryParams.studentId = studentId; this.analysisqueryParams.studentId = studentId;
this.analysisqueryParams.batchCode = batchCode; this.analysisqueryParams.batchCode = batchCode;
}, },
@ -132,7 +131,6 @@ export default {
this.analysislist.itemScoreList[i].cityAvgScore, this.analysislist.itemScoreList[i].cityAvgScore,
]; ];
var textname = this.analysislist.itemScoreList[i].itemName; var textname = this.analysislist.itemScoreList[i].itemName;
// console.log(ydata);
var myChart = echarts.init(myEchart[i]); var myChart = echarts.init(myEchart[i]);
var option = { var option = {
title: { title: {
@ -224,7 +222,6 @@ export default {
// //
analysislists() { analysislists() {
constitution(this.analysisqueryParams).then((res) => { constitution(this.analysisqueryParams).then((res) => {
console.log(res);
if (!res.data || res.data == "") { if (!res.data || res.data == "") {
this.itemshow2 = true; this.itemshow2 = true;
this.itemshow = false; this.itemshow = false;
@ -241,7 +238,6 @@ export default {
getList() { getList() {
// //
getRoleInfo().then((res) => { getRoleInfo().then((res) => {
console.log(res);
this.classqueryParams.kindergartenId = res.data.kindergartenId; this.classqueryParams.kindergartenId = res.data.kindergartenId;
var user = res.data.roleKeys; var user = res.data.roleKeys;
if (user.includes("enchou")) { if (user.includes("enchou")) {

View File

@ -304,8 +304,6 @@ export default {
listDept(this.queryParams).then((response) => { listDept(this.queryParams).then((response) => {
this.deptList = this.handleTree(response.data, "deptId"); this.deptList = this.handleTree(response.data, "deptId");
this.loading = false; this.loading = false;
console.log(response.data);
console.log(this.deptList);
}); });
}, },
/** 转换部门数据结构 */ /** 转换部门数据结构 */
@ -357,7 +355,6 @@ export default {
this.title = "添加部门"; this.title = "添加部门";
listDept().then((response) => { listDept().then((response) => {
this.deptOptions = this.handleTree(response.data, "deptId"); this.deptOptions = this.handleTree(response.data, "deptId");
console.log(this.deptOptions);
}); });
}, },
/** 展开/折叠操作 */ /** 展开/折叠操作 */
@ -382,8 +379,6 @@ export default {
}, },
/** 提交按钮 */ /** 提交按钮 */
submitForm: function () { submitForm: function () {
console.log(this.form);
this.$refs["form"].validate((valid) => { this.$refs["form"].validate((valid) => {
if (valid) { if (valid) {
if (this.form.deptId != undefined) { if (this.form.deptId != undefined) {

View File

@ -182,7 +182,6 @@ export default {
this.analysisinfo(); this.analysisinfo();
}, },
kinbatlist(kindergartenId, batchCode) { kinbatlist(kindergartenId, batchCode) {
console.log(kindergartenId, batchCode);
this.analysislist.kindergartenId = kindergartenId; this.analysislist.kindergartenId = kindergartenId;
this.analysislist.batchCode = batchCode; this.analysislist.batchCode = batchCode;
if (batchCode == "请选择批次") { if (batchCode == "请选择批次") {
@ -227,7 +226,6 @@ export default {
getList() { getList() {
// //
getRoleInfo().then((res) => { getRoleInfo().then((res) => {
console.log(res);
var user = res.data.roleKeys; var user = res.data.roleKeys;
if (user.includes("enchou")) { if (user.includes("enchou")) {
return; return;

View File

@ -1,41 +1,20 @@
<template> <template>
<div class="app-container"> <div class="app-container">
<el-form <el-form ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="90px">
ref="queryForm" <kindergarten @kinbatlist="kinbatlist" style="width: 500px; display: inline"></kindergarten>
size="small"
:inline="true"
v-show="showSearch"
label-width="90px"
>
<kindergarten
@kinbatlist="kinbatlist"
style="width: 500px; display: inline"
></kindergarten>
<el-form-item> <el-form-item>
<el-button <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">查看</el-button>
type="primary"
icon="el-icon-search"
size="mini"
@click="handleQuery"
>查看</el-button
>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-row :gutter="10" class="mb8"> <el-row :gutter="10" class="mb8">
<right-toolbar <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
:showSearch.sync="showSearch"
@queryTable="getList"
></right-toolbar>
</el-row> </el-row>
<el-row v-show="itemshow"> <el-row v-show="itemshow">
<el-col :span="24" class="card-box" style=""> <el-col :span="24" class="card-box" style>
<el-card> <el-card>
<div style="display: flex; margin-top: 40px"> <div style="display: flex; margin-top: 40px">
<div <div slot="header" style="width: 50%; text-align: center; font-size: 18px">
slot="header"
style="width: 50%; text-align: center; font-size: 18px"
>
<span>各年级男/女平均身高(cm)</span> <span>各年级男/女平均身高(cm)</span>
<div <div
id="main" id="main"
@ -47,10 +26,7 @@
" "
></div> ></div>
</div> </div>
<div <div slot="header" style="width: 50%; text-align: center; font-size: 18px">
slot="header"
style="width: 50%; text-align: center; font-size: 18px"
>
<span>各年级男/女平均体重(kg)</span> <span>各年级男/女平均体重(kg)</span>
<div <div
id="main2" id="main2"
@ -71,9 +47,12 @@
<el-col :span="24" :offset="0"> <el-col :span="24" :offset="0">
<el-card> <el-card>
<div slot="header" style="text-align: center"> <div slot="header" style="text-align: center">
<img style="width: 40px" src="@/icons/笑脸.png" alt="" /> <img style="width: 40px" src="@/icons/笑脸.png" alt />
<div><!-- card title -->该批次暂无数据</div> <div>
<!-- card title -->
该批次暂无数据
</div>
</div> </div>
<!-- card body --> <!-- card body -->
</el-card> </el-card>
@ -100,10 +79,10 @@ export default {
// //
analysisqueryParams: { analysisqueryParams: {
kindergartenId: "", kindergartenId: "",
batchCode: "", batchCode: ""
// kindergartenId: "18", // kindergartenId: "18",
// batchCode: "PC202208030005", // batchCode: "PC202208030005",
}, }
}; };
}, },
mounted() {}, mounted() {},
@ -115,7 +94,6 @@ export default {
this.analysisinfo(); this.analysisinfo();
}, },
kinbatlist(kindergartenId, batchCode) { kinbatlist(kindergartenId, batchCode) {
console.log(kindergartenId, batchCode);
this.analysisqueryParams.kindergartenId = kindergartenId; this.analysisqueryParams.kindergartenId = kindergartenId;
this.analysisqueryParams.batchCode = batchCode; this.analysisqueryParams.batchCode = batchCode;
if (batchCode == "请选择批次") { if (batchCode == "请选择批次") {
@ -124,13 +102,12 @@ export default {
}, },
analysisinfo() { analysisinfo() {
heightAndWeightanalysis(this.analysisqueryParams).then((res) => { heightAndWeightanalysis(this.analysisqueryParams).then(res => {
if (!res.data) { if (!res.data) {
this.itemshow2 = true; this.itemshow2 = true;
this.itemshow = false; this.itemshow = false;
} else { } else {
this.analysislist = res.data; this.analysislist = res.data;
console.log(this.analysislist);
var yclassname = []; var yclassname = [];
var grilsheight = []; var grilsheight = [];
var boyheight = []; var boyheight = [];
@ -138,7 +115,7 @@ export default {
var grilsweight = []; var grilsweight = [];
for (var i = 0; i < this.analysislist.length; i++) { for (var i = 0; i < this.analysislist.length; i++) {
this.analysislist[i].weightAndHeightAvgScoreList.forEach((el) => { this.analysislist[i].weightAndHeightAvgScoreList.forEach(el => {
if (el.itemCode == "H001" && el.studentSex == "MALE") { if (el.itemCode == "H001" && el.studentSex == "MALE") {
boyheight.push(el.averageScore); boyheight.push(el.averageScore);
} else if (el.itemCode == "H001" && el.studentSex == "FEMALE") { } else if (el.itemCode == "H001" && el.studentSex == "FEMALE") {
@ -162,14 +139,10 @@ export default {
grilsweight.push(0); grilsweight.push(0);
} }
} }
this.analysislist.forEach(e => {
this.analysislist.forEach((e) => {
yclassname.push(e.className); yclassname.push(e.className);
}); });
console.log(grilsheight, boyheight);
console.log(grilsweight, boyweight);
var app = {}; var app = {};
var myChart = echarts.init(document.getElementById("main")); var myChart = echarts.init(document.getElementById("main"));
var myChart2 = echarts.init(document.getElementById("main2")); var myChart2 = echarts.init(document.getElementById("main2"));
var option; var option;
@ -187,37 +160,37 @@ export default {
"insideTopLeft", "insideTopLeft",
"insideTopRight", "insideTopRight",
"insideBottomLeft", "insideBottomLeft",
"insideBottomRight", "insideBottomRight"
]; ];
app.configParameters = { app.configParameters = {
rotate: { rotate: {
min: 0, min: 0,
max: 90, max: 90
}, },
align: { align: {
options: { options: {
left: "left", left: "left",
center: "center", center: "center",
right: "right", right: "right"
}, }
}, },
verticalAlign: { verticalAlign: {
options: { options: {
top: "top", top: "top",
middle: "middle", middle: "middle",
bottom: "bottom", bottom: "bottom"
}, }
}, },
position: { position: {
options: posList.reduce(function (map, pos) { options: posList.reduce(function(map, pos) {
map[pos] = pos; map[pos] = pos;
return map; return map;
}, {}), }, {})
}, },
distance: { distance: {
min: 0, min: 0,
max: 100, max: 100
}, }
}; };
app.config = { app.config = {
rotate: 0, rotate: 0,
@ -225,31 +198,31 @@ export default {
verticalAlign: "middle", verticalAlign: "middle",
position: "top", position: "top",
distance: 15, distance: 15,
onChange: function () { onChange: function() {
const labelOption = { const labelOption = {
rotate: app.config.rotate, rotate: app.config.rotate,
align: app.config.align, align: app.config.align,
verticalAlign: app.config.verticalAlign, verticalAlign: app.config.verticalAlign,
position: app.config.position, position: app.config.position,
distance: app.config.distance, distance: app.config.distance
}; };
myChart.setOption({ myChart.setOption({
series: [ series: [
{ {
label: labelOption, label: labelOption
}, },
{ {
label: labelOption, label: labelOption
}, },
{ {
label: labelOption, label: labelOption
}, },
{ {
label: labelOption, label: labelOption
}, }
], ]
}); });
}, }
}; };
const labelOption = { const labelOption = {
show: true, show: true,
@ -261,30 +234,30 @@ export default {
formatter: "{c}", formatter: "{c}",
fontSize: 16, fontSize: 16,
rich: { rich: {
name: {}, name: {}
}, }
}; };
option = { option = {
tooltip: { tooltip: {
trigger: "axis", trigger: "axis",
axisPointer: { axisPointer: {
type: "shadow", type: "shadow"
}, }
}, },
legend: { legend: {
data: ["男", "女"], data: ["男", "女"]
}, },
xAxis: [ xAxis: [
{ {
type: "category", type: "category",
axisTick: { show: false }, axisTick: { show: false },
data: yclassname, data: yclassname
}, }
], ],
yAxis: [ yAxis: [
{ {
type: "value", type: "value"
}, }
], ],
series: [ series: [
{ {
@ -295,9 +268,9 @@ export default {
color: "#00B050", color: "#00B050",
label: labelOption, label: labelOption,
emphasis: { emphasis: {
focus: "series", focus: "series"
}, },
data: boyheight, data: boyheight
}, },
{ {
name: "女", name: "女",
@ -306,33 +279,33 @@ export default {
color: "red", color: "red",
label: labelOption, label: labelOption,
emphasis: { emphasis: {
focus: "series", focus: "series"
}, },
data: grilsheight, data: grilsheight
}, }
], ]
}; };
option2 = { option2 = {
tooltip: { tooltip: {
trigger: "axis", trigger: "axis",
axisPointer: { axisPointer: {
type: "shadow", type: "shadow"
}, }
}, },
legend: { legend: {
data: ["男", "女"], data: ["男", "女"]
}, },
xAxis: [ xAxis: [
{ {
type: "category", type: "category",
axisTick: { show: false }, axisTick: { show: false },
data: yclassname, data: yclassname
}, }
], ],
yAxis: [ yAxis: [
{ {
type: "value", type: "value"
}, }
], ],
series: [ series: [
{ {
@ -343,9 +316,9 @@ export default {
color: "#00B050", color: "#00B050",
label: labelOption, label: labelOption,
emphasis: { emphasis: {
focus: "series", focus: "series"
}, },
data: boyweight, data: boyweight
}, },
{ {
barWidth: 35, barWidth: 35,
@ -354,11 +327,11 @@ export default {
color: "red", color: "red",
label: labelOption, label: labelOption,
emphasis: { emphasis: {
focus: "series", focus: "series"
}, },
data: grilsweight, data: grilsweight
}, }
], ]
}; };
option && myChart.setOption(option); option && myChart.setOption(option);
option2 && myChart2.setOption(option2); option2 && myChart2.setOption(option2);
@ -367,11 +340,9 @@ export default {
} }
}); });
}, },
getList() { getList() {
// //
getRoleInfo().then((res) => { getRoleInfo().then(res => {
console.log(res);
var user = res.data.roleKeys; var user = res.data.roleKeys;
if (user.includes("enchou")) { if (user.includes("enchou")) {
return; return;
@ -386,8 +357,8 @@ export default {
reset() { reset() {
this.form = {}; this.form = {};
this.resetForm("form"); this.resetForm("form");
}, }
}, }
}; };
</script> </script>
<style scoped='scss'> <style scoped='scss'>

View File

@ -386,7 +386,6 @@ export default {
clickcity(item) { clickcity(item) {
this.value2 = ""; this.value2 = "";
this.form.areaId = item.id; this.form.areaId = item.id;
console.log(item);
getSubordinateInfo(item.id).then((res) => { getSubordinateInfo(item.id).then((res) => {
this.arealist = res.data; this.arealist = res.data;
}); });
@ -455,13 +454,11 @@ export default {
getList() { getList() {
listArea(this.queryParams).then((response) => { listArea(this.queryParams).then((response) => {
this.areaList = this.handleTree(response.data); this.areaList = this.handleTree(response.data);
console.log(this.areaList);
}); });
this.loading = true; this.loading = true;
list(this.queryParams).then((response) => { list(this.queryParams).then((response) => {
this.List = this.handleTree(response.data); this.List = this.handleTree(response.data);
this.List2 = this.List; this.List2 = this.List;
console.log(this.List);
this.loading = false; this.loading = false;
}); });
}, },
@ -545,16 +542,13 @@ export default {
this.value = response.data.provinceCode; this.value = response.data.provinceCode;
this.value1 = response.data.cityName; this.value1 = response.data.cityName;
this.value2 = response.data.regionName; this.value2 = response.data.regionName;
console.log(this.value);
this.form = response.data; this.form = response.data;
this.open = true; this.open = true;
this.title = "修改区域管理"; this.title = "修改区域管理";
}); });
}, },
/** 提交按钮 */ /** 提交按钮 */
submitForm() { submitForm() {
console.log(this.form);
if (this.List.length == 0) { if (this.List.length == 0) {
this.form.parentId = 0; this.form.parentId = 0;
} }

View File

@ -304,7 +304,6 @@ export default {
}; };
let ItemLevelList = (rule, value, callback) => { let ItemLevelList = (rule, value, callback) => {
for (let i = 0; i < value.length; i++) { for (let i = 0; i < value.length; i++) {
console.log(value[i].levelMinScore > value[i].levelMaxScore);
if (value[i].levelMinScore > value[i].levelMaxScore) { if (value[i].levelMinScore > value[i].levelMaxScore) {
callback(new Error("最高分必须大于最低分,请重新填写!")); callback(new Error("最高分必须大于最低分,请重新填写!"));
} else if (value[i].levelName == "") { } else if (value[i].levelName == "") {
@ -318,8 +317,6 @@ export default {
} }
} }
// value.for((e) => { // value.for((e) => {
// console.log(e.levelMinScore, e.levelMaxScore);
// console.log(e.levelMinScore > e.levelMaxScore);
// if (e.levelMinScore > e.levelMaxScore) { // if (e.levelMinScore > e.levelMaxScore) {
// callback(new Error(",")); // callback(new Error(","));
// } else if (e.levelName == "") { // } else if (e.levelName == "") {
@ -412,10 +409,8 @@ export default {
methods: { methods: {
delInput(index) { delInput(index) {
this.form.testItemLevelList.splice(index, 1); this.form.testItemLevelList.splice(index, 1);
console.log(this.form.testItemLevelList);
}, },
addInput() { addInput() {
console.log(this.form);
this.form.testItemLevelList.push({ this.form.testItemLevelList.push({
levelName: "", levelName: "",
levelMinScore: "", levelMinScore: "",
@ -424,7 +419,6 @@ export default {
}, },
/** 转换部门数据结构 */ /** 转换部门数据结构 */
normalizer(node) { normalizer(node) {
// console.log(node);
if (node.children && !node.children.length) { if (node.children && !node.children.length) {
delete node.children; delete node.children;
} }
@ -447,9 +441,7 @@ export default {
this.loading = true; this.loading = true;
listItemCategory(this.queryParams).then((response) => { listItemCategory(this.queryParams).then((response) => {
this.itemCategoryList = this.handleTree(response.data); this.itemCategoryList = this.handleTree(response.data);
// console.log(this.itemCategoryList);
// this.total = response.data.length; // this.total = response.data.length;
// console.log(this.total);
this.loading = false; this.loading = false;
}); });
}, },
@ -497,10 +489,8 @@ export default {
/** 项目新增按钮操作 */ /** 项目新增按钮操作 */
handleAdd2(row) { handleAdd2(row) {
console.log(row);
this.reset(); this.reset();
this.form.parentId = row.id; this.form.parentId = row.id;
console.log(this.form);
this.open = true; this.open = true;
this.title = "添加区域管理"; this.title = "添加区域管理";
}, },
@ -523,12 +513,10 @@ export default {
this.form = response.data; this.form = response.data;
this.open = true; this.open = true;
this.title = "修改测试项目分类"; this.title = "修改测试项目分类";
console.log(this.form);
}); });
}, },
/** 提交按钮 */ /** 提交按钮 */
submitForm() { submitForm() {
console.log(this.form);
this.$refs["form"].validate((valid) => { this.$refs["form"].validate((valid) => {
if (valid) { if (valid) {
if (this.form.id != null) { if (this.form.id != null) {

File diff suppressed because it is too large Load Diff

View File

@ -287,9 +287,7 @@ export default {
data() { data() {
// //
var checkMobile = (rule, value, cb) => { var checkMobile = (rule, value, cb) => {
console.log(value);
var str = String(value); var str = String(value);
console.log(str);
// //
const regMobile = const regMobile =
/^1(3[0-9]|4[01456879]|5[0-35-9]|6[2567]|7[0-8]|8[0-9]|9[0-35-9])\d{8}$/ /^1(3[0-9]|4[01456879]|5[0-35-9]|6[2567]|7[0-8]|8[0-9]|9[0-35-9])\d{8}$/
@ -425,7 +423,6 @@ export default {
this.loading = true; this.loading = true;
getUserInfoList({ roleKey: "enchou" }).then((res) => { getUserInfoList({ roleKey: "enchou" }).then((res) => {
this.getUserInfoLists = res.data; this.getUserInfoLists = res.data;
console.log(this.getUserInfoLists);
}); });
list(this.info).then((response) => { list(this.info).then((response) => {
this.infolist = this.handleTree(response.data); this.infolist = this.handleTree(response.data);
@ -508,7 +505,6 @@ export default {
}, },
/** 提交按钮 */ /** 提交按钮 */
submitForm() { submitForm() {
console.log(this.form);
this.$refs["form"].validate((valid) => { this.$refs["form"].validate((valid) => {
if (valid) { if (valid) {
if (this.form.id != null) { if (this.form.id != null) {

View File

@ -245,7 +245,6 @@ export default {
methods: { methods: {
/** 查询运动处方字典列表 */ /** 查询运动处方字典列表 */
getList() { getList() {
console.log(this.queryParams);
this.loading = true; this.loading = true;
listMotionInfo(this.queryParams).then((response) => { listMotionInfo(this.queryParams).then((response) => {
this.motionInfoList = response.rows; this.motionInfoList = response.rows;
@ -306,7 +305,6 @@ export default {
submitForm() { submitForm() {
// var motionContent = this.form.motionContent.slice(3, -4); // var motionContent = this.form.motionContent.slice(3, -4);
// this.form.motionContent = motionContent; // this.form.motionContent = motionContent;
console.log(this.form);
this.$refs["form"].validate((valid) => { this.$refs["form"].validate((valid) => {
if (valid) { if (valid) {
if (this.form.id != null) { if (this.form.id != null) {

View File

@ -249,7 +249,6 @@ export default {
}, },
watch: { watch: {
$route(to, from) { $route(to, from) {
console.log(to.path, from.path);
if (to.path == "/baseInfo/parentInfo") { if (to.path == "/baseInfo/parentInfo") {
this.getList(); this.getList();
} }

View File

@ -1285,7 +1285,6 @@ export default {
// watch: { // watch: {
// itemlists: { // itemlists: {
// handler(newName, oldName) { // handler(newName, oldName) {
// console.log(newName, oldName);
// this.echartslist = { // this.echartslist = {
// studentId: newName.studentId, // studentId: newName.studentId,
// batchCode: newName.batchCode, // batchCode: newName.batchCode,
@ -1350,7 +1349,6 @@ export default {
this.selectspanArr.push(1); // 1 this.selectspanArr.push(1); // 1
this.selectposition = index; // this.selectposition = index; //
} }
if ( if (
this.selectlist[index].physicalQualityName == this.selectlist[index].physicalQualityName ==
this.selectlist[index - 1].physicalQualityName && this.selectlist[index - 1].physicalQualityName &&
@ -1363,7 +1361,6 @@ export default {
this.selectspanArr2.push(1); // 1 this.selectspanArr2.push(1); // 1
this.selectposition2 = index; // this.selectposition2 = index; //
} }
if ( if (
this.selectlist[index].physicalQualityName == this.selectlist[index].physicalQualityName ==
this.selectlist[index - 1].physicalQualityName && this.selectlist[index - 1].physicalQualityName &&
@ -1392,7 +1389,6 @@ export default {
}); });
}, },
selectlistMethod({ row, column, rowIndex, columnIndex }) { selectlistMethod({ row, column, rowIndex, columnIndex }) {
console.log(columnIndex);
if (columnIndex == 0) { if (columnIndex == 0) {
const _row = this.selectspanArr[rowIndex]; const _row = this.selectspanArr[rowIndex];
const _col = _row > 0 ? 1 : 0; const _col = _row > 0 ? 1 : 0;
@ -1552,8 +1548,6 @@ export default {
this.itemheight = res.data.heightScore; this.itemheight = res.data.heightScore;
this.bmiItemLevel = res.data.bmiItemLevel; this.bmiItemLevel = res.data.bmiItemLevel;
this.itemweight = res.data.weightScore; this.itemweight = res.data.weightScore;
// console.log(this.shapelist);
console.log(this.bmiItemLevel);
let seriesData = []; let seriesData = [];
res.data.bmiItemLevel.forEach((el) => { res.data.bmiItemLevel.forEach((el) => {
seriesData.push({ seriesData.push({
@ -1568,7 +1562,6 @@ export default {
")", ")",
}); });
}); });
console.log(seriesData);
let shapechart = echarts.init( let shapechart = echarts.init(
document.getElementById("shapechart") document.getElementById("shapechart")
); );
@ -1627,7 +1620,6 @@ export default {
constitutioninfo() { constitutioninfo() {
setTimeout(() => { setTimeout(() => {
constitution(this.echartslist).then((res) => { constitution(this.echartslist).then((res) => {
console.log(res);
this.constitutionlist = res.data; this.constitutionlist = res.data;
if (!res.data || res.data == "") { if (!res.data || res.data == "") {
this.constitutionshow = false; this.constitutionshow = false;
@ -1650,7 +1642,6 @@ export default {
this.constitutionlist.itemScoreList[i].cityAvgScore, this.constitutionlist.itemScoreList[i].cityAvgScore,
]; ];
let textname = this.constitutionlist.itemScoreList[i].itemName; let textname = this.constitutionlist.itemScoreList[i].itemName;
// console.log(ydata);
let myChart = echarts.init(constitutionEchart[i]); let myChart = echarts.init(constitutionEchart[i]);
let option = { let option = {
title: { title: {
@ -1830,7 +1821,6 @@ export default {
}; };
} }
if (columnIndex == 7) { if (columnIndex == 7) {
// console.log(this.spanArr2);
const _row = this.spanArr2[rowIndex]; const _row = this.spanArr2[rowIndex];
const _col = _row > 0 ? 1 : 0; const _col = _row > 0 ? 1 : 0;
return { return {
@ -1839,7 +1829,6 @@ export default {
}; };
} }
if (columnIndex == 8) { if (columnIndex == 8) {
// console.log(this.spanArr2);
const _row = this.spanArr3[rowIndex]; const _row = this.spanArr3[rowIndex];
const _col = _row > 0 ? 1 : 0; const _col = _row > 0 ? 1 : 0;
return { return {
@ -1848,7 +1837,6 @@ export default {
}; };
} }
if (columnIndex == 9) { if (columnIndex == 9) {
// console.log(this.spanArr2);
const _row = this.spanArr4[rowIndex]; const _row = this.spanArr4[rowIndex];
const _col = _row > 0 ? 1 : 0; const _col = _row > 0 ? 1 : 0;
return { return {

View File

@ -276,12 +276,9 @@ export default {
this.analysisinfo(); this.analysisinfo();
}, },
kinbatlist(kin, batchCode) { kinbatlist(kin, batchCode) {
console.log(kin);
var a = kin; var a = kin;
console.log(a);
this.analysisqueryParams.kindergartenId = a; this.analysisqueryParams.kindergartenId = a;
this.analysisqueryParams.batchCode = batchCode; this.analysisqueryParams.batchCode = batchCode;
console.log(this.analysisqueryParams);
}, },
analysisinfo() { analysisinfo() {
@ -295,7 +292,6 @@ export default {
this.categoryAgeFractionList = res.data.categoryAgeFractionList; this.categoryAgeFractionList = res.data.categoryAgeFractionList;
this.categoryScoreList = res.data.categoryScoreList; this.categoryScoreList = res.data.categoryScoreList;
this.firstCategoryScoreList = res.data.firstCategoryScoreList; this.firstCategoryScoreList = res.data.firstCategoryScoreList;
console.log(this.firstCategoryScoreList);
if (res.data == [] || !res.data) { if (res.data == [] || !res.data) {
this.itemshow2 = true; this.itemshow2 = true;
this.itemshow = false; this.itemshow = false;
@ -322,7 +318,6 @@ export default {
let seriesData = []; let seriesData = [];
let yindicator = []; let yindicator = [];
this.categoryScoreList.forEach((el) => { this.categoryScoreList.forEach((el) => {
console.log(el);
seriesData.push(el.itemFraction); seriesData.push(el.itemFraction);
if (el.avgCategoryName == null) { if (el.avgCategoryName == null) {
el.avgCategoryName = "暂无"; el.avgCategoryName = "暂无";
@ -413,7 +408,6 @@ export default {
getList() { getList() {
// //
getRoleInfo().then((res) => { getRoleInfo().then((res) => {
console.log(res);
var user = res.data.roleKeys; var user = res.data.roleKeys;
if (user.includes("enchou")) { if (user.includes("enchou")) {
return; return;

View File

@ -389,7 +389,6 @@ export default {
created() {}, created() {},
methods: { methods: {
itemlists(studentId, batchCode) { itemlists(studentId, batchCode) {
console.log(studentId, batchCode);
this.studentscore.studentId = studentId; this.studentscore.studentId = studentId;
this.studentscore.batchCode = batchCode; this.studentscore.batchCode = batchCode;
}, },
@ -410,14 +409,12 @@ export default {
this.itemshow = true; this.itemshow = true;
this.itemshow2 = false; this.itemshow2 = false;
this.studentscorelist = res.rows; this.studentscorelist = res.rows;
console.log(this.studentscorelist);
} }
}); });
}, },
getList() { getList() {
// //
getRoleInfo().then((res) => { getRoleInfo().then((res) => {
console.log(res);
this.classqueryParams.kindergartenId = res.data.kindergartenId; this.classqueryParams.kindergartenId = res.data.kindergartenId;
var user = res.data.roleKeys; var user = res.data.roleKeys;
if (user.includes("enchou")) { if (user.includes("enchou")) {

View File

@ -689,7 +689,6 @@ export default {
// }, // },
/** 分配用户操作 */ /** 分配用户操作 */
handleAuthUser(row) { handleAuthUser(row) {
console.log(row);
const roleId = row.roleId; const roleId = row.roleId;
this.$router.push("/system/role-auth/user/" + roleId); this.$router.push("/system/role-auth/user/" + roleId);
}, },

View File

@ -678,7 +678,6 @@ export default {
}, },
methods: { methods: {
itemlists(studentId, batchCode) { itemlists(studentId, batchCode) {
console.log(studentId, batchCode);
this.analysisstudent.studentId = studentId; this.analysisstudent.studentId = studentId;
this.analysisstudent.batchCode = batchCode; this.analysisstudent.batchCode = batchCode;
}, },
@ -724,8 +723,6 @@ export default {
this.itemheight = res.data.heightScore; this.itemheight = res.data.heightScore;
this.bmiItemLevel = res.data.bmiItemLevel; this.bmiItemLevel = res.data.bmiItemLevel;
this.itemweight = res.data.weightScore; this.itemweight = res.data.weightScore;
// console.log(this.analysislist);
console.log(this.bmiItemLevel);
let seriesData = []; let seriesData = [];
res.data.bmiItemLevel.forEach((el) => { res.data.bmiItemLevel.forEach((el) => {
seriesData.push({ seriesData.push({
@ -740,10 +737,7 @@ export default {
")", ")",
}); });
}); });
console.log(seriesData);
var myChart = echarts.init(document.getElementById("chart")); var myChart = echarts.init(document.getElementById("chart"));
var option = { var option = {
series: [ series: [
{ {
@ -786,10 +780,8 @@ export default {
getList() { getList() {
// //
getRoleInfo().then((res) => { getRoleInfo().then((res) => {
console.log(res);
this.classqueryParams.kindergartenId = res.data.kindergartenId; this.classqueryParams.kindergartenId = res.data.kindergartenId;
var user = res.data.roleKeys; var user = res.data.roleKeys;
console.log(user);
if (user.includes("enchou")) { if (user.includes("enchou")) {
return; return;
} else if (user.includes("teacher")) { } else if (user.includes("teacher")) {

File diff suppressed because it is too large Load Diff

View File

@ -1,31 +1,13 @@
<template> <template>
<div class="app-container"> <div class="app-container">
<el-form <el-form ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="90px">
ref="queryForm" <kindergarten @kinbatlist="kinbatlist" style="width: 500px; display: inline"></kindergarten>
size="small"
:inline="true"
v-show="showSearch"
label-width="90px"
>
<kindergarten
@kinbatlist="kinbatlist"
style="width: 500px; display: inline"
></kindergarten>
<el-form-item> <el-form-item>
<el-button <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">查看</el-button>
type="primary"
icon="el-icon-search"
size="mini"
@click="handleQuery"
>查看</el-button
>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-row :gutter="10" class="mb8"> <el-row :gutter="10" class="mb8">
<right-toolbar <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
:showSearch.sync="showSearch"
@queryTable="getList"
></right-toolbar>
</el-row> </el-row>
<el-row v-show="itemshow"> <el-row v-show="itemshow">
<div> <div>
@ -36,24 +18,15 @@
</div> </div>
<div v-if="yclassname1.length != 0" style="position: relative"> <div v-if="yclassname1.length != 0" style="position: relative">
<div class="title">大班</div> <div class="title">大班</div>
<div <div id="main" style="width: 500px; height: 350px; margin: 0 auto"></div>
id="main"
style="width: 500px; height: 350px; margin: 0 auto"
></div>
</div> </div>
<div v-if="yclassname2.length != 0" style="position: relative"> <div v-if="yclassname2.length != 0" style="position: relative">
<div class="title">中班</div> <div class="title">中班</div>
<div <div id="main2" style="width: 500px; height: 350px; margin: 0 auto"></div>
id="main2"
style="width: 500px; height: 350px; margin: 0 auto"
></div>
</div> </div>
<div v-if="yclassname3.length != 0" style="position: relative"> <div v-if="yclassname3.length != 0" style="position: relative">
<div class="title">小班</div> <div class="title">小班</div>
<div <div id="main3" style="width: 500px; height: 350px; margin: 0 auto"></div>
id="main3"
style="width: 500px; height: 350px; margin: 0 auto"
></div>
</div> </div>
</div> </div>
<div style="width: 50%"> <div style="width: 50%">
@ -66,41 +39,13 @@
highlight-current-row highlight-current-row
style="margin: 0 auto; width: 530px" style="margin: 0 auto; width: 530px"
> >
<el-table-column <el-table-column type="index" width="130" label="排名" align="center"></el-table-column>
type="index" <el-table-column property="studentName" label="姓名" width="130" align="center"></el-table-column>
width="130" <el-table-column property="className" label="班级" width="130" align="center"></el-table-column>
label="排名" <el-table-column property="itemFraction" label="分数" width="140" align="center"></el-table-column>
align="center"
>
</el-table-column>
<el-table-column
property="studentName"
label="姓名"
width="130"
align="center"
>
</el-table-column>
<el-table-column
property="className"
label="班级"
width="130"
align="center"
>
</el-table-column>
<el-table-column
property="itemFraction"
label="分数"
width="140"
align="center"
>
</el-table-column>
</el-table> </el-table>
<div <div slot="header" class="header" style="margin-bottom: 20px; margin-top: 20px">
slot="header"
class="header"
style="margin-bottom: 20px; margin-top: 20px"
>
<span>班级优秀幼儿榜</span> <span>班级优秀幼儿榜</span>
</div> </div>
<el-table <el-table
@ -109,34 +54,10 @@
highlight-current-row highlight-current-row
style="margin: 0 auto; width: 530px" style="margin: 0 auto; width: 530px"
> >
<el-table-column <el-table-column type="index" width="130" label="排名" align="center"></el-table-column>
type="index" <el-table-column property="studentName" label="姓名" width="130" align="center"></el-table-column>
width="130" <el-table-column property="className" label="班级" width="130" align="center"></el-table-column>
label="排名" <el-table-column property="itemFraction" label="分数" width="140" align="center"></el-table-column>
align="center"
>
</el-table-column>
<el-table-column
property="studentName"
label="姓名"
width="130"
align="center"
>
</el-table-column>
<el-table-column
property="className"
label="班级"
width="130"
align="center"
>
</el-table-column>
<el-table-column
property="itemFraction"
label="分数"
width="140"
align="center"
>
</el-table-column>
</el-table> </el-table>
</div> </div>
</div> </div>
@ -146,9 +67,12 @@
<el-col :span="24" :offset="0"> <el-col :span="24" :offset="0">
<el-card> <el-card>
<div slot="header" style="text-align: center"> <div slot="header" style="text-align: center">
<img style="width: 40px" src="@/icons/笑脸.png" alt="" /> <img style="width: 40px" src="@/icons/笑脸.png" alt />
<div><!-- card title -->该幼儿园此批次暂无数据</div> <div>
<!-- card title -->
该幼儿园此批次暂无数据
</div>
</div> </div>
<!-- card body --> <!-- card body -->
</el-card> </el-card>
@ -162,7 +86,7 @@ import { getRoleInfo } from "@/api/system/quality";
import { import {
StudentList, StudentList,
ClassList, ClassList,
selectAllClassById, selectAllClassById
} from "@/api/system/survey"; } from "@/api/system/survey";
import Kindergarten from "../../assembly/kindergarten.vue"; import Kindergarten from "../../assembly/kindergarten.vue";
export default { export default {
@ -179,19 +103,19 @@ export default {
// //
selectAllClassByquery: { selectAllClassByquery: {
kindergartenId: "", kindergartenId: "",
batchCode: "", batchCode: ""
}, },
classqueryParams: { classqueryParams: {
kindergartenId: "", kindergartenId: "",
batchCode: "", batchCode: "",
pageNum: 1, pageNum: 1,
pageSize: 10, pageSize: 10
// kindergartenId: "2", // kindergartenId: "2",
// batchCode: "PC202208260011", // batchCode: "PC202208260011",
}, },
studentlistqueryParams: { studentlistqueryParams: {
kindergartenId: "", kindergartenId: "",
batchCode: "", batchCode: ""
// kindergartenId: "2", // kindergartenId: "2",
// batchCode: "PC202208260011", // batchCode: "PC202208260011",
}, },
@ -203,7 +127,7 @@ export default {
yclassname3: [], yclassname3: [],
classscore1: [], classscore1: [],
classscore2: [], classscore2: [],
classscore3: [], classscore3: []
}; };
}, },
mounted() {}, mounted() {},
@ -217,9 +141,7 @@ export default {
// this.ClassListinfo(); // this.ClassListinfo();
// this.selectAllClassByIdinfo(); // this.selectAllClassByIdinfo();
}, },
kinbatlist(kindergartenId, batchCode) { kinbatlist(kindergartenId, batchCode) {
console.log(kindergartenId, batchCode);
this.studentlistqueryParams.kindergartenId = kindergartenId; this.studentlistqueryParams.kindergartenId = kindergartenId;
this.studentlistqueryParams.batchCode = batchCode; this.studentlistqueryParams.batchCode = batchCode;
this.classqueryParams.kindergartenId = kindergartenId; this.classqueryParams.kindergartenId = kindergartenId;
@ -228,24 +150,23 @@ export default {
this.selectAllClassByquery.batchCode = batchCode; this.selectAllClassByquery.batchCode = batchCode;
}, },
ClassListinfo() { ClassListinfo() {
ClassList(this.classqueryParams).then((res) => {}); ClassList(this.classqueryParams).then(res => {});
}, },
StudentListinfo() { StudentListinfo() {
StudentList(this.studentlistqueryParams).then((res) => { StudentList(this.studentlistqueryParams).then(res => {
if (res.data.testAllStudentScoreVOList != null) { if (res.data.testAllStudentScoreVOList != null) {
this.studentlist = res.data.testAllStudentScoreVOList; this.studentlist = res.data.testAllStudentScoreVOList;
this.itemshow2 = false; this.itemshow2 = false;
this.itemshow = true; this.itemshow = true;
} }
if (res.data.allStudentScoreVOList != null) { if (res.data.allStudentScoreVOList != null) {
console.log(1);
this.yclassname1 = []; this.yclassname1 = [];
this.yclassname2 = []; this.yclassname2 = [];
this.yclassname3 = []; this.yclassname3 = [];
this.classscore1 = []; this.classscore1 = [];
this.classscore2 = []; this.classscore2 = [];
this.classscore3 = []; this.classscore3 = [];
res.data.allStudentScoreVOList.forEach((e) => { res.data.allStudentScoreVOList.forEach(e => {
if (e.classType == this.LARGECLASS) { if (e.classType == this.LARGECLASS) {
this.yclassname1.push(e.className); this.yclassname1.push(e.className);
if ( if (
@ -281,8 +202,7 @@ export default {
} }
} }
}); });
console.log(this.yclassname3, this.yclassname2); this.$nextTick(e => {
this.$nextTick((e) => {
if (this.yclassname1.length != 0) { if (this.yclassname1.length != 0) {
var myChart = echarts.init(document.getElementById("main")); var myChart = echarts.init(document.getElementById("main"));
} }
@ -312,37 +232,37 @@ export default {
"insideTopLeft", "insideTopLeft",
"insideTopRight", "insideTopRight",
"insideBottomLeft", "insideBottomLeft",
"insideBottomRight", "insideBottomRight"
]; ];
app.configParameters = { app.configParameters = {
rotate: { rotate: {
min: 0, min: 0,
max: 90, max: 90
}, },
align: { align: {
options: { options: {
left: "left", left: "left",
center: "center", center: "center",
right: "right", right: "right"
}, }
}, },
verticalAlign: { verticalAlign: {
options: { options: {
top: "top", top: "top",
middle: "middle", middle: "middle",
bottom: "bottom", bottom: "bottom"
}, }
}, },
position: { position: {
options: posList.reduce(function (map, pos) { options: posList.reduce(function(map, pos) {
map[pos] = pos; map[pos] = pos;
return map; return map;
}, {}), }, {})
}, },
distance: { distance: {
min: 0, min: 0,
max: 100, max: 100
}, }
}; };
app.config = { app.config = {
rotate: 0, rotate: 0,
@ -350,31 +270,31 @@ export default {
verticalAlign: "middle", verticalAlign: "middle",
position: "top", position: "top",
distance: 15, distance: 15,
onChange: function () { onChange: function() {
const labelOption = { const labelOption = {
rotate: app.config.rotate, rotate: app.config.rotate,
align: app.config.align, align: app.config.align,
verticalAlign: app.config.verticalAlign, verticalAlign: app.config.verticalAlign,
position: app.config.position, position: app.config.position,
distance: app.config.distance, distance: app.config.distance
}; };
myChart.setOption({ myChart.setOption({
series: [ series: [
{ {
label: labelOption, label: labelOption
}, },
{ {
label: labelOption, label: labelOption
}, },
{ {
label: labelOption, label: labelOption
}, },
{ {
label: labelOption, label: labelOption
}, }
], ]
}); });
}, }
}; };
const labelOption = { const labelOption = {
show: true, show: true,
@ -386,31 +306,31 @@ export default {
formatter: "{c}", formatter: "{c}",
fontSize: 16, fontSize: 16,
rich: { rich: {
name: {}, name: {}
}, }
}; };
option = { option = {
tooltip: { tooltip: {
trigger: "axis", trigger: "axis",
axisPointer: { axisPointer: {
type: "shadow", type: "shadow"
}, }
}, },
legend: {}, legend: {},
xAxis: [ xAxis: [
{ {
type: "category", type: "category",
axisTick: { show: false }, axisTick: { show: false },
data: this.yclassname1, data: this.yclassname1
}, }
], ],
yAxis: [ yAxis: [
{ {
type: "value", type: "value"
// max: (value) => { // max: (value) => {
// return Math.ceil(value.max / 100) * 100; // return Math.ceil(value.max / 100) * 100;
// }, // },
}, }
], ],
series: [ series: [
{ {
@ -420,31 +340,31 @@ export default {
color: "#00B050", color: "#00B050",
label: labelOption, label: labelOption,
emphasis: { emphasis: {
focus: "series", focus: "series"
}, },
data: this.classscore1, data: this.classscore1
}, }
], ]
}; };
option2 = { option2 = {
tooltip: { tooltip: {
trigger: "axis", trigger: "axis",
axisPointer: { axisPointer: {
type: "shadow", type: "shadow"
}, }
}, },
legend: {}, legend: {},
xAxis: [ xAxis: [
{ {
type: "category", type: "category",
axisTick: { show: false }, axisTick: { show: false },
data: this.yclassname2, data: this.yclassname2
}, }
], ],
yAxis: [ yAxis: [
{ {
type: "value", type: "value"
}, }
], ],
series: [ series: [
{ {
@ -455,31 +375,31 @@ export default {
color: "#00B050", color: "#00B050",
label: labelOption, label: labelOption,
emphasis: { emphasis: {
focus: "series", focus: "series"
}, },
data: this.classscore2, data: this.classscore2
}, }
], ]
}; };
option3 = { option3 = {
tooltip: { tooltip: {
trigger: "axis", trigger: "axis",
axisPointer: { axisPointer: {
type: "shadow", type: "shadow"
}, }
}, },
legend: {}, legend: {},
xAxis: [ xAxis: [
{ {
type: "category", type: "category",
axisTick: { show: false }, axisTick: { show: false },
data: this.yclassname3, data: this.yclassname3
}, }
], ],
yAxis: [ yAxis: [
{ {
type: "value", type: "value"
}, }
], ],
series: [ series: [
{ {
@ -489,11 +409,11 @@ export default {
color: "#00B050", color: "#00B050",
label: labelOption, label: labelOption,
emphasis: { emphasis: {
focus: "series", focus: "series"
}, },
data: this.classscore3, data: this.classscore3
}, }
], ]
}; };
if (this.yclassname1.length != 0) { if (this.yclassname1.length != 0) {
@ -526,13 +446,11 @@ export default {
}); });
}, },
selectAllClassByIdinfo() { selectAllClassByIdinfo() {
selectAllClassById(this.selectAllClassByquery).then((res) => { selectAllClassById(this.selectAllClassByquery).then(res => {});
console.log(this.selectAllClassBylist);
});
}, },
getList() { getList() {
// //
getRoleInfo().then((res) => { getRoleInfo().then(res => {
var user = res.data.roleKeys; var user = res.data.roleKeys;
if (user.includes("enchou")) { if (user.includes("enchou")) {
return; return;
@ -547,8 +465,8 @@ export default {
reset() { reset() {
this.form = {}; this.form = {};
this.resetForm("form"); this.resetForm("form");
}, }
}, }
}; };
</script> </script>
<style scoped='scss'> <style scoped='scss'>

View File

@ -28,7 +28,7 @@
:value="item.id" :value="item.id"
> >
</el-option> </el-option>
</el-select> --> </el-select>-->
</el-form-item> </el-form-item>
<el-form-item label="教师名称" prop="teacherName"> <el-form-item label="教师名称" prop="teacherName">
<el-input <el-input
@ -55,16 +55,8 @@
/> />
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
type="primary" <el-button icon="el-icon-refresh" size="mini" @click="resetQuery1">重置</el-button>
icon="el-icon-search"
size="mini"
@click="handleQuery"
>搜索</el-button
>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery1"
>重置</el-button
>
</el-form-item> </el-form-item>
</el-form> </el-form>
@ -77,8 +69,7 @@
size="mini" size="mini"
@click="handleAdd" @click="handleAdd"
v-hasPermi="['system:teacherInfo:add']" v-hasPermi="['system:teacherInfo:add']"
>新增</el-button >新增</el-button>
>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -89,8 +80,7 @@
:disabled="single" :disabled="single"
@click="handleUpdate" @click="handleUpdate"
v-hasPermi="['system:teacherInfo:edit']" v-hasPermi="['system:teacherInfo:edit']"
>修改</el-button >修改</el-button>
>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -101,8 +91,7 @@
:disabled="multiple" :disabled="multiple"
@click="handleDelete" @click="handleDelete"
v-hasPermi="['system:teacherInfo:remove']" v-hasPermi="['system:teacherInfo:remove']"
>删除</el-button >删除</el-button>
>
</el-col> </el-col>
<!-- <el-col :span="1.5"> <!-- <el-col :span="1.5">
<el-button <el-button
@ -114,44 +103,25 @@
v-hasPermi="['system:teacherInfo:export']" v-hasPermi="['system:teacherInfo:export']"
>导出</el-button >导出</el-button
> >
</el-col> --> </el-col>-->
<right-toolbar <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
:showSearch.sync="showSearch"
@queryTable="getList"
></right-toolbar>
</el-row> </el-row>
<el-table <el-table v-loading="loading" :data="teacherInfoList" @selection-change="handleSelectionChange">
v-loading="loading"
:data="teacherInfoList"
@selection-change="handleSelectionChange"
>
<el-table-column type="selection" width="55" align="center" /> <el-table-column type="selection" width="55" align="center" />
<el-table-column <el-table-column label="所属幼儿园" align="center" prop="kindergartenName" />
label="所属幼儿园"
align="center"
prop="kindergartenName"
/>
<el-table-column label="所属班级" align="center" prop="classInfoList"> <el-table-column label="所属班级" align="center" prop="classInfoList">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button size="mini" type="text" @click="teacherInfo(scope.row)" <el-button size="mini" type="text" @click="teacherInfo(scope.row)">查看</el-button>
>查看</el-button
>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="教师名称" align="center" prop="teacherName" /> <el-table-column label="教师名称" align="center" prop="teacherName" />
<el-table-column label="身份证号" align="center" prop="cardNo" /> <el-table-column label="身份证号" align="center" prop="cardNo" />
<el-table-column label="联系电话" align="center" prop="teacherPhone" /> <el-table-column label="联系电话" align="center" prop="teacherPhone" />
<el-table-column label="性别" align="center" prop="teacherSex"> <el-table-column label="性别" align="center" prop="teacherSex">
<template slot-scope="scope"> <template slot-scope="scope">{{ scope.row.teacherSex == "MALE" ? "男" : "女" }}</template>
{{ scope.row.teacherSex == "MALE" ? "男" : "女" }}
</template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
label="操作"
align="center"
class-name="small-padding fixed-width"
>
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
size="mini" size="mini"
@ -159,16 +129,14 @@
icon="el-icon-edit" icon="el-icon-edit"
@click="handleUpdate(scope.row)" @click="handleUpdate(scope.row)"
v-hasPermi="['system:teacherInfo:edit']" v-hasPermi="['system:teacherInfo:edit']"
>修改</el-button >修改</el-button>
>
<el-button <el-button
size="mini" size="mini"
type="text" type="text"
icon="el-icon-delete" icon="el-icon-delete"
@click="handleDelete(scope.row)" @click="handleDelete(scope.row)"
v-hasPermi="['system:teacherInfo:remove']" v-hasPermi="['system:teacherInfo:remove']"
>删除</el-button >删除</el-button>
>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -195,34 +163,29 @@
@click="innerVisible2 = true" @click="innerVisible2 = true"
style="width: 360px; text-align: left; height: 36px; color: #c0c4cc" style="width: 360px; text-align: left; height: 36px; color: #c0c4cc"
v-if="kindergartenName == '请选择所在幼儿园'" v-if="kindergartenName == '请选择所在幼儿园'"
>{{ kindergartenName }}</el-button >{{ kindergartenName }}</el-button>
>
<el-button <el-button
@click="innerVisible2 = true" @click="innerVisible2 = true"
style="width: 360px; text-align: left; height: 36px" style="width: 360px; text-align: left; height: 36px"
v-else v-else
>{{ kindergartenName }}</el-button >{{ kindergartenName }}</el-button>
>
</el-form-item> </el-form-item>
<el-form-item label="所属班级" prop="classInfoList" class="is-required"> <el-form-item label="所属班级" prop="classInfoList" class="is-required">
<el-button <el-button
@click="innerVisibleclick" @click="innerVisibleclick"
style="width: 360px; text-align: left; height: 36px; color: #c0c4cc" style="width: 360px; text-align: left; height: 36px; color: #c0c4cc"
v-if="classinfoName.length == 0" v-if="classinfoName.length == 0"
>请选择所属班级</el-button >请选择所属班级</el-button>
>
<el-tag <el-tag
v-for="(tag, index) in classinfoName" v-for="(tag, index) in classinfoName"
v-else v-else
:key="index" :key="index"
closable closable
type="" type
:disable-transitions="true" :disable-transitions="true"
@close="handleClose(tag, index)" @close="handleClose(tag, index)"
style="margin-right: 10px" style="margin-right: 10px"
> >{{ tag.className }}</el-tag>
{{ tag.className }}
</el-tag>
<el-tag <el-tag
v-if="classinfoName.length != 0" v-if="classinfoName.length != 0"
type="primary" type="primary"
@ -230,15 +193,10 @@
:disable-transitions="true" :disable-transitions="true"
@click="innerVisibletrue2" @click="innerVisibletrue2"
style="float: right; margin-top: 4px" style="float: right; margin-top: 4px"
>选择所属班级</el-tag >选择所属班级</el-tag>
>
</el-form-item> </el-form-item>
<el-form-item label="教师名称" prop="teacherName"> <el-form-item label="教师名称" prop="teacherName">
<el-input <el-input v-model="form.teacherName" placeholder="请输入教师名称" maxlength="10" />
v-model="form.teacherName"
placeholder="请输入教师名称"
maxlength="10"
/>
</el-form-item> </el-form-item>
<el-form-item label="身份证号" prop="cardNo"> <el-form-item label="身份证号" prop="cardNo">
<el-input v-model="form.cardNo" placeholder="请输入身份证号" maxlength="18" /> <el-input v-model="form.cardNo" placeholder="请输入身份证号" maxlength="18" />
@ -250,11 +208,7 @@
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
<el-form-item label="联系电话" prop="teacherPhone"> <el-form-item label="联系电话" prop="teacherPhone">
<el-input <el-input v-model="form.teacherPhone" placeholder="请输入联系电话" maxlength="11" />
v-model="form.teacherPhone"
placeholder="请输入联系电话"
maxlength="11"
/>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
@ -295,23 +249,12 @@
/> />
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery3">搜索</el-button>
type="primary" <el-button icon="el-icon-refresh" size="mini" @click="resetQuery2">重置</el-button>
icon="el-icon-search"
size="mini"
@click="handleQuery3"
>搜索</el-button
>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery2"
>重置</el-button
>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-table <el-table :data="kindergartenInfoList" @cell-dblclick="kindergartenNameclick">
:data="kindergartenInfoList"
@cell-dblclick="kindergartenNameclick"
>
<el-table-column label="请选择" width="70" align="center"> <el-table-column label="请选择" width="70" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
@ -331,41 +274,11 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column property="kindergartenName" label="幼儿园名字" width="150" align="center"></el-table-column>
property="kindergartenName" <el-table-column property="kindergartenAddress" label="幼儿园地址" width="150" align="center"></el-table-column>
label="幼儿园名字" <el-table-column label="幼儿园所在组织" align="center" prop="organizeName" width="150"></el-table-column>
width="150" <el-table-column property="contacts" label="联系人" width="150" align="center"></el-table-column>
align="center" <el-table-column property="phone" label="联系电话" width="150" align="center"></el-table-column>
>
</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> </el-table>
<pagination <pagination
@ -403,18 +316,13 @@
/> />
</el-form-item> </el-form-item>
<el-form-item label="班级类型" prop="classType"> <el-form-item label="班级类型" prop="classType">
<el-select <el-select v-model="classinfoList2.classType" placeholder="请选择" style="width: 150px">
v-model="classinfoList2.classType"
placeholder="请选择"
style="width: 150px"
>
<el-option <el-option
v-for="item in options" v-for="item in options"
:key="item.value" :key="item.value"
:label="item.label" :label="item.label"
:value="item.classType" :value="item.classType"
> ></el-option>
</el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="班主任姓名" prop="classTeacher"> <el-form-item label="班主任姓名" prop="classTeacher">
@ -427,16 +335,8 @@
/> />
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery2">搜索</el-button>
type="primary" <el-button icon="el-icon-refresh" size="mini" @click="resetQuery3">重置</el-button>
icon="el-icon-search"
size="mini"
@click="handleQuery2"
>搜索</el-button
>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery3"
>重置</el-button
>
</el-form-item> </el-form-item>
</el-form> </el-form>
@ -466,25 +366,9 @@
></el-button> ></el-button>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column property="kindergartenName" label="幼儿园名称" width="190" align="center" />
property="kindergartenName" <el-table-column property="className" label="班级名称" width="180" align="center"></el-table-column>
label="幼儿园名称" <el-table-column property="classType" label="班级类型" width="160" align="center">
width="190"
align="center"
/>
<el-table-column
property="className"
label="班级名称"
width="180"
align="center"
>
</el-table-column>
<el-table-column
property="classType"
label="班级类型"
width="160"
align="center"
>
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.classType == dictValue1 ? "大班" : "" }} {{ scope.row.classType == dictValue1 ? "大班" : "" }}
{{ scope.row.classType == dictValue2 ? "中班" : "" }} {{ scope.row.classType == dictValue2 ? "中班" : "" }}
@ -493,20 +377,8 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column property="classTeacher" label="班主任姓名" width="180" align="center"></el-table-column>
property="classTeacher" <el-table-column property="phone" label="联系电话" width="190" align="center"></el-table-column>
label="班主任姓名"
width="180"
align="center"
>
</el-table-column>
<el-table-column
property="phone"
label="联系电话"
width="190"
align="center"
>
</el-table-column>
</el-table> </el-table>
<pagination <pagination
v-show="total2 > 0" v-show="total2 > 0"
@ -526,8 +398,7 @@
height: 50px; height: 50px;
font-size: 15px; font-size: 15px;
" "
>选择完成</el-button >选择完成</el-button>
>
</el-dialog> </el-dialog>
<el-dialog <el-dialog
@ -538,24 +409,9 @@
:before-close="cancel4" :before-close="cancel4"
style="margin-top: 100px" style="margin-top: 100px"
> >
<el-table <el-table :data="teacherrclassinfo" align="center" style="margin-top: 10px">
:data="teacherrclassinfo" <el-table-column property="className" label="班级名称" width="180" align="center"></el-table-column>
align="center" <el-table-column property="classType" label="班级类型" width="160" align="center">
style="margin-top: 10px"
>
<el-table-column
property="className"
label="班级名称"
width="180"
align="center"
>
</el-table-column>
<el-table-column
property="classType"
label="班级类型"
width="160"
align="center"
>
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.classType == dictValue1 ? "大班" : "" }} {{ scope.row.classType == dictValue1 ? "大班" : "" }}
{{ scope.row.classType == dictValue2 ? "中班" : "" }} {{ scope.row.classType == dictValue2 ? "中班" : "" }}
@ -564,20 +420,8 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column property="classTeacher" label="班主任姓名" width="180" align="center"></el-table-column>
property="classTeacher" <el-table-column property="phone" label="联系电话" width="190" align="center"></el-table-column>
label="班主任姓名"
width="180"
align="center"
>
</el-table-column>
<el-table-column
property="phone"
label="联系电话"
width="190"
align="center"
>
</el-table-column>
</el-table> </el-table>
</el-dialog> </el-dialog>
</div> </div>
@ -590,12 +434,12 @@ import {
delTeacherInfo, delTeacherInfo,
addTeacherInfo, addTeacherInfo,
updateTeacherInfo, updateTeacherInfo,
getClassInfo, getClassInfo
} from "@/api/system/teacherInfo"; } from "@/api/system/teacherInfo";
import { listClassinfo } from "@/api/system/classinfo"; import { listClassinfo } from "@/api/system/classinfo";
import { import {
listKindergartenInfo, listKindergartenInfo,
tKindergartenInfo, tKindergartenInfo
} from "@/api/system/kindergartenInfo"; } from "@/api/system/kindergartenInfo";
export default { export default {
name: "TeacherInfo", name: "TeacherInfo",
@ -609,8 +453,7 @@ export default {
} else if (value == "") { } else if (value == "") {
cb(); cb();
} else { } else {
const regMobile = const regMobile = /^(?:(?:\+|00)86)?1(?:(?:3[\d])|(?:4[5-79])|(?:5[0-35-9])|(?:6[5-7])|(?:7[0-8])|(?:8[\d])|(?:9[189]))\d{8}$/;
/^(?:(?:\+|00)86)?1(?:(?:3[\d])|(?:4[5-79])|(?:5[0-35-9])|(?:6[5-7])|(?:7[0-8])|(?:8[\d])|(?:9[189]))\d{8}$/;
const reg = /^(0[0-9]{2,3}\-)([2-9][0-9]{6,7})+(\-[0-9]{1,4})?$/; const reg = /^(0[0-9]{2,3}\-)([2-9][0-9]{6,7})+(\-[0-9]{1,4})?$/;
const isTel = reg.test(value); const isTel = reg.test(value);
@ -631,9 +474,8 @@ export default {
var isCardId = (rule, value, callback) => { var isCardId = (rule, value, callback) => {
if (!value) { if (!value) {
return callback(); return callback();
} else { } else {
const reg = const reg = /^\d{6}(18|19|20)?\d{2}(0[1-9]|1[0-2])(([0-2][1-9])|10|20|30|31)\d{3}(\d|X|x)$/;
/^\d{6}(18|19|20)?\d{2}(0[1-9]|1[0-2])(([0-2][1-9])|10|20|30|31)\d{3}(\d|X|x)$/;
const card = reg.test(value); const card = reg.test(value);
if (!card) { if (!card) {
callback(new Error("身份证号格式有误!")); callback(new Error("身份证号格式有误!"));
@ -678,7 +520,7 @@ export default {
pageSize: 10, pageSize: 10,
kindergartenId: null, kindergartenId: null,
className: null, className: null,
classType: null, classType: null
}, },
dictValue1: "", dictValue1: "",
dictValue2: "", dictValue2: "",
@ -690,20 +532,20 @@ export default {
options: [ options: [
{ {
classType: "", classType: "",
label: "大班", label: "大班"
}, },
{ {
classType: "", classType: "",
label: "中班", label: "中班"
}, },
{ {
classType: "", classType: "",
label: "小班", label: "小班"
}, },
{ {
classType: "", classType: "",
label: "毕业", label: "毕业"
}, }
], ],
// //
title: "", title: "",
@ -719,14 +561,14 @@ export default {
cardNo: "", cardNo: "",
teacherPhone: "", teacherPhone: "",
teacherSex: "", teacherSex: "",
kindergartenName: "", kindergartenName: ""
}, },
queryParams2: { queryParams2: {
pageNum: 1, pageNum: 1,
pageSize: 10, pageSize: 10,
kindergartenId: null, kindergartenId: null,
className: null, className: null,
classType: null, classType: null
}, },
// //
form: { form: {
@ -736,43 +578,43 @@ export default {
cardNo: null, cardNo: null,
teacherPhone: null, teacherPhone: null,
teacherSex: null, teacherSex: null,
classInfoList: [], classInfoList: []
}, },
// //
rules: { rules: {
teacherSex: [ teacherSex: [
{ required: true, message: "请选择性别", trigger: "blur" }, { required: true, message: "请选择性别", trigger: "blur" }
], ],
teacherPhone: [ teacherPhone: [
{ {
validator: checkMobile, validator: checkMobile,
trigger: "blur", trigger: "blur",
message: "请输入正确的手机号", message: "请输入正确的手机号"
}, }
], ],
teacherName: [ teacherName: [
{ required: true, message: "请输入教师名称", trigger: "blur" }, { required: true, message: "请输入教师名称", trigger: "blur" }
], ],
cardNo: [ cardNo: [
{ message: "", trigger: "blur" }, { message: "", trigger: "blur" },
{ validator: isCardId, trigger: "blur" }, { validator: isCardId, trigger: "blur" }
], ],
classInfoList: [ classInfoList: [
{ required: true, message: "所属班级不能为空", trigger: "blur" }, { required: true, message: "所属班级不能为空", trigger: "blur" }
], ],
kindergartenId: [ kindergartenId: [
{ required: true, message: "所属幼儿园不能为空", trigger: "blur" }, { required: true, message: "所属幼儿园不能为空", trigger: "blur" }
], ]
}, }
}; };
}, },
computed: { computed: {
//id id true //id id true
containsclass() { containsclass() {
return function (id) { return function(id) {
return this.form.classInfoList.find((e) => e == id); return this.form.classInfoList.find(e => e == id);
}; };
}, }
}, },
created() { created() {
this.getList(); this.getList();
@ -780,7 +622,7 @@ export default {
methods: { methods: {
// //
getclassinfo() { getclassinfo() {
listClassinfo(this.classinfoList2).then((response) => { listClassinfo(this.classinfoList2).then(response => {
this.classinfoList = response.rows; this.classinfoList = response.rows;
this.total2 = response.total; this.total2 = response.total;
}); });
@ -810,15 +652,15 @@ export default {
}, },
classinfoclick2(item) { classinfoclick2(item) {
this.form.classInfoList = this.form.classInfoList.filter( this.form.classInfoList = this.form.classInfoList.filter(
(e) => e != item.id e => e != item.id
); );
this.classinfoName = this.classinfoName.filter((e) => e.id != item.id); this.classinfoName = this.classinfoName.filter(e => e.id != item.id);
}, },
classinfoclick(item) { classinfoclick(item) {
this.form.classInfoList = this.form.classInfoList.filter( this.form.classInfoList = this.form.classInfoList.filter(
(e) => e != item.id e => e != item.id
); );
this.classinfoName = this.classinfoName.filter((e) => e.id != item.id); this.classinfoName = this.classinfoName.filter(e => e.id != item.id);
this.form.classInfoList.push(item.id); this.form.classInfoList.push(item.id);
if (Array.isArray(this.classinfoName)) { if (Array.isArray(this.classinfoName)) {
@ -827,16 +669,13 @@ export default {
this.classinfoName = this.classinfoName.split(","); this.classinfoName = this.classinfoName.split(",");
this.classinfoName.push(item); this.classinfoName.push(item);
} }
console.log(this.classinfoName);
console.log(this.form.classInfoList);
}, },
// //
teacherInfo(row) { teacherInfo(row) {
this.innerVisible3 = true; this.innerVisible3 = true;
getClassInfo({ getClassInfo({
id: row.id, id: row.id
}).then((res) => { }).then(res => {
this.teacherrclassinfo = res.data; this.teacherrclassinfo = res.data;
}); });
}, },
@ -856,13 +695,13 @@ export default {
pageSize: 10, pageSize: 10,
kindergartenId: null, kindergartenId: null,
className: null, className: null,
classType: null, classType: null
}; };
this.handleQuery2(); this.handleQuery2();
}, },
//banjisousuo //banjisousuo
handleQuery2() { handleQuery2() {
listClassinfo(this.classinfoList2).then((response) => { listClassinfo(this.classinfoList2).then(response => {
this.classinfoList = response.rows; this.classinfoList = response.rows;
this.total2 = response.total; this.total2 = response.total;
}); });
@ -889,7 +728,7 @@ export default {
pageSize: 10, pageSize: 10,
kindergartenId: null, kindergartenId: null,
className: null, className: null,
classType: null, classType: null
}; };
this.handleQuery3(); this.handleQuery3();
this.innerVisible = false; this.innerVisible = false;
@ -907,7 +746,7 @@ export default {
pageSize: 10, pageSize: 10,
kindergartenId: null, kindergartenId: null,
className: null, className: null,
classType: null, classType: null
}; };
this.handleQuery2(); this.handleQuery2();
@ -928,14 +767,14 @@ export default {
cardNo: null, cardNo: null,
teacherPhone: null, teacherPhone: null,
teacherSex: null, teacherSex: null,
classInfoList: [], classInfoList: []
}; };
this.resetForm("form"); this.resetForm("form");
}, },
/** 搜索按钮操作 */ /** 搜索按钮操作 */
handleQuery() { handleQuery() {
this.queryParams.pageNum = 1; this.queryParams.pageNum = 1;
listTeacherInfo(this.queryParams).then((response) => { listTeacherInfo(this.queryParams).then(response => {
this.teacherInfoList = response.rows; this.teacherInfoList = response.rows;
this.total = response.total; this.total = response.total;
}); });
@ -950,7 +789,7 @@ export default {
cardNo: "", cardNo: "",
teacherPhone: "", teacherPhone: "",
teacherSex: "", teacherSex: "",
kindergartenName: "", kindergartenName: ""
}; };
this.handleQuery(); this.handleQuery();
}, },
@ -961,14 +800,14 @@ export default {
pageSize: 10, pageSize: 10,
kindergartenId: null, kindergartenId: null,
className: null, className: null,
classType: null, classType: null
}; };
this.handleQuery3(); this.handleQuery3();
}, },
/** 搜索按钮操作 */ /** 搜索按钮操作 */
handleQuery3() { handleQuery3() {
this.queryParams2.pageNum = 1; this.queryParams2.pageNum = 1;
listKindergartenInfo(this.queryParams2).then((response) => { listKindergartenInfo(this.queryParams2).then(response => {
this.kindergartenInfoList = response.rows; this.kindergartenInfoList = response.rows;
this.total3 = response.total; this.total3 = response.total;
}); });
@ -1007,16 +846,16 @@ export default {
/** 查询教师信息管理列表 */ /** 查询教师信息管理列表 */
getList() { getList() {
this.loading = true; this.loading = true;
listKindergartenInfo(this.queryParams2).then((response) => { listKindergartenInfo(this.queryParams2).then(response => {
this.kindergartenInfoList = response.rows; this.kindergartenInfoList = response.rows;
this.total3 = response.total; this.total3 = response.total;
}); });
listTeacherInfo(this.queryParams).then((response) => { listTeacherInfo(this.queryParams).then(response => {
this.teacherInfoList = response.rows; this.teacherInfoList = response.rows;
this.total = response.total; this.total = response.total;
this.loading = false; this.loading = false;
}); });
tKindergartenInfo(this.ClassType).then((res) => { tKindergartenInfo(this.ClassType).then(res => {
this.options[0].classType = res.data[0].dictValue; this.options[0].classType = res.data[0].dictValue;
this.options[1].classType = res.data[1].dictValue; this.options[1].classType = res.data[1].dictValue;
this.options[2].classType = res.data[2].dictValue; this.options[2].classType = res.data[2].dictValue;
@ -1029,7 +868,7 @@ export default {
}, },
// //
handleSelectionChange(selection) { handleSelectionChange(selection) {
this.ids = selection.map((item) => item.id); this.ids = selection.map(item => item.id);
this.single = selection.length !== 1; this.single = selection.length !== 1;
this.multiple = !selection.length; this.multiple = !selection.length;
}, },
@ -1054,7 +893,7 @@ export default {
this.classinfoName = []; this.classinfoName = [];
const id = row.id || this.ids; const id = row.id || this.ids;
getTeacherInfo(id) getTeacherInfo(id)
.then((response) => { .then(response => {
response.data.classInfoList = []; response.data.classInfoList = [];
this.form = response.data; this.form = response.data;
this.open = true; this.open = true;
@ -1063,25 +902,25 @@ export default {
this.kindergartenid = this.form.kindergartenId; this.kindergartenid = this.form.kindergartenId;
this.classinfoList2.kindergartenId = this.form.kindergartenId; this.classinfoList2.kindergartenId = this.form.kindergartenId;
}) })
.then((el) => { .then(el => {
this.getclassinfo(); this.getclassinfo();
}) })
.then((val) => { .then(val => {
getClassInfo({ getClassInfo({
id: row.id, id: row.id
}).then((res) => { }).then(res => {
this.form.classInfoList = res.data.map((e) => e.id); this.form.classInfoList = res.data.map(e => e.id);
this.form.classInfoList.join(","); this.form.classInfoList.join(",");
res.data.map((e) => this.classinfoName.push(e)); res.data.map(e => this.classinfoName.push(e));
}); });
}); });
}, },
/** 提交按钮 */ /** 提交按钮 */
submitForm() { submitForm() {
this.$refs["form"].validate((valid) => { this.$refs["form"].validate(valid => {
if (valid) { if (valid) {
if (this.form.id != null) { if (this.form.id != null) {
updateTeacherInfo(this.form).then((response) => { updateTeacherInfo(this.form).then(response => {
this.$modal.msgSuccess("修改成功"); this.$modal.msgSuccess("修改成功");
this.open = false; this.open = false;
this.kindergartenid = ""; this.kindergartenid = "";
@ -1090,7 +929,7 @@ export default {
this.resetQuery1(); this.resetQuery1();
}); });
} else { } else {
addTeacherInfo(this.form).then((response) => { addTeacherInfo(this.form).then(response => {
this.$modal.msgSuccess("新增成功"); this.$modal.msgSuccess("新增成功");
this.open = false; this.open = false;
this.resetQuery1(); this.resetQuery1();
@ -1107,7 +946,7 @@ export default {
const ids = row.id || this.ids; const ids = row.id || this.ids;
this.$modal this.$modal
.confirm("是否确认删除此教师的数据?") .confirm("是否确认删除此教师的数据?")
.then(function () { .then(function() {
return delTeacherInfo(ids); return delTeacherInfo(ids);
}) })
.then(() => { .then(() => {
@ -1121,11 +960,11 @@ export default {
this.download( this.download(
"system/teacherInfo/export", "system/teacherInfo/export",
{ {
...this.queryParams, ...this.queryParams
}, },
`teacherInfo_${new Date().getTime()}.xlsx` `teacherInfo_${new Date().getTime()}.xlsx`
); );
}, }
}, }
}; };
</script> </script>

View File

@ -34,18 +34,10 @@
clearable clearable
@keyup.enter.native="handleQuery2" @keyup.enter.native="handleQuery2"
/> />
</el-form-item> --> </el-form-item>-->
<el-form-item> <el-form-item>
<el-button <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery2">搜索</el-button>
type="primary" <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
icon="el-icon-search"
size="mini"
@click="handleQuery2"
>搜索</el-button
>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
>重置</el-button
>
</el-form-item> </el-form-item>
</el-form> </el-form>
@ -58,8 +50,7 @@
size="mini" size="mini"
@click="handleAdd" @click="handleAdd"
v-hasPermi="['system:testItemCityScore:add']" v-hasPermi="['system:testItemCityScore:add']"
>新增</el-button >新增</el-button>
>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -70,8 +61,7 @@
:disabled="single" :disabled="single"
@click="handleUpdate" @click="handleUpdate"
v-hasPermi="['system:testItemCityScore:edit']" v-hasPermi="['system:testItemCityScore:edit']"
>修改</el-button >修改</el-button>
>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -82,8 +72,7 @@
:disabled="multiple" :disabled="multiple"
@click="handleDelete" @click="handleDelete"
v-hasPermi="['system:testItemCityScore:remove']" v-hasPermi="['system:testItemCityScore:remove']"
>删除</el-button >删除</el-button>
>
</el-col> </el-col>
<!-- <el-col :span="1.5"> <!-- <el-col :span="1.5">
<el-button <el-button
@ -95,11 +84,8 @@
v-hasPermi="['system:testItemCityScore:export']" v-hasPermi="['system:testItemCityScore:export']"
>导出</el-button >导出</el-button
> >
</el-col> --> </el-col>-->
<right-toolbar <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
:showSearch.sync="showSearch"
@queryTable="getList"
></right-toolbar>
</el-row> </el-row>
<el-table <el-table
@ -127,11 +113,7 @@
{{ scope.row.dictValue == "text" ? scope.row.itemAvgText : "" }} {{ scope.row.dictValue == "text" ? scope.row.itemAvgText : "" }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
label="操作"
align="center"
class-name="small-padding fixed-width"
>
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
size="mini" size="mini"
@ -139,16 +121,14 @@
icon="el-icon-edit" icon="el-icon-edit"
@click="handleUpdate(scope.row)" @click="handleUpdate(scope.row)"
v-hasPermi="['system:testItemCityScore:edit']" v-hasPermi="['system:testItemCityScore:edit']"
>修改</el-button >修改</el-button>
>
<el-button <el-button
size="mini" size="mini"
type="text" type="text"
icon="el-icon-delete" icon="el-icon-delete"
@click="handleDelete(scope.row)" @click="handleDelete(scope.row)"
v-hasPermi="['system:testItemCityScore:remove']" v-hasPermi="['system:testItemCityScore:remove']"
>删除</el-button >删除</el-button>
>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -184,44 +164,26 @@
@click="innerVisiblexm" @click="innerVisiblexm"
style="width: 380px; text-align: left; height: 36px; color: #c0c4cc" style="width: 380px; text-align: left; height: 36px; color: #c0c4cc"
v-if="xmname == '请选择所属项目'" v-if="xmname == '请选择所属项目'"
> >{{ xmname }}</el-button>
{{ xmname }}
</el-button>
<el-button <el-button
@click="innerVisiblexm" @click="innerVisiblexm"
style="width: 380px; text-align: left; height: 36px" style="width: 380px; text-align: left; height: 36px"
v-else v-else
> >{{ xmname }}</el-button>
{{ xmname }}
</el-button>
</el-form-item> </el-form-item>
<el-form-item label="学生性别" prop="sex"> <el-form-item label="学生性别" prop="sex">
<el-select <el-select v-model="form.sex" clearable placeholder="请选择" style="width: 380px">
v-model="form.sex"
clearable
placeholder="请选择"
style="width: 380px"
>
<el-option <el-option
v-for="item in sexs" v-for="item in sexs"
:key="item.value" :key="item.value"
:label="item.label" :label="item.label"
:value="item.value" :value="item.value"
@click.native="sexclick(item)" @click.native="sexclick(item)"
> ></el-option>
</el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item <el-form-item label="平均得分" :required="true" v-if="form.resultDictType == ''">
label="平均得分" <el-input v-model="value" placeholder="请输入平均得分" maxlength="10" />
:required="true"
v-if="form.resultDictType == ''"
>
<el-input
v-model="value"
placeholder="请输入平均得分"
maxlength="10"
/>
</el-form-item> </el-form-item>
<el-form-item <el-form-item
@ -230,11 +192,7 @@
key="itemAvgScore" key="itemAvgScore"
prop="itemAvgScore" prop="itemAvgScore"
> >
<el-input <el-input v-model="form.itemAvgScore" placeholder="请输入平均得分" maxlength="10" />
v-model="form.itemAvgScore"
placeholder="请输入平均得分"
maxlength="10"
/>
</el-form-item> </el-form-item>
<el-form-item <el-form-item
@ -243,11 +201,7 @@
key="itemAvgText" key="itemAvgText"
prop="itemAvgText" prop="itemAvgText"
> >
<el-input <el-input v-model="form.itemAvgText" placeholder="请输入平均得分" maxlength="100" />
v-model="form.itemAvgText"
placeholder="请输入平均得分"
maxlength="100"
/>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
@ -283,9 +237,7 @@
@click="innerVisible = true" @click="innerVisible = true"
style="width: 380px; text-align: left; height: 36px; color: #c0c4cc" style="width: 380px; text-align: left; height: 36px; color: #c0c4cc"
v-if="xmname == '请选择所属项目'" v-if="xmname == '请选择所属项目'"
> >{{ xmname }}</el-button>
{{ xmname }}
</el-button>
<el-button <el-button
type="info" type="info"
plain plain
@ -293,48 +245,23 @@
@click="innerVisible = true" @click="innerVisible = true"
style="width: 380px; text-align: left; height: 36px" style="width: 380px; text-align: left; height: 36px"
v-else v-else
> >{{ xmname }}</el-button>
{{ xmname }}
</el-button>
</el-form-item> </el-form-item>
<el-form-item label="学生性别" prop="sex"> <el-form-item label="学生性别" prop="sex">
<el-select <el-select v-model="form.sex" clearable disabled placeholder="请选择" style="width: 380px">
v-model="form.sex"
clearable
disabled
placeholder="请选择"
style="width: 380px"
>
<el-option <el-option
v-for="item in sexs" v-for="item in sexs"
:key="item.value" :key="item.value"
:label="item.label" :label="item.label"
:value="item.value" :value="item.value"
> ></el-option>
</el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item <el-form-item label="平均得分" prop="itemAvgScore" v-if="form.dictValue == 'number'">
label="平均得分" <el-input v-model="form.itemAvgScore" placeholder="请输入平均得分" maxlength="10" />
prop="itemAvgScore"
v-if="form.dictValue == 'number'"
>
<el-input
v-model="form.itemAvgScore"
placeholder="请输入平均得分"
maxlength="10"
/>
</el-form-item> </el-form-item>
<el-form-item <el-form-item label="平均得分" prop="itemAvgText" v-if="form.dictValue == 'text'">
label="平均得分" <el-input v-model="form.itemAvgText" placeholder="请输入平均得分" maxlength="100" />
prop="itemAvgText"
v-if="form.dictValue == 'text'"
>
<el-input
v-model="form.itemAvgText"
placeholder="请输入平均得分"
maxlength="100"
/>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
@ -351,18 +278,8 @@
append-to-body append-to-body
:before-close="cancel2" :before-close="cancel2"
> >
<el-form <el-form :model="queryParams2" ref="queryForm" size="small" :inline="true" label-width="70px">
:model="queryParams2" <el-form-item label="所属项目分类" prop="itemCategoryId" label-width="100px">
ref="queryForm"
size="small"
:inline="true"
label-width="70px"
>
<el-form-item
label="所属项目分类"
prop="itemCategoryId"
label-width="100px"
>
<treeselect <treeselect
:normalizer="normalizer2" :normalizer="normalizer2"
:options="itemCategoryList" :options="itemCategoryList"
@ -398,18 +315,10 @@
clearable clearable
@keyup.enter.native="handleQuery" @keyup.enter.native="handleQuery"
/> />
</el-form-item> --> </el-form-item>-->
<el-form-item> <el-form-item>
<el-button <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
type="primary" <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
icon="el-icon-search"
size="mini"
@click="handleQuery"
>搜索</el-button
>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
>重置</el-button
>
</el-form-item> </el-form-item>
</el-form> </el-form>
@ -429,32 +338,22 @@
@click="xmclick2(scope.row)" @click="xmclick2(scope.row)"
></el-button> ></el-button>
<el-button <el-button v-else style="width: 15px; height: 15px" circle @click="xmclick(scope.row)"></el-button>
v-else
style="width: 15px; height: 15px"
circle
@click="xmclick(scope.row)"
></el-button>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column label="项目所属分类" align="center" prop="categoryName" width="80px" />
label="项目所属分类"
align="center"
prop="categoryName"
width="80px"
/>
<el-table-column label="字典类型" align="center" prop="resultDictType"> <el-table-column label="字典类型" align="center" prop="resultDictType">
<template slot-scope="scope"> <template slot-scope="scope">
{{ {{
scope.row.resultDictType == ResultType1.dictCode scope.row.resultDictType == ResultType1.dictCode
? ResultType1.dictLabel ? ResultType1.dictLabel
: "" : ""
}}{{ }}{{
scope.row.resultDictType == ResultType2.dictCode scope.row.resultDictType == ResultType2.dictCode
? ResultType2.dictLabel ? ResultType2.dictLabel
: "" : ""
}}</template }}
> </template>
</el-table-column> </el-table-column>
<el-table-column label="项目名称" align="center" prop="itemName" /> <el-table-column label="项目名称" align="center" prop="itemName" />
<el-table-column label="项目编号" align="center" prop="itemCode" /> <el-table-column label="项目编号" align="center" prop="itemCode" />
@ -485,7 +384,7 @@
align="center" align="center"
prop="unifiedStandardScore" prop="unifiedStandardScore"
/> />
<el-table-column label="排序" align="center" prop="sorting" /> --> <el-table-column label="排序" align="center" prop="sorting" />-->
</el-table> </el-table>
<pagination <pagination
@ -506,7 +405,7 @@ import {
delTestItemCityScore, delTestItemCityScore,
addTestItemCityScore, addTestItemCityScore,
updateTestItemCityScore, updateTestItemCityScore,
getItemCityScoreInfo, getItemCityScoreInfo
} from "@/api/system/testItemCityScore"; } from "@/api/system/testItemCityScore";
import { tKindergartenInfo } from "@/api/system/kindergartenInfo"; import { tKindergartenInfo } from "@/api/system/kindergartenInfo";
import { listItemCategory } from "@/api/system/itemCategory"; import { listItemCategory } from "@/api/system/itemCategory";
@ -520,13 +419,11 @@ export default {
data() { data() {
var roleMoeny = (rule, value, callback) => { var roleMoeny = (rule, value, callback) => {
var str = String(this.form.itemAvgScore); var str = String(this.form.itemAvgScore);
console.log(str);
var str_ = ""; var str_ = "";
var str2 = ""; var str2 = "";
if (str.includes(".")) { if (str.includes(".")) {
str_ = str.substr(str.indexOf(".")).length; str_ = str.substr(str.indexOf(".")).length;
str2 = str.substr(0, str.indexOf(".")).length; str2 = str.substr(0, str.indexOf(".")).length;
console.log(str2);
if (Number.isNaN(Number.parseFloat(str))) { if (Number.isNaN(Number.parseFloat(str))) {
callback(new Error("请输入数字")); callback(new Error("请输入数字"));
} else if (!this.form.itemAvgScore) { } else if (!this.form.itemAvgScore) {
@ -544,7 +441,6 @@ export default {
} }
} else { } else {
str2 = str.length; str2 = str.length;
console.log(str2);
if (Number.isNaN(Number.parseFloat(str))) { if (Number.isNaN(Number.parseFloat(str))) {
callback(new Error("请输入数字")); callback(new Error("请输入数字"));
} else if (!this.form.itemAvgScore) { } else if (!this.form.itemAvgScore) {
@ -562,8 +458,6 @@ export default {
}; };
var roleMoeny1 = (rule, value, callback) => { var roleMoeny1 = (rule, value, callback) => {
var str = String(this.form.itemAvgText); var str = String(this.form.itemAvgText);
console.log(value);
console.log(this.form);
var str_ = ""; var str_ = "";
var str2 = ""; var str2 = "";
if (str.includes(".")) { if (str.includes(".")) {
@ -598,12 +492,12 @@ export default {
sexs: [ sexs: [
{ {
label: "男", label: "男",
value: "MALE", value: "MALE"
}, },
{ {
label: "女", label: "女",
value: "FEMALE", value: "FEMALE"
}, }
], ],
value: "", value: "",
// //
@ -653,7 +547,7 @@ export default {
pageSize: 10, pageSize: 10,
areaId: null, areaId: null,
itemId: null, itemId: null,
itemAvgScore: null, itemAvgScore: null
}, },
// //
queryParams2: { queryParams2: {
@ -661,18 +555,18 @@ export default {
pageSize: 10, pageSize: 10,
itemCategoryId: null, itemCategoryId: null,
itemName: null, itemName: null,
itemCode: null, itemCode: null
}, },
getItemCityScorelist: { getItemCityScorelist: {
areaId: null, areaId: null,
itemId: null, itemId: null,
sex: null, sex: null
}, },
// //
form: { form: {
resultDictType: "", resultDictType: "",
itemAvgScore: "123", itemAvgScore: "123",
itemAvgText: "456", itemAvgText: "456"
}, },
// //
rules: { rules: {
@ -683,16 +577,14 @@ export default {
required: true, required: true,
validator: roleMoeny1, validator: roleMoeny1,
message: "", message: "",
trigger: "blur", trigger: "blur"
}, }
], ],
areaId: [ areaId: [
{ required: true, message: "请选择所属区域", trigger: "blur" }, { required: true, message: "请选择所属区域", trigger: "blur" }
], ],
itemId: [ itemId: [{ required: true, message: "请选择所属项目", trigger: "blur" }]
{ required: true, message: "请选择所属项目", trigger: "blur" }, }
],
},
}; };
}, },
created() { created() {
@ -719,7 +611,7 @@ export default {
} }
}, },
getItemCityScore() { getItemCityScore() {
getItemCityScoreInfo(this.getItemCityScorelist).then((res) => { getItemCityScoreInfo(this.getItemCityScorelist).then(res => {
if (res.data) { if (res.data) {
if (res.data.itemAvgScore == null) { if (res.data.itemAvgScore == null) {
this.form.itemAvgText = res.data.itemAvgText; this.form.itemAvgText = res.data.itemAvgText;
@ -732,8 +624,6 @@ export default {
this.form.itemAvgScore = null; this.form.itemAvgScore = null;
this.form.itemAvgText = null; this.form.itemAvgText = null;
} }
console.log(this.form);
}); });
}, },
innerVisiblexm() { innerVisiblexm() {
@ -746,7 +636,7 @@ export default {
return { return {
itemId: node.id, itemId: node.id,
label: node.itemName, label: node.itemName,
children: node.children, children: node.children
}; };
}, },
normalizer2(node) { normalizer2(node) {
@ -756,7 +646,7 @@ export default {
return { return {
itemCategoryId: node.id, itemCategoryId: node.id,
label: node.categoryName, label: node.categoryName,
children: node.children, children: node.children
}; };
}, },
xmclick2(item) { xmclick2(item) {
@ -785,40 +675,32 @@ export default {
) { ) {
this.getItemCityScore(); this.getItemCityScore();
} }
console.log(this.ResultType1, this.ResultType2);
console.log(this.form);
}, },
/** 查询全市平均成绩列表 */ /** 查询全市平均成绩列表 */
getList() { getList() {
this.loading = true; this.loading = true;
listArea(this.queryParams2).then((response) => { listArea(this.queryParams2).then(response => {
// this.areaList = response.data.forEach((e) => { // this.areaList = response.data.forEach((e) => {
// e.code = Number(e.code); // e.code = Number(e.code);
// }); // });
this.areaList = this.handleTree(response.data); this.areaList = this.handleTree(response.data);
// console.log(this.areaList);
}); });
listTestItemCityScore(this.queryParams).then((response) => { listTestItemCityScore(this.queryParams).then(response => {
this.testItemCityScoreList = response.rows; this.testItemCityScoreList = response.rows;
this.total = response.total; this.total = response.total;
this.loading = false; this.loading = false;
console.log(this.testItemCityScoreList);
}); });
listTestItems(this.queryParams2).then((response) => { listTestItems(this.queryParams2).then(response => {
this.testItemsList = response.rows; this.testItemsList = response.rows;
this.testItemsList2 = this.handleTree(response.rows); this.testItemsList2 = this.handleTree(response.rows);
// console.log(this.testItemsList);
}); });
listItemCategory(this.queryParams2).then((response) => { listItemCategory(this.queryParams2).then(response => {
this.itemCategoryList = this.handleTree(response.data); this.itemCategoryList = this.handleTree(response.data);
// console.log(this.itemCategoryList);
}); });
tKindergartenInfo(this.itemResultType).then((res) => { tKindergartenInfo(this.itemResultType).then(res => {
// console.log(res);
this.itemResultTypelist = res.data; this.itemResultTypelist = res.data;
this.ResultType1 = this.itemResultTypelist[0]; this.ResultType1 = this.itemResultTypelist[0];
this.ResultType2 = this.itemResultTypelist[1]; this.ResultType2 = this.itemResultTypelist[1];
console.log(this.ResultType1, this.ResultType2);
}); });
}, },
// //
@ -829,7 +711,7 @@ export default {
pageSize: 10, pageSize: 10,
itemCategoryId: null, itemCategoryId: null,
itemName: null, itemName: null,
itemCode: null, itemCode: null
}; };
this.getList(); this.getList();
}, },
@ -849,17 +731,15 @@ export default {
itemId: null, itemId: null,
resultDictType: "", resultDictType: "",
itemAvgScore: "", itemAvgScore: "",
itemAvgText: "", itemAvgText: ""
}; };
}, },
/** 搜索按钮操作 */ /** 搜索按钮操作 */
handleQuery2() { handleQuery2() {
console.log(this.queryParams); listTestItemCityScore(this.queryParams).then(response => {
listTestItemCityScore(this.queryParams).then((response) => {
this.testItemCityScoreList = response.rows; this.testItemCityScoreList = response.rows;
this.total = response.total; this.total = response.total;
this.loading = false; this.loading = false;
console.log(this.testItemCityScoreList);
}); });
}, },
handleQuery() { handleQuery() {
@ -875,15 +755,14 @@ export default {
areaId: null, areaId: null,
itemId: null, itemId: null,
itemAvgScore: null, itemAvgScore: null,
itemAvgText: null, itemAvgText: null
}; };
this.handleQuery(); this.handleQuery();
}, },
// //
handleSelectionChange(selection) { handleSelectionChange(selection) {
console.log(selection); this.ids = selection.map(item => item.id);
this.ids = selection.map((item) => item.id); this.name = selection.map(item => item.itemName);
this.name = selection.map((item) => item.itemName);
this.single = selection.length !== 1; this.single = selection.length !== 1;
this.multiple = !selection.length; this.multiple = !selection.length;
}, },
@ -893,7 +772,7 @@ export default {
this.getItemCityScorelist = { this.getItemCityScorelist = {
areaId: null, areaId: null,
itemId: null, itemId: null,
sex: null, sex: null
}; };
this.open = true; this.open = true;
this.title = "添加全市平均成绩"; this.title = "添加全市平均成绩";
@ -902,36 +781,32 @@ export default {
handleUpdate(row) { handleUpdate(row) {
this.reset(); this.reset();
const id = row.id || this.ids; const id = row.id || this.ids;
getTestItemCityScore(id).then((response) => { getTestItemCityScore(id).then(response => {
this.form = response.data; this.form = response.data;
this.open2 = true; this.open2 = true;
this.title = "修改全市平均成绩"; this.title = "修改全市平均成绩";
this.xmname = this.form.itemName; this.xmname = this.form.itemName;
this.xmid = this.form.itemId; this.xmid = this.form.itemId;
console.log(this.form);
}); });
}, },
/** 提交按钮 */ /** 提交按钮 */
submitForm() { submitForm() {
if (this.form.resultDictType == this.ResultType1.dictValue) { if (this.form.resultDictType == this.ResultType1.dictValue) {
console.log(this.ResultType1.dictValue);
this.form.itemAvgText = ""; this.form.itemAvgText = "";
} }
if (this.form.resultDictType == this.ResultType2.dictValue) { if (this.form.resultDictType == this.ResultType2.dictValue) {
console.log(this.ResultType2.dictValue);
this.form.itemAvgScore = ""; this.form.itemAvgScore = "";
} }
console.log(this.form); this.$refs["form"].validate(valid => {
this.$refs["form"].validate((valid) => {
if (valid) { if (valid) {
if (this.form.id != null) { if (this.form.id != null) {
updateTestItemCityScore(this.form).then((response) => { updateTestItemCityScore(this.form).then(response => {
this.$modal.msgSuccess("修改成功"); this.$modal.msgSuccess("修改成功");
this.open2 = false; this.open2 = false;
this.getList(); this.getList();
}); });
} else { } else {
addTestItemCityScore(this.form).then((response) => { addTestItemCityScore(this.form).then(response => {
this.$modal.msgSuccess("新增成功"); this.$modal.msgSuccess("新增成功");
this.open = false; this.open = false;
this.getList(); this.getList();
@ -945,12 +820,11 @@ export default {
}, },
/** 删除按钮操作 */ /** 删除按钮操作 */
handleDelete(row) { handleDelete(row) {
console.log(row);
const ids = row.id || this.ids; const ids = row.id || this.ids;
const name = row.itemName || this.name; const name = row.itemName || this.name;
this.$modal this.$modal
.confirm('是否确认删除项目名称为"' + name + '"的全市平均成绩?') .confirm('是否确认删除项目名称为"' + name + '"的全市平均成绩?')
.then(function () { .then(function() {
return delTestItemCityScore(ids); return delTestItemCityScore(ids);
}) })
.then(() => { .then(() => {
@ -967,7 +841,7 @@ export default {
return { return {
areaId: node.id, areaId: node.id,
label: node.name, label: node.name,
children: node.children, children: node.children
}; };
}, },
/** 导出按钮操作 */ /** 导出按钮操作 */
@ -975,11 +849,11 @@ export default {
this.download( this.download(
"system/testItemCityScore/export", "system/testItemCityScore/export",
{ {
...this.queryParams, ...this.queryParams
}, },
`testItemCityScore_${new Date().getTime()}.xlsx` `testItemCityScore_${new Date().getTime()}.xlsx`
); );
}, }
}, }
}; };
</script> </script>

View File

@ -18,16 +18,8 @@
/> />
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
type="primary" <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
icon="el-icon-search"
size="mini"
@click="handleQuery"
>搜索</el-button
>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
>重置</el-button
>
</el-form-item> </el-form-item>
</el-form> </el-form>
@ -40,8 +32,7 @@
size="mini" size="mini"
@click="handleAdd" @click="handleAdd"
v-hasPermi="['system:testItemCountryScore:add']" v-hasPermi="['system:testItemCountryScore:add']"
>新增</el-button >新增</el-button>
>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -52,8 +43,7 @@
:disabled="single" :disabled="single"
@click="handleUpdate" @click="handleUpdate"
v-hasPermi="['system:testItemCountryScore:edit']" v-hasPermi="['system:testItemCountryScore:edit']"
>修改</el-button >修改</el-button>
>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -64,8 +54,7 @@
:disabled="multiple" :disabled="multiple"
@click="handleDelete" @click="handleDelete"
v-hasPermi="['system:testItemCountryScore:remove']" v-hasPermi="['system:testItemCountryScore:remove']"
>删除</el-button >删除</el-button>
>
</el-col> </el-col>
<!-- <el-col :span="1.5"> <!-- <el-col :span="1.5">
<el-button <el-button
@ -77,11 +66,8 @@
v-hasPermi="['system:testItemCountryScore:export']" v-hasPermi="['system:testItemCountryScore:export']"
>导出</el-button >导出</el-button
> >
</el-col> --> </el-col>-->
<right-toolbar <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
:showSearch.sync="showSearch"
@queryTable="getList"
></right-toolbar>
</el-row> </el-row>
<el-table <el-table
@ -104,11 +90,7 @@
{{ scope.row.dictValue == "text" ? scope.row.itemAvgText : "" }} {{ scope.row.dictValue == "text" ? scope.row.itemAvgText : "" }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
label="操作"
align="center"
class-name="small-padding fixed-width"
>
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
size="mini" size="mini"
@ -116,16 +98,14 @@
icon="el-icon-edit" icon="el-icon-edit"
@click="handleUpdate(scope.row)" @click="handleUpdate(scope.row)"
v-hasPermi="['system:testItemCountryScore:edit']" v-hasPermi="['system:testItemCountryScore:edit']"
>修改</el-button >修改</el-button>
>
<el-button <el-button
size="mini" size="mini"
type="text" type="text"
icon="el-icon-delete" icon="el-icon-delete"
@click="handleDelete(scope.row)" @click="handleDelete(scope.row)"
v-hasPermi="['system:testItemCountryScore:remove']" v-hasPermi="['system:testItemCountryScore:remove']"
>删除</el-button >删除</el-button>
>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -146,13 +126,7 @@
append-to-body append-to-body
:before-close="cancel2" :before-close="cancel2"
> >
<el-form <el-form ref="form" :model="form" :rules="rulesxg" label-width="80px" style>
ref="form"
:model="form"
:rules="rulesxg"
label-width="80px"
style=""
>
<el-form-item label="所属项目" prop="itemId"> <el-form-item label="所属项目" prop="itemId">
<el-button <el-button
type="info" type="info"
@ -167,8 +141,7 @@
color: #c0c4cc; color: #c0c4cc;
padding-left: -10px; padding-left: -10px;
" "
>{{ xmname }}</el-button >{{ xmname }}</el-button>
>
<el-button <el-button
type="info" type="info"
@ -182,31 +155,19 @@
height: 36px; height: 36px;
padding-left: -10px; padding-left: -10px;
" "
>{{ xmname }}</el-button >{{ xmname }}</el-button>
>
</el-form-item> </el-form-item>
<el-form-item label="学生性别" prop="sex"> <el-form-item label="学生性别" prop="sex">
<el-select <el-select v-model="form.sex" clearable disabled placeholder="请选择" style="width: 360px">
v-model="form.sex"
clearable
disabled
placeholder="请选择"
style="width: 360px"
>
<el-option <el-option
v-for="item in sexs" v-for="item in sexs"
:key="item.value" :key="item.value"
:label="item.label" :label="item.label"
:value="item.value" :value="item.value"
> ></el-option>
</el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item <el-form-item label="平均得分" prop="itemAvgScore" v-if="form.dictValue == 'number'">
label="平均得分"
prop="itemAvgScore"
v-if="form.dictValue == 'number'"
>
<el-input <el-input
v-model="form.itemAvgScore" v-model="form.itemAvgScore"
style="width: 360px" style="width: 360px"
@ -214,11 +175,7 @@
maxlength="10" maxlength="10"
/> />
</el-form-item> </el-form-item>
<el-form-item <el-form-item label="平均得分" prop="itemAvgText" v-if="form.dictValue == 'text'">
label="平均得分"
prop="itemAvgText"
v-if="form.dictValue == 'text'"
>
<el-input <el-input
v-model="form.itemAvgText" v-model="form.itemAvgText"
placeholder="请输入平均得分" placeholder="请输入平均得分"
@ -242,16 +199,10 @@
append-to-body append-to-body
:before-close="cancel" :before-close="cancel"
> >
<el-form <el-form ref="form2" :model="form2" :rules="rules" label-width="80px" style>
ref="form2"
:model="form2"
:rules="rules"
label-width="80px"
style=""
>
<el-form-item label="所属项目" prop="itemId"> <el-form-item label="所属项目" prop="itemId">
<el-button <el-button
type="" type
@click="innerVisible = true" @click="innerVisible = true"
v-if="xmname == '请选择所属项目'" v-if="xmname == '请选择所属项目'"
style=" style="
@ -261,11 +212,10 @@
color: #c0c4cc; color: #c0c4cc;
padding-left: -10px; padding-left: -10px;
" "
>{{ xmname }}</el-button >{{ xmname }}</el-button>
>
<el-button <el-button
type="" type
@click="innerVisible = true" @click="innerVisible = true"
v-else v-else
style=" style="
@ -274,44 +224,24 @@
height: 36px; height: 36px;
padding-left: -10px; padding-left: -10px;
" "
>{{ xmname }}</el-button >{{ xmname }}</el-button>
>
</el-form-item> </el-form-item>
<el-form-item label="学生性别" prop="sex"> <el-form-item label="学生性别" prop="sex">
<el-select <el-select v-model="form2.sex" clearable placeholder="请选择" style="width: 360px">
v-model="form2.sex"
clearable
placeholder="请选择"
style="width: 360px"
>
<el-option <el-option
v-for="item in sexs" v-for="item in sexs"
:key="item.value" :key="item.value"
:label="item.label" :label="item.label"
:value="item.value" :value="item.value"
@click.native="sexclick(item)" @click.native="sexclick(item)"
> ></el-option>
</el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item <el-form-item label="平均得分" prop="itemAvgScore1" v-if="form2.resultDictType == ''">
label="平均得分" <el-input v-model="value" placeholder="请输入平均得分" style="width: 360px" maxlength="10" />
prop="itemAvgScore1"
v-if="form2.resultDictType == ''"
>
<el-input
v-model="value"
placeholder="请输入平均得分"
style="width: 360px"
maxlength="10"
/>
</el-form-item> </el-form-item>
<el-form-item <el-form-item label="平均得分" prop="itemAvgScore" v-else-if="form2.resultDictType == 'number'">
label="平均得分"
prop="itemAvgScore"
v-else-if="form2.resultDictType == 'number'"
>
<el-input <el-input
v-model="form2.itemAvgScore" v-model="form2.itemAvgScore"
placeholder="请输入平均得分" placeholder="请输入平均得分"
@ -320,11 +250,7 @@
/> />
</el-form-item> </el-form-item>
<el-form-item <el-form-item label="平均得分" prop="itemAvgText" v-else-if="form2.resultDictType == 'text'">
label="平均得分"
prop="itemAvgText"
v-else-if="form2.resultDictType == 'text'"
>
<el-input <el-input
v-model="form2.itemAvgText" v-model="form2.itemAvgText"
placeholder="请输入平均得分" placeholder="请输入平均得分"
@ -340,12 +266,7 @@
</el-dialog> </el-dialog>
<!-- 项目弹窗 --> <!-- 项目弹窗 -->
<el-dialog <el-dialog width="850px" title="选择所属项目" :visible.sync="innerVisible" append-to-body>
width="850px"
title="选择所属项目"
:visible.sync="innerVisible"
append-to-body
>
<el-form <el-form
:model="queryParams2" :model="queryParams2"
ref="queryForm" ref="queryForm"
@ -371,16 +292,8 @@
/> />
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery2">搜索</el-button>
type="primary" <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
icon="el-icon-search"
size="mini"
@click="handleQuery2"
>搜索</el-button
>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
>重置</el-button
>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-table :data="testItemslists" @cell-dblclick="xmclick"> <el-table :data="testItemslists" @cell-dblclick="xmclick">
@ -394,126 +307,42 @@
@click="xmclick(scope.row)" @click="xmclick(scope.row)"
></el-button> ></el-button>
<el-button <el-button v-else style="width: 15px; height: 15px" circle @click="xmclick(scope.row)"></el-button>
v-else
style="width: 15px; height: 15px"
circle
@click="xmclick(scope.row)"
></el-button>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column property="itemName" label="项目名称" width="150" align="center"></el-table-column>
property="itemName"
label="项目名称"
width="150"
align="center"
>
</el-table-column>
<el-table-column label="字典类型" align="center" prop="resultDictType"> <el-table-column label="字典类型" align="center" prop="resultDictType">
<template slot-scope="scope"> <template slot-scope="scope">
{{ {{
scope.row.resultDictType == ResultType1.dictCode scope.row.resultDictType == ResultType1.dictCode
? ResultType1.dictLabel ? ResultType1.dictLabel
: "" : ""
}}{{ }}{{
scope.row.resultDictType == ResultType2.dictCode scope.row.resultDictType == ResultType2.dictCode
? ResultType2.dictLabel ? ResultType2.dictLabel
: "" : ""
}}</template }}
> </template>
</el-table-column>
<el-table-column
property="itemCode"
label="测试项目编号"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="itemContent"
label="项目内容"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="mesureUnit"
label="项目度量单位"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="largeStandardScore"
label="大班标准最高得分"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="middleStandardScore"
label="中班标准最高得分"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="smallStandardScore"
label="小班标准最高得分"
width="150"
align="center"
>
</el-table-column> </el-table-column>
<el-table-column property="itemCode" label="测试项目编号" width="150" align="center"></el-table-column>
<el-table-column property="itemContent" label="项目内容" width="150" align="center"></el-table-column>
<el-table-column property="mesureUnit" label="项目度量单位" width="150" align="center"></el-table-column>
<el-table-column property="largeStandardScore" label="大班标准最高得分" width="150" align="center"></el-table-column>
<el-table-column property="middleStandardScore" label="中班标准最高得分" width="150" align="center"></el-table-column>
<el-table-column property="smallStandardScore" label="小班标准最高得分" width="150" align="center"></el-table-column>
<el-table-column <el-table-column
property="unifiedStandardScore" property="unifiedStandardScore"
label="统一标准最高得分" label="统一标准最高得分"
width="150" width="150"
align="center" align="center"
> ></el-table-column>
</el-table-column> <el-table-column property="sorting" label="排序" width="150" align="center"></el-table-column>
<el-table-column <el-table-column property="remark" label="项目概述" width="150" align="center"></el-table-column>
property="sorting" <el-table-column property="createBy" label="创建人" width="150" align="center"></el-table-column>
label="排序" <el-table-column property="createTime" label="创建时间" width="150" align="center"></el-table-column>
width="150" <el-table-column property="updateBy" label="修改人" width="150" align="center"></el-table-column>
align="center" <el-table-column property="updateTime" label="修改时间" width="150" align="center"></el-table-column>
>
</el-table-column>
<el-table-column
property="remark"
label="项目概述"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="createBy"
label="创建人"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="createTime"
label="创建时间"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="updateBy"
label="修改人"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="updateTime"
label="修改时间"
width="150"
align="center"
>
</el-table-column>
</el-table> </el-table>
<pagination <pagination
v-show="total2 > 0" v-show="total2 > 0"
@ -534,7 +363,7 @@ import {
addTestItemCountryScore, addTestItemCountryScore,
updateTestItemCountryScore, updateTestItemCountryScore,
testItemslist, testItemslist,
getItemCountryScoreInfo, getItemCountryScoreInfo
} from "@/api/system/testItemCountryScore"; } from "@/api/system/testItemCountryScore";
import { tKindergartenInfo } from "@/api/system/kindergartenInfo"; import { tKindergartenInfo } from "@/api/system/kindergartenInfo";
@ -548,7 +377,6 @@ export default {
if (str.includes(".")) { if (str.includes(".")) {
str_ = str.substr(str.indexOf(".")).length; str_ = str.substr(str.indexOf(".")).length;
str2 = str.substr(0, str.indexOf(".")).length; str2 = str.substr(0, str.indexOf(".")).length;
console.log(str2);
if (Number.isNaN(Number.parseFloat(str))) { if (Number.isNaN(Number.parseFloat(str))) {
callback(new Error("请输入数字")); callback(new Error("请输入数字"));
} else if (!this.form2.itemAvgScore) { } else if (!this.form2.itemAvgScore) {
@ -566,7 +394,6 @@ export default {
} }
} else { } else {
str2 = str.length; str2 = str.length;
console.log(str2);
if (Number.isNaN(Number.parseFloat(str))) { if (Number.isNaN(Number.parseFloat(str))) {
callback(new Error("请输入数字")); callback(new Error("请输入数字"));
} else if (!this.form2.itemAvgScore) { } else if (!this.form2.itemAvgScore) {
@ -584,13 +411,11 @@ export default {
}; };
var roleMoeny2 = (rule, value, callback) => { var roleMoeny2 = (rule, value, callback) => {
var str = String(this.form.itemAvgScore); var str = String(this.form.itemAvgScore);
console.log(str);
var str_ = ""; var str_ = "";
var str2 = ""; var str2 = "";
if (str.includes(".")) { if (str.includes(".")) {
str_ = str.substr(str.indexOf(".")).length; str_ = str.substr(str.indexOf(".")).length;
str2 = str.substr(0, str.indexOf(".")).length; str2 = str.substr(0, str.indexOf(".")).length;
console.log(str2);
if (Number.isNaN(Number.parseFloat(str))) { if (Number.isNaN(Number.parseFloat(str))) {
callback(new Error("请输入数字")); callback(new Error("请输入数字"));
} else if (!this.form.itemAvgScore) { } else if (!this.form.itemAvgScore) {
@ -608,7 +433,6 @@ export default {
} }
} else { } else {
str2 = str.length; str2 = str.length;
console.log(str2);
if (Number.isNaN(Number.parseFloat(str))) { if (Number.isNaN(Number.parseFloat(str))) {
callback(new Error("请输入数字")); callback(new Error("请输入数字"));
} else if (!this.form.itemAvgScore) { } else if (!this.form.itemAvgScore) {
@ -631,12 +455,12 @@ export default {
sexs: [ sexs: [
{ {
label: "男", label: "男",
value: "MALE", value: "MALE"
}, },
{ {
label: "女", label: "女",
value: "FEMALE", value: "FEMALE"
}, }
], ],
// //
itemResultType: "item_result_type", itemResultType: "item_result_type",
@ -679,18 +503,18 @@ export default {
pageNum: 1, pageNum: 1,
pageSize: 10, pageSize: 10,
itemName: null, itemName: null,
sex: null, sex: null
}, },
queryParams2: { queryParams2: {
pageNum: 1, pageNum: 1,
pageSize: 10, pageSize: 10,
itemCategoryId: "", itemCategoryId: "",
itemName: "", itemName: "",
itemCode: "", itemCode: ""
}, },
queryParams3: { queryParams3: {
itemId: null, itemId: null,
sex: null, sex: null
}, },
// //
form: {}, form: {},
@ -699,7 +523,7 @@ export default {
// //
rulesxg: { rulesxg: {
itemId: [ itemId: [
{ required: true, message: "请选择所属项目", trigger: "blur" }, { required: true, message: "请选择所属项目", trigger: "blur" }
], ],
sex: [{ required: true, message: "请选择性别", trigger: "blur" }], sex: [{ required: true, message: "请选择性别", trigger: "blur" }],
itemAvgScore: [ itemAvgScore: [
@ -707,38 +531,38 @@ export default {
required: true, required: true,
validator: roleMoeny2, validator: roleMoeny2,
message: "", message: "",
trigger: "blur", trigger: "blur"
}, }
], ],
itemAvgText: [ itemAvgText: [
{ required: true, message: "请输入平均得分", trigger: "blur" }, { required: true, message: "请输入平均得分", trigger: "blur" }
], ]
}, },
rules: { rules: {
itemId: [ itemId: [
{ required: true, message: "请选择所属项目", trigger: "blur" }, { required: true, message: "请选择所属项目", trigger: "blur" }
], ],
itemAvgScore1: [ itemAvgScore1: [
{ {
required: true, required: true,
message: "请选择所属项目之后输入平均得分", message: "请选择所属项目之后输入平均得分",
trigger: "blur", trigger: "blur"
}, }
], ],
itemAvgScore: [ itemAvgScore: [
{ {
required: true, required: true,
validator: roleMoeny, validator: roleMoeny,
message: "", message: "",
trigger: "blur", trigger: "blur"
}, }
], ],
sex: [{ required: true, message: "请选择性别", trigger: "blur" }], sex: [{ required: true, message: "请选择性别", trigger: "blur" }],
itemAvgText: [ itemAvgText: [
{ required: true, message: "请输入平均得分", trigger: "blur" }, { required: true, message: "请输入平均得分", trigger: "blur" }
], ]
}, },
realVal: "", realVal: ""
}; };
}, },
created() { created() {
@ -746,8 +570,7 @@ export default {
}, },
methods: { methods: {
getItemCountryScore() { getItemCountryScore() {
getItemCountryScoreInfo(this.queryParams3).then((res) => { getItemCountryScoreInfo(this.queryParams3).then(res => {
console.log(res);
if (res.data) { if (res.data) {
this.form2.itemAvgScore = res.data.itemAvgScore; this.form2.itemAvgScore = res.data.itemAvgScore;
this.form2.itemAvgText = res.data.itemAvgText; this.form2.itemAvgText = res.data.itemAvgText;
@ -759,13 +582,11 @@ export default {
}, },
sexclick(item) { sexclick(item) {
this.queryParams3.sex = item.value; this.queryParams3.sex = item.value;
console.log(this.queryParams3);
if (this.queryParams3.itemId != null) { if (this.queryParams3.itemId != null) {
this.getItemCountryScore(); this.getItemCountryScore();
} }
}, },
xmclick(row) { xmclick(row) {
console.log(row);
this.xmname = row.itemName; this.xmname = row.itemName;
this.queryParams3.itemId = row.id; this.queryParams3.itemId = row.id;
this.itemId2 = row.id; this.itemId2 = row.id;
@ -785,8 +606,6 @@ export default {
this.form.itemAvgScore = ""; this.form.itemAvgScore = "";
this.form2.itemAvgScore = ""; this.form2.itemAvgScore = "";
} }
console.log(this.form);
console.log(this.form2);
if (this.queryParams3.sex != null) { if (this.queryParams3.sex != null) {
this.getItemCountryScore(); this.getItemCountryScore();
} }
@ -795,22 +614,19 @@ export default {
/** 查询全国平均成绩列表 */ /** 查询全国平均成绩列表 */
getList() { getList() {
this.loading = true; this.loading = true;
testItemslist(this.queryParams2).then((res) => { testItemslist(this.queryParams2).then(res => {
this.testItemslists = res.rows; this.testItemslists = res.rows;
console.log(this.testItemslists);
this.total2 = res.total; this.total2 = res.total;
}); });
listTestItemCountryScore(this.queryParams).then((response) => { listTestItemCountryScore(this.queryParams).then(response => {
this.testItemCountryScoreList = response.rows; this.testItemCountryScoreList = response.rows;
this.total = response.total; this.total = response.total;
this.loading = false; this.loading = false;
}); });
tKindergartenInfo(this.itemResultType).then((res) => { tKindergartenInfo(this.itemResultType).then(res => {
// console.log(res);
this.itemResultTypelist = res.data; this.itemResultTypelist = res.data;
this.ResultType1 = this.itemResultTypelist[0]; this.ResultType1 = this.itemResultTypelist[0];
this.ResultType2 = this.itemResultTypelist[1]; this.ResultType2 = this.itemResultTypelist[1];
// console.log(this.ResultType1);
}); });
}, },
// //
@ -836,21 +652,21 @@ export default {
itemAvgScore: "", itemAvgScore: "",
itemAvgText: "", itemAvgText: "",
resultDictType: "", //number text resultDictType: "", //number text
sex: "", sex: ""
}; };
this.form2 = { this.form2 = {
itemId: "", itemId: "",
itemAvgScore: null, itemAvgScore: null,
itemAvgText: "", itemAvgText: "",
resultDictType: "", //number text resultDictType: "", //number text
sex: "", sex: ""
}; };
this.resetForm("form"); this.resetForm("form");
}, },
/** 搜索按钮操作 */ /** 搜索按钮操作 */
handleQuery2() { handleQuery2() {
this.queryParams2.pageNum = 1; this.queryParams2.pageNum = 1;
testItemslist(this.queryParams).then((response) => { testItemslist(this.queryParams).then(response => {
this.testItemslist = response.rows; this.testItemslist = response.rows;
this.total = response.total; this.total = response.total;
this.loading = false; this.loading = false;
@ -871,7 +687,7 @@ export default {
// //
handleSelectionChange(selection) { handleSelectionChange(selection) {
this.ids = selection.map((item) => item.id); this.ids = selection.map(item => item.id);
this.single = selection.length !== 1; this.single = selection.length !== 1;
this.multiple = !selection.length; this.multiple = !selection.length;
}, },
@ -879,7 +695,7 @@ export default {
handleAdd() { handleAdd() {
this.queryParams3 = { this.queryParams3 = {
itemId: null, itemId: null,
sex: null, sex: null
}; };
this.reset(); this.reset();
this.open = true; this.open = true;
@ -890,35 +706,25 @@ export default {
this.itemId2 = row.itemId; this.itemId2 = row.itemId;
this.reset(); this.reset();
const id = row.id || this.ids; const id = row.id || this.ids;
getTestItemCountryScore(id).then((response) => { getTestItemCountryScore(id).then(response => {
this.form = response.data; this.form = response.data;
console.log(this.form);
this.xmname = response.data.itemName; this.xmname = response.data.itemName;
this.open2 = true; this.open2 = true;
this.title = "修改全国平均成绩"; this.title = "修改全国平均成绩";
console.log(this.form);
}); });
}, },
/** 提交按钮 */ /** 提交按钮 */
submitForm() { submitForm() {
if (this.form.dictValue == this.ResultType1.dictValue) { if (this.form.dictValue == this.ResultType1.dictValue) {
console.log(this.ResultType1.dictValue);
this.form.itemAvgText = ""; this.form.itemAvgText = "";
} }
if (this.form.dictValue == this.ResultType2.dictValue) { if (this.form.dictValue == this.ResultType2.dictValue) {
console.log(this.ResultType2.dictValue);
this.form.itemAvgScore = ""; this.form.itemAvgScore = "";
} }
// console.log(this.form2);
// console.log(this.form);
// console.log(this.form2.itemAvgScore);
if (this.form.id != null) { if (this.form.id != null) {
this.$refs["form"].validate((valid) => { this.$refs["form"].validate(valid => {
if (valid) { if (valid) {
updateTestItemCountryScore(this.form).then((response) => { updateTestItemCountryScore(this.form).then(response => {
this.$modal.msgSuccess("修改成功"); this.$modal.msgSuccess("修改成功");
this.open2 = false; this.open2 = false;
@ -930,16 +736,13 @@ export default {
} }
}); });
} else { } else {
this.$refs["form2"].validate((valid) => { this.$refs["form2"].validate(valid => {
if (valid) { if (valid) {
this.form2.itemAvgScore = Number(this.form2.itemAvgScore); this.form2.itemAvgScore = Number(this.form2.itemAvgScore);
addTestItemCountryScore(this.form2).then((response) => { addTestItemCountryScore(this.form2).then(response => {
this.$modal.msgSuccess("新增成功"); this.$modal.msgSuccess("新增成功");
this.open = false; this.open = false;
// console.log(this.form2)
this.getList(); this.getList();
// this.form.itemId = "";
this.itemId2 = ""; this.itemId2 = "";
this.xmname = ""; this.xmname = "";
this.xmname = "请选择所属项目"; this.xmname = "请选择所属项目";
@ -957,7 +760,7 @@ export default {
const ids = row.id || this.ids; const ids = row.id || this.ids;
this.$modal this.$modal
.confirm("是否确认删除全国平均成绩的数据项?") .confirm("是否确认删除全国平均成绩的数据项?")
.then(function () { .then(function() {
return delTestItemCountryScore(ids); return delTestItemCountryScore(ids);
}) })
.then(() => { .then(() => {
@ -971,11 +774,11 @@ export default {
this.download( this.download(
"system/testItemCountryScore/export", "system/testItemCountryScore/export",
{ {
...this.queryParams, ...this.queryParams
}, },
`testItemCountryScore_${new Date().getTime()}.xlsx` `testItemCountryScore_${new Date().getTime()}.xlsx`
); );
}, }
}, }
}; };
</script> </script>

File diff suppressed because it is too large Load Diff

View File

@ -519,7 +519,6 @@ export default {
str_ = str.substr(str.indexOf(".")).length; str_ = str.substr(str.indexOf(".")).length;
if (str.includes(".")) { if (str.includes(".")) {
str2 = str.substr(str.indexOf(".")).length; str2 = str.substr(str.indexOf(".")).length;
console.log(str2);
if (Number.isNaN(Number.parseFloat(value))) { if (Number.isNaN(Number.parseFloat(value))) {
callback(new Error("请输入数字")); callback(new Error("请输入数字"));
} else if (this.form.middleStandardScore * 1 > 99999999) { } else if (this.form.middleStandardScore * 1 > 99999999) {
@ -533,7 +532,6 @@ export default {
} }
} else { } else {
str2 = str.length; str2 = str.length;
console.log(str2);
if (Number.isNaN(Number.parseFloat(value))) { if (Number.isNaN(Number.parseFloat(value))) {
callback(new Error("请输入数字")); callback(new Error("请输入数字"));
} else if (this.form.middleStandardScore * 1 > 99999999) { } else if (this.form.middleStandardScore * 1 > 99999999) {
@ -554,7 +552,6 @@ export default {
str_ = str.substr(str.indexOf(".")).length; str_ = str.substr(str.indexOf(".")).length;
if (str.includes(".")) { if (str.includes(".")) {
str2 = str.substr(0, str.indexOf(".")).length; str2 = str.substr(0, str.indexOf(".")).length;
console.log(str2);
if (Number.isNaN(Number.parseFloat(value))) { if (Number.isNaN(Number.parseFloat(value))) {
callback(new Error("请输入数字")); callback(new Error("请输入数字"));
} else if (this.form.middleStandardScore * 1 > 99999999) { } else if (this.form.middleStandardScore * 1 > 99999999) {
@ -568,7 +565,6 @@ export default {
} }
} else { } else {
str2 = str.length; str2 = str.length;
console.log(str2);
if (Number.isNaN(Number.parseFloat(value))) { if (Number.isNaN(Number.parseFloat(value))) {
callback(new Error("请输入数字")); callback(new Error("请输入数字"));
} else if (this.form.unifiedStandardScore * 1 > 99999999) { } else if (this.form.unifiedStandardScore * 1 > 99999999) {
@ -589,7 +585,6 @@ export default {
str_ = str.substr(str.indexOf(".")).length; str_ = str.substr(str.indexOf(".")).length;
if (str.includes(".")) { if (str.includes(".")) {
str2 = str.substr(0, str.indexOf(".")).length; str2 = str.substr(0, str.indexOf(".")).length;
console.log(str2);
if (Number.isNaN(Number.parseFloat(value))) { if (Number.isNaN(Number.parseFloat(value))) {
callback(new Error("请输入数字")); callback(new Error("请输入数字"));
} else if (this.form.middleStandardScore * 1 > 99999999) { } else if (this.form.middleStandardScore * 1 > 99999999) {
@ -603,7 +598,6 @@ export default {
} }
} else { } else {
str2 = str.length; str2 = str.length;
console.log(str2);
if (Number.isNaN(Number.parseFloat(value))) { if (Number.isNaN(Number.parseFloat(value))) {
callback(new Error("请输入数字")); callback(new Error("请输入数字"));
} else if (this.form.middleStandardScore * 1 > 99999999) { } else if (this.form.middleStandardScore * 1 > 99999999) {
@ -624,7 +618,6 @@ export default {
str_ = str.substr(str.indexOf(".")).length; str_ = str.substr(str.indexOf(".")).length;
if (str.includes(".")) { if (str.includes(".")) {
str2 = str.substr(0, str.indexOf(".")).length; str2 = str.substr(0, str.indexOf(".")).length;
console.log(str2);
if (Number.isNaN(Number.parseFloat(value))) { if (Number.isNaN(Number.parseFloat(value))) {
callback(new Error("请输入数字")); callback(new Error("请输入数字"));
} else if (this.form.smallStandardScore * 1 > 99999999) { } else if (this.form.smallStandardScore * 1 > 99999999) {
@ -638,7 +631,6 @@ export default {
} }
} else { } else {
str2 = str.length; str2 = str.length;
console.log(str2);
if (Number.isNaN(Number.parseFloat(value))) { if (Number.isNaN(Number.parseFloat(value))) {
callback(new Error("请输入数字")); callback(new Error("请输入数字"));
} else if (this.form.smallStandardScore * 1 > 99999999) { } else if (this.form.smallStandardScore * 1 > 99999999) {
@ -659,7 +651,6 @@ export default {
str_ = str.substr(str.indexOf(".")).length; str_ = str.substr(str.indexOf(".")).length;
if (str.includes(".")) { if (str.includes(".")) {
str2 = str.substr(0, str.indexOf(".")).length; str2 = str.substr(0, str.indexOf(".")).length;
console.log(str2);
if (Number.isNaN(Number.parseFloat(value))) { if (Number.isNaN(Number.parseFloat(value))) {
callback(new Error("请输入数字")); callback(new Error("请输入数字"));
} else if (this.form.minScore * 1 > 99999999) { } else if (this.form.minScore * 1 > 99999999) {
@ -673,7 +664,6 @@ export default {
} }
} else { } else {
str2 = str.length; str2 = str.length;
console.log(str2);
if (Number.isNaN(Number.parseFloat(value))) { if (Number.isNaN(Number.parseFloat(value))) {
callback(new Error("请输入数字")); callback(new Error("请输入数字"));
} else if (this.form.minScore * 1 > 99999999) { } else if (this.form.minScore * 1 > 99999999) {
@ -694,7 +684,6 @@ export default {
str_ = str.substr(str.indexOf(".")).length; str_ = str.substr(str.indexOf(".")).length;
if (str.includes(".")) { if (str.includes(".")) {
str2 = str.substr(0, str.indexOf(".")).length; str2 = str.substr(0, str.indexOf(".")).length;
console.log(str2);
if (Number.isNaN(Number.parseFloat(value))) { if (Number.isNaN(Number.parseFloat(value))) {
callback(new Error("请输入数字")); callback(new Error("请输入数字"));
} else if (this.form.maxScore * 1 > 99999999) { } else if (this.form.maxScore * 1 > 99999999) {
@ -708,7 +697,6 @@ export default {
} }
} else { } else {
str2 = str.length; str2 = str.length;
console.log(str2);
if (Number.isNaN(Number.parseFloat(value))) { if (Number.isNaN(Number.parseFloat(value))) {
callback(new Error("请输入数字")); callback(new Error("请输入数字"));
} else if (this.form.maxScore * 1 > 99999999) { } else if (this.form.maxScore * 1 > 99999999) {
@ -724,7 +712,6 @@ export default {
}; };
let itemLevelList = (rule, value, callback) => { let itemLevelList = (rule, value, callback) => {
for (let i = 0; i < value.length; i++) { for (let i = 0; i < value.length; i++) {
console.log(value[i].levelMinScore > value[i].levelMaxScore);
if (value[i].levelMinScore > value[i].levelMaxScore) { if (value[i].levelMinScore > value[i].levelMaxScore) {
callback(new Error("最高分必须大于最低分,请重新填写!")); callback(new Error("最高分必须大于最低分,请重新填写!"));
} else if (value[i].levelName == "") { } else if (value[i].levelName == "") {
@ -738,8 +725,6 @@ export default {
} }
} }
// value.for((e) => { // value.for((e) => {
// console.log(e.levelMinScore, e.levelMaxScore);
// console.log(e.levelMinScore > e.levelMaxScore);
// if (e.levelMinScore > e.levelMaxScore) { // if (e.levelMinScore > e.levelMaxScore) {
// callback(new Error(",")); // callback(new Error(","));
// } else if (e.levelName == "") { // } else if (e.levelName == "") {
@ -1057,10 +1042,8 @@ export default {
delInput(index) { delInput(index) {
this.form.itemLevelList.splice(index, 1); this.form.itemLevelList.splice(index, 1);
console.log(this.form.itemLevelList);
}, },
addInput() { addInput() {
console.log(this.form);
if (this.form.itemLevelList.length >= 5) { if (this.form.itemLevelList.length >= 5) {
this.$message.error("最多5个级别"); this.$message.error("最多5个级别");
} else { } else {
@ -1077,17 +1060,13 @@ export default {
this.loading = true; this.loading = true;
listItemCategory(this.queryParams).then((response) => { listItemCategory(this.queryParams).then((response) => {
this.itemCategoryList = this.handleTree(response.data); this.itemCategoryList = this.handleTree(response.data);
// console.log(this.itemCategoryList);
}); });
tKindergartenInfo(this.itemResultType).then((res) => { tKindergartenInfo(this.itemResultType).then((res) => {
// console.log(res);
this.itemResultTypelist = res.data; this.itemResultTypelist = res.data;
this.ResultType1 = this.itemResultTypelist[0]; this.ResultType1 = this.itemResultTypelist[0];
this.ResultType2 = this.itemResultTypelist[1]; this.ResultType2 = this.itemResultTypelist[1];
// console.log(this.ResultType1);
}); });
tKindergartenInfo(this.measureUnitType).then((res) => { tKindergartenInfo(this.measureUnitType).then((res) => {
// console.log(res);
this.measureUnitTypelist = res.data; this.measureUnitTypelist = res.data;
}); });
tKindergartenInfo(this.standardType).then((res) => { tKindergartenInfo(this.standardType).then((res) => {
@ -1163,7 +1142,6 @@ export default {
getTestCategoryItemInfo(row.id).then((res) => { getTestCategoryItemInfo(row.id).then((res) => {
this.categorynamelist = res.data; this.categorynamelist = res.data;
this.itemtypeopen = true; this.itemtypeopen = true;
console.log(this.categorynamelist);
}); });
}, },
/** 修改按钮操作 */ /** 修改按钮操作 */
@ -1180,16 +1158,13 @@ export default {
// response.data.unifiedStandardScore // response.data.unifiedStandardScore
// ); // );
this.form = response.data; this.form = response.data;
// console.log(typeof this.form.unifiedStandardScore);
this.open = true; this.open = true;
this.title = "修改测试项目"; this.title = "修改测试项目";
}); });
}, },
/** 提交按钮 */ /** 提交按钮 */
submitForm() { submitForm() {
console.log(this.form);
// this.form.unifiedStandardScore = Number(this.form.unifiedStandardScore); // this.form.unifiedStandardScore = Number(this.form.unifiedStandardScore);
// console.log(typeof this.form.unifiedStandardScore);
this.$refs["form"].validate((valid) => { this.$refs["form"].validate((valid) => {
if (valid) { if (valid) {
if (this.form.id != null) { if (this.form.id != null) {

View File

@ -25,16 +25,8 @@
/> />
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
type="primary" <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
icon="el-icon-search"
size="mini"
@click="handleQuery"
>搜索</el-button
>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
>重置</el-button
>
</el-form-item> </el-form-item>
</el-form> </el-form>
@ -47,8 +39,7 @@
size="mini" size="mini"
@click="handleAdd" @click="handleAdd"
v-hasPermi="['system:testScoreBatch:add']" v-hasPermi="['system:testScoreBatch:add']"
>新增</el-button >新增</el-button>
>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -59,8 +50,7 @@
:disabled="single" :disabled="single"
@click="handleUpdate" @click="handleUpdate"
v-hasPermi="['system:testScoreBatch:edit']" v-hasPermi="['system:testScoreBatch:edit']"
>修改</el-button >修改</el-button>
>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -71,8 +61,7 @@
:disabled="multiple" :disabled="multiple"
@click="handleDelete" @click="handleDelete"
v-hasPermi="['system:testScoreBatch:remove']" v-hasPermi="['system:testScoreBatch:remove']"
>删除</el-button >删除</el-button>
>
</el-col> </el-col>
<!-- <el-col :span="1.5"> <!-- <el-col :span="1.5">
<el-button <el-button
@ -83,11 +72,8 @@
@click="handleExport" @click="handleExport"
v-hasPermi="['system:testScoreBatch:export']" v-hasPermi="['system:testScoreBatch:export']"
>导出</el-button> >导出</el-button>
</el-col> --> </el-col>-->
<right-toolbar <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
:showSearch.sync="showSearch"
@queryTable="getList"
></right-toolbar>
</el-row> </el-row>
<el-table <el-table
@ -99,21 +85,12 @@
<!-- <el-table-column label="主键id" align="center" prop="id" /> --> <!-- <el-table-column label="主键id" align="center" prop="id" /> -->
<el-table-column label="批次编号" align="center" prop="batchCode" /> <el-table-column label="批次编号" align="center" prop="batchCode" />
<el-table-column label="批次名称" align="center" prop="batchName" /> <el-table-column label="批次名称" align="center" prop="batchName" />
<el-table-column <el-table-column label="备注信息" align="center" prop="remark" :show-overflow-tooltip="true" />
label="备注信息"
align="center"
prop="remark"
:show-overflow-tooltip="true"
/>
<el-table-column label="创建人" align="center" prop="createBy" /> <el-table-column label="创建人" align="center" prop="createBy" />
<el-table-column label="创建时间" align="center" prop="createTime" /> <el-table-column label="创建时间" align="center" prop="createTime" />
<!-- <el-table-column label="修改人" align="center" prop="updateBy" /> <!-- <el-table-column label="修改人" align="center" prop="updateBy" />
<el-table-column label="修改时间" align="center" prop="updateTime" /> --> <el-table-column label="修改时间" align="center" prop="updateTime" />-->
<el-table-column <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
label="操作"
align="center"
class-name="small-padding fixed-width"
>
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
size="mini" size="mini"
@ -121,24 +98,21 @@
icon="el-icon-search" icon="el-icon-search"
@click="seeitem(scope.row)" @click="seeitem(scope.row)"
v-hasPermi="['system:studentInfo:edit']" v-hasPermi="['system:studentInfo:edit']"
>查看</el-button >查看</el-button>
>
<el-button <el-button
size="mini" size="mini"
type="text" type="text"
icon="el-icon-edit" icon="el-icon-edit"
@click="handleUpdate(scope.row)" @click="handleUpdate(scope.row)"
v-hasPermi="['system:testScoreBatch:edit']" v-hasPermi="['system:testScoreBatch:edit']"
>修改</el-button >修改</el-button>
>
<el-button <el-button
size="mini" size="mini"
type="text" type="text"
icon="el-icon-delete" icon="el-icon-delete"
@click="handleDelete(scope.row)" @click="handleDelete(scope.row)"
v-hasPermi="['system:testScoreBatch:remove']" v-hasPermi="['system:testScoreBatch:remove']"
>删除</el-button >删除</el-button>
>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -153,13 +127,7 @@
<!-- 添加或修改测试批次对话框 --> <!-- 添加或修改测试批次对话框 -->
<el-dialog :title="title" :visible.sync="open" width="900px" append-to-body> <el-dialog :title="title" :visible.sync="open" width="900px" append-to-body>
<el-form <el-form ref="form" :model="form" :rules="rules" label-width="80px" :inline="true">
ref="form"
:model="form"
:rules="rules"
label-width="80px"
:inline="true"
>
<el-form-item label="批次名称" prop="batchName"> <el-form-item label="批次名称" prop="batchName">
<el-input <el-input
style="width: 250px" style="width: 250px"
@ -178,13 +146,7 @@
</el-form-item> </el-form-item>
<el-form-item label="测试项目" prop="itemBatchInfoIdList"> <el-form-item label="测试项目" prop="itemBatchInfoIdList">
<el-button <el-button size="small" @click="innerVisible3 = true" type="primary" plain>添加测试项目</el-button>
size="small"
@click="innerVisible3 = true"
type="primary"
plain
>添加测试项目</el-button
>
</el-form-item> </el-form-item>
</el-form> </el-form>
@ -194,58 +156,31 @@
</div> </div>
<div> <div>
<el-table <el-table ref="singleTable" :data="items" style="width: 95%; margin: 20px auto">
ref="singleTable" <el-table-column type="index" width="80" align="center"></el-table-column>
:data="items" <el-table-column property="itemCode" label="项目编号" width="230" align="center"></el-table-column>
style="width: 95%; margin: 20px auto" <el-table-column property="itemName" label="项目名称" width="230" align="center"></el-table-column>
> <el-table-column property="itemType" label="字典类型" align="center" width="180">
<el-table-column type="index" width="80" align="center">
</el-table-column>
<el-table-column
property="itemCode"
label="项目编号"
width="230"
align="center"
>
</el-table-column>
<el-table-column
property="itemName"
label="项目名称"
width="230"
align="center"
>
</el-table-column>
<el-table-column
property="itemType"
label="字典类型"
align="center"
width="180"
>
<template slot-scope="scope"> <template slot-scope="scope">
{{ {{
scope.row.itemType == ResultType1.dictCode scope.row.itemType == ResultType1.dictCode
? ResultType1.dictLabel ? ResultType1.dictLabel
: "" : ""
}}{{ }}{{
scope.row.itemType == ResultType2.dictCode scope.row.itemType == ResultType2.dictCode
? ResultType2.dictLabel ? ResultType2.dictLabel
: "" : ""
}}</template }}
> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
label="操作"
align="center"
class-name="small-padding fixed-width"
>
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
size="mini" size="mini"
type="text" type="text"
icon="el-icon-delete" icon="el-icon-delete"
@click="delitem(scope.row)" @click="delitem(scope.row)"
>删除</el-button >删除</el-button>
>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -255,17 +190,12 @@
:page.sync="temqueryParams.pageNum" :page.sync="temqueryParams.pageNum"
:limit.sync="temqueryParams.pageSize" :limit.sync="temqueryParams.pageSize"
@pagination="lookitem" @pagination="lookitem"
/> --> />-->
</div> </div>
</el-dialog> </el-dialog>
<!-- 测试项目弹窗 --> <!-- 测试项目弹窗 -->
<el-dialog <el-dialog width="1000px" title="选择测试项目名称" :visible.sync="innerVisible3" append-to-body>
width="1000px"
title="选择测试项目名称"
:visible.sync="innerVisible3"
append-to-body
>
<el-form <el-form
:model="queryParams4" :model="queryParams4"
ref="queryForm" ref="queryForm"
@ -283,16 +213,8 @@
/> />
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery4">搜索</el-button>
type="primary" <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
icon="el-icon-search"
size="mini"
@click="handleQuery4"
>搜索</el-button
>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
>重置</el-button
>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-table :data="testItemss" @cell-dblclick="addtestitem"> <el-table :data="testItemss" @cell-dblclick="addtestitem">
@ -311,117 +233,38 @@
></el-button> ></el-button>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column property="itemCode" label="项目编号" width="150" align="center"></el-table-column>
property="itemCode" <el-table-column property="itemName" label="项目名称" width="150" align="center"></el-table-column>
label="项目编号"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="itemName"
label="项目名称"
width="150"
align="center"
>
</el-table-column>
<el-table-column label="字典类型" align="center" prop="resultDictType"> <el-table-column label="字典类型" align="center" prop="resultDictType">
<template slot-scope="scope"> <template slot-scope="scope">
{{ {{
scope.row.resultDictType == ResultType1.dictCode scope.row.resultDictType == ResultType1.dictCode
? ResultType1.dictLabel ? ResultType1.dictLabel
: "" : ""
}}{{ }}{{
scope.row.resultDictType == ResultType2.dictCode scope.row.resultDictType == ResultType2.dictCode
? ResultType2.dictLabel ? ResultType2.dictLabel
: "" : ""
}}</template }}
> </template>
</el-table-column>
<el-table-column
property="itemContent"
label="项目内容"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="measureUnit"
label="项目度量单位"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="largeStandardScore"
label="大班标准最高得分"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="middleStandardScore"
label="中班标准最高得分"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="smallStandardScore"
label="小班标准最高得分"
width="150"
align="center"
>
</el-table-column> </el-table-column>
<el-table-column property="itemContent" label="项目内容" width="150" align="center"></el-table-column>
<el-table-column property="measureUnit" label="项目度量单位" width="150" align="center"></el-table-column>
<el-table-column property="largeStandardScore" label="大班标准最高得分" width="150" align="center"></el-table-column>
<el-table-column property="middleStandardScore" label="中班标准最高得分" width="150" align="center"></el-table-column>
<el-table-column property="smallStandardScore" label="小班标准最高得分" width="150" align="center"></el-table-column>
<el-table-column <el-table-column
property="unifiedStandardScore" property="unifiedStandardScore"
label="统一标准最高得分" label="统一标准最高得分"
width="150" width="150"
align="center" align="center"
> ></el-table-column>
</el-table-column> <el-table-column property="sorting" label="排序" width="150" align="center"></el-table-column>
<el-table-column <el-table-column property="remark" label="项目概述" width="150" align="center"></el-table-column>
property="sorting" <el-table-column property="creatBy" label="创建人" width="150" align="center"></el-table-column>
label="排序" <el-table-column property="createTime" label="创建时间" width="150" align="center"></el-table-column>
width="150" <el-table-column property="updateBy" label="修改人" width="150" align="center"></el-table-column>
align="center" <el-table-column property="updateTime" label="修改时间" width="150" align="center"></el-table-column>
>
</el-table-column>
<el-table-column
property="remark"
label="项目概述"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="creatBy"
label="创建人"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="createTime"
label="创建时间"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="updateBy"
label="修改人"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="updateTime"
label="修改时间"
width="150"
align="center"
>
</el-table-column>
</el-table> </el-table>
<pagination <pagination
@ -444,50 +287,26 @@
height: 40px; height: 40px;
font-size: 15px; font-size: 15px;
" "
>选择完成</el-button >选择完成</el-button>
>
</el-dialog> </el-dialog>
<el-dialog <el-dialog width="680px" title="查看测试项目" :visible.sync="innerVisible" append-to-body>
width="680px"
title="查看测试项目"
:visible.sync="innerVisible"
append-to-body
>
<el-table ref="singleTable" :data="itemlist" style="width: 100%"> <el-table ref="singleTable" :data="itemlist" style="width: 100%">
<el-table-column type="index" width="100" align="center"> <el-table-column type="index" width="100" align="center"></el-table-column>
</el-table-column> <el-table-column property="itemCode" label="项目编号" width="180" align="center"></el-table-column>
<el-table-column <el-table-column property="itemName" label="项目名称" width="180" align="center"></el-table-column>
property="itemCode" <el-table-column property="resultDictType" label="字典类型" width="180" align="center">
label="项目编号"
width="180"
align="center"
>
</el-table-column>
<el-table-column
property="itemName"
label="项目名称"
width="180"
align="center"
>
</el-table-column>
<el-table-column
property="resultDictType"
label="字典类型"
width="180"
align="center"
>
<template slot-scope="scope"> <template slot-scope="scope">
{{ {{
scope.row.resultDictType == ResultType1.dictCode scope.row.resultDictType == ResultType1.dictCode
? ResultType1.dictLabel ? ResultType1.dictLabel
: "" : ""
}}{{ }}{{
scope.row.resultDictType == ResultType2.dictCode scope.row.resultDictType == ResultType2.dictCode
? ResultType2.dictLabel ? ResultType2.dictLabel
: "" : ""
}}</template }}
> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<!-- <pagination <!-- <pagination
@ -496,7 +315,7 @@
:page.sync="temqueryParams.pageNum" :page.sync="temqueryParams.pageNum"
:limit.sync="temqueryParams.pageSize" :limit.sync="temqueryParams.pageSize"
@pagination="lookitem" @pagination="lookitem"
/> --> />-->
</el-dialog> </el-dialog>
</div> </div>
</template> </template>
@ -508,7 +327,7 @@ import {
delTestScoreBatch, delTestScoreBatch,
addTestScoreBatch, addTestScoreBatch,
updateTestScoreBatch, updateTestScoreBatch,
temBatchInfoList, temBatchInfoList
} from "@/api/system/testScoreBatch"; } from "@/api/system/testScoreBatch";
import { testItems } from "@/api/system/testItemScore"; import { testItems } from "@/api/system/testItemScore";
import { tKindergartenInfo } from "@/api/system/kindergartenInfo"; import { tKindergartenInfo } from "@/api/system/kindergartenInfo";
@ -517,7 +336,6 @@ export default {
data() { data() {
var itembatch = (rule, value, callback) => { var itembatch = (rule, value, callback) => {
var str = this.form.itemBatchInfoIdList; var str = this.form.itemBatchInfoIdList;
console.log(str);
if (str.length > 0) { if (str.length > 0) {
callback(); callback();
} else { } else {
@ -556,18 +374,18 @@ export default {
pageNum: 1, pageNum: 1,
pageSize: 10, pageSize: 10,
batchCode: null, batchCode: null,
batchName: null, batchName: null
}, },
temqueryParams: { temqueryParams: {
pageNum: 1, pageNum: 1,
pageSize: 9999, pageSize: 9999,
id: "", id: ""
}, },
// //
queryParams4: { queryParams4: {
pageNum: 1, pageNum: 1,
pageSize: 10, pageSize: 10,
itemName: null, itemName: null
}, },
// //
form: {}, form: {},
@ -582,14 +400,14 @@ export default {
required: true, required: true,
validator: itembatch, validator: itembatch,
message: "", message: "",
trigger: "blur", trigger: "blur"
}, }
], ],
batchName: [{ required: true, message: "批次名称不能为空" }], batchName: [{ required: true, message: "批次名称不能为空" }],
remark: [{ required: true, message: "备注信息不能为空" }], remark: [{ required: true, message: "备注信息不能为空" }]
}, },
items: [], items: [],
itemlist: [], itemlist: []
}; };
}, },
created() { created() {
@ -597,14 +415,12 @@ export default {
}, },
methods: { methods: {
delitem(item) { delitem(item) {
console.log(item); this.items = this.items.filter(e => {
this.items = this.items.filter((e) => {
return e.itemId != item.itemId; return e.itemId != item.itemId;
}); });
}, },
deltestitem(item) { deltestitem(item) {
console.log(item); this.items = this.items.filter(e => {
this.items = this.items.filter((e) => {
return e.itemId != item.id; return e.itemId != item.id;
}); });
}, },
@ -613,45 +429,39 @@ export default {
itemId: row.id, itemId: row.id,
itemName: row.itemName, itemName: row.itemName,
itemType: row.resultDictType, itemType: row.resultDictType,
itemCode: row.itemCode, itemCode: row.itemCode
}; };
this.items.push(item); this.items.push(item);
// this.form.itemBatchInfoIdList.push(row.id); // this.form.itemBatchInfoIdList.push(row.id);
console.log(this.items);
}, },
itemclick() { itemclick() {
this.innerVisible3 = false; this.innerVisible3 = false;
}, },
lookitem(item) { lookitem(item) {
console.log(item);
this.itemlist = []; this.itemlist = [];
this.items = []; this.items = [];
this.temqueryParams.batchId = item.id; this.temqueryParams.batchId = item.id;
temBatchInfoList(this.temqueryParams).then((res) => { temBatchInfoList(this.temqueryParams).then(res => {
console.log(res);
if (res.rows.length != 0) { if (res.rows.length != 0) {
this.itemlist = res.rows; this.itemlist = res.rows;
this.total2 = res.total; this.total2 = res.total;
this.items = res.rows; this.items = res.rows;
this.items.forEach((e) => { this.items.forEach(e => {
e.itemType = e.resultDictType; e.itemType = e.resultDictType;
e.itemId = e.id; e.itemId = e.id;
}); });
} }
console.log(this.items);
}); });
}, },
seeitem(item) { seeitem(item) {
this.lookitem(item); this.lookitem(item);
console.log(this.items);
if (this.items != []) { if (this.items != []) {
this.innerVisible = true; this.innerVisible = true;
} }
}, },
handleQuery4() { handleQuery4() {
this.queryParams4.pageNum = 1; this.queryParams4.pageNum = 1;
testItems(this.queryParams4).then((response) => { testItems(this.queryParams4).then(response => {
this.testItems = response.rows; this.testItems = response.rows;
this.total = response.total; this.total = response.total;
this.loading = false; this.loading = false;
@ -660,21 +470,18 @@ export default {
}, },
/** 查询测试成绩批次列表 */ /** 查询测试成绩批次列表 */
getList() { getList() {
tKindergartenInfo(this.itemResultType).then((res) => { tKindergartenInfo(this.itemResultType).then(res => {
// console.log(res);
this.ResultType1 = res.data[0]; this.ResultType1 = res.data[0];
this.ResultType2 = res.data[1]; this.ResultType2 = res.data[1];
console.log(this.ResultType1, this.ResultType2);
}); });
// //
testItems(this.queryParams4).then((res) => { testItems(this.queryParams4).then(res => {
// console.log(res)
this.testItemss = res.rows; this.testItemss = res.rows;
this.total4 = res.total; this.total4 = res.total;
this.loading = false; this.loading = false;
}); });
this.loading = true; this.loading = true;
listTestScoreBatch(this.queryParams).then((response) => { listTestScoreBatch(this.queryParams).then(response => {
this.testScoreBatchList = response.rows; this.testScoreBatchList = response.rows;
this.total = response.total; this.total = response.total;
this.loading = false; this.loading = false;
@ -698,7 +505,7 @@ export default {
createTime: null, createTime: null,
updateBy: null, updateBy: null,
updateTime: null, updateTime: null,
itemBatchInfoIdList: [], itemBatchInfoIdList: []
}; };
this.resetForm("form"); this.resetForm("form");
}, },
@ -713,7 +520,7 @@ export default {
pageNum: 1, pageNum: 1,
pageSize: 10, pageSize: 10,
batchCode: null, batchCode: null,
batchName: null, batchName: null
}; };
this.resetForm("queryForm"); this.resetForm("queryForm");
this.handleQuery(); this.handleQuery();
@ -722,7 +529,7 @@ export default {
}, },
// //
handleSelectionChange(selection) { handleSelectionChange(selection) {
this.ids = selection.map((item) => item.id); this.ids = selection.map(item => item.id);
this.single = selection.length !== 1; this.single = selection.length !== 1;
this.multiple = !selection.length; this.multiple = !selection.length;
}, },
@ -739,7 +546,7 @@ export default {
this.reset(); this.reset();
const id = row.id || this.ids; const id = row.id || this.ids;
this.lookitem(row); this.lookitem(row);
getTestScoreBatch(id).then((response) => { getTestScoreBatch(id).then(response => {
this.form = response.data; this.form = response.data;
this.open = true; this.open = true;
this.title = "修改测试成绩批次"; this.title = "修改测试成绩批次";
@ -748,20 +555,19 @@ export default {
/** 提交按钮 */ /** 提交按钮 */
submitForm() { submitForm() {
this.form.itemBatchInfoIdList = []; this.form.itemBatchInfoIdList = [];
this.items.forEach((e) => { this.items.forEach(e => {
this.form.itemBatchInfoIdList.push(e.itemId); this.form.itemBatchInfoIdList.push(e.itemId);
}); });
console.log(this.form); this.$refs["form"].validate(valid => {
this.$refs["form"].validate((valid) => {
if (valid) { if (valid) {
if (this.form.id != null) { if (this.form.id != null) {
updateTestScoreBatch(this.form).then((response) => { updateTestScoreBatch(this.form).then(response => {
this.$modal.msgSuccess("修改成功"); this.$modal.msgSuccess("修改成功");
this.open = false; this.open = false;
this.getList(); this.getList();
}); });
} else { } else {
addTestScoreBatch(this.form).then((response) => { addTestScoreBatch(this.form).then(response => {
this.$modal.msgSuccess("新增成功"); this.$modal.msgSuccess("新增成功");
this.open = false; this.open = false;
this.getList(); this.getList();
@ -775,7 +581,7 @@ export default {
const ids = row.id || this.ids; const ids = row.id || this.ids;
this.$modal this.$modal
.confirm("是否确认删除测试成绩批次的数据项?") .confirm("是否确认删除测试成绩批次的数据项?")
.then(function () { .then(function() {
return delTestScoreBatch(ids); return delTestScoreBatch(ids);
}) })
.then(() => { .then(() => {
@ -789,12 +595,12 @@ export default {
this.download( this.download(
"system/testScoreBatch/export", "system/testScoreBatch/export",
{ {
...this.queryParams, ...this.queryParams
}, },
`testScoreBatch_${new Date().getTime()}.xlsx` `testScoreBatch_${new Date().getTime()}.xlsx`
); );
}, }
}, }
}; };
</script> </script>
<style scoped='scss'> <style scoped='scss'>

View File

@ -689,7 +689,6 @@ export default {
// //
usermemberGrade() { usermemberGrade() {
tKindergartenInfo("user_type").then((res) => { tKindergartenInfo("user_type").then((res) => {
console.log(res);
}); });
}, },
// //
@ -721,7 +720,6 @@ export default {
// e.code = Number(e.code); // e.code = Number(e.code);
// }); // });
this.areaList = this.handleTree(response.data); this.areaList = this.handleTree(response.data);
console.log(this.areaList);
this.loading = false; this.loading = false;
}); });
}, },
@ -729,7 +727,6 @@ export default {
getTreeselect() { getTreeselect() {
treeselect().then((response) => { treeselect().then((response) => {
this.deptOptions = response.data; this.deptOptions = response.data;
// console.log(this.deptOptions);
}); });
}, },
// //
@ -838,8 +835,6 @@ export default {
this.open = true; this.open = true;
this.title = "修改用户"; this.title = "修改用户";
this.form.password = ""; this.form.password = "";
console.log(this.form)
console.log(this.areaList)
}); });
}, },
/** 重置密码按钮操作 */ /** 重置密码按钮操作 */
@ -865,7 +860,6 @@ export default {
}, },
/** 提交按钮 */ /** 提交按钮 */
submitForm: function () { submitForm: function () {
console.log(this.form);
this.$refs["form"].validate((valid) => { this.$refs["form"].validate((valid) => {
if (valid) { if (valid) {
if (this.form.userId != undefined) { if (this.form.userId != undefined) {

View File

@ -1,7 +1,16 @@
<template> <template>
<div> <div>
<div class="user-info-head" @click="editCropper()"><img v-bind:src="options.img" title="点击上传头像" class="img-circle img-lg" /></div> <div class="user-info-head" @click="editCropper()">
<el-dialog :title="title" :visible.sync="open" width="800px" append-to-body @opened="modalOpened" @close="closeDialog"> <img v-bind:src="options.img" title="点击上传头像" class="img-circle img-lg" />
</div>
<el-dialog
:title="title"
:visible.sync="open"
width="800px"
append-to-body
@opened="modalOpened"
@close="closeDialog"
>
<el-row> <el-row>
<el-col :xs="24" :md="12" :style="{height: '350px'}"> <el-col :xs="24" :md="12" :style="{height: '350px'}">
<vue-cropper <vue-cropper
@ -25,7 +34,12 @@
<br /> <br />
<el-row> <el-row>
<el-col :lg="2" :md="2"> <el-col :lg="2" :md="2">
<el-upload action="#" :http-request="requestUpload" :show-file-list="false" :before-upload="beforeUpload"> <el-upload
action="#"
:http-request="requestUpload"
:show-file-list="false"
:before-upload="beforeUpload"
>
<el-button size="small"> <el-button size="small">
选择 选择
<i class="el-icon-upload el-icon--right"></i> <i class="el-icon-upload el-icon--right"></i>
@ -92,8 +106,7 @@ export default {
this.visible = true; this.visible = true;
}, },
// //
requestUpload() { requestUpload() {},
},
// //
rotateLeft() { rotateLeft() {
this.$refs.cropper.rotateLeft(); this.$refs.cropper.rotateLeft();
@ -110,7 +123,9 @@ export default {
// //
beforeUpload(file) { beforeUpload(file) {
if (file.type.indexOf("image/") == -1) { if (file.type.indexOf("image/") == -1) {
this.$modal.msgError("文件格式错误,请上传图片类型,如JPGPNG后缀的文件。"); this.$modal.msgError(
"文件格式错误,请上传图片类型,如JPGPNG后缀的文件。"
);
} else { } else {
const reader = new FileReader(); const reader = new FileReader();
reader.readAsDataURL(file); reader.readAsDataURL(file);
@ -124,11 +139,10 @@ export default {
this.$refs.cropper.getCropBlob(data => { this.$refs.cropper.getCropBlob(data => {
let formData = new FormData(); let formData = new FormData();
formData.append("avatarfile", data); formData.append("avatarfile", data);
console.log(data)
uploadAvatar(formData).then(response => { uploadAvatar(formData).then(response => {
this.open = false; this.open = false;
this.options.img = process.env.VUE_APP_BASE_API + response.imgUrl; this.options.img = process.env.VUE_APP_BASE_API + response.imgUrl;
store.commit('SET_AVATAR', this.options.img); store.commit("SET_AVATAR", this.options.img);
this.$modal.msgSuccess("修改成功"); this.$modal.msgSuccess("修改成功");
this.visible = false; this.visible = false;
}); });
@ -140,7 +154,7 @@ export default {
}, },
// //
closeDialog() { closeDialog() {
this.options.img = store.getters.avatar this.options.img = store.getters.avatar;
this.visible = false; this.visible = false;
} }
} }
@ -154,7 +168,7 @@ export default {
} }
.user-info-head:hover:after { .user-info-head:hover:after {
content: '+'; content: "+";
position: absolute; position: absolute;
left: 0; left: 0;
right: 0; right: 0;