This commit is contained in:
曹辉 2022-08-23 10:22:07 +08:00
parent c50fdb27b6
commit 6dde8e62e3
8 changed files with 159 additions and 57 deletions

View File

@ -5,7 +5,7 @@ VUE_APP_TITLE = 幼儿园体质检测管理系统
ENV = 'development'
# 若依管理系统/开发环境
VUE_APP_BASE_API = 'http://192.168.16.62:8090'
VUE_APP_BASE_API = 'http://192.168.16.64:8080'
#'/dev-api'
# 路由懒加载

View File

@ -3,8 +3,8 @@ import request from '@/utils/request'
// 查询
export function ClassList(query) {
return request({
url: 'system/testItemAvgScore/ClassList',
url: '/system/testItemAvgScore/ClassList',
method: 'get',
params: query
})
}
}

View File

@ -10,7 +10,7 @@ export function getRoleInfo() {
// 查询身体素质
export function testBodyScoreInfo(query) {
return request({
url: 'system/testBodyScoreInfo/listBody',
url: '/system/testBodyScoreInfo/listBody',
method: 'get',
params: query
})

View File

@ -3,7 +3,7 @@ import request from '@/utils/request'
// 查询
export function StudentList(query) {
return request({
url: 'system/testAll/StudentList',
url: '/system/testAll/StudentList',
method: 'get',
params: query
})
@ -14,8 +14,8 @@ export function StudentList(query) {
// 查询
export function ClassList(query) {
return request({
url: 'system/testAll/ClassList',
url: '/system/testAll/ClassList',
method: 'get',
params: query
})
}
}

View File

@ -658,7 +658,7 @@ export default {
},
//
batchCodeshowclick() {
if (this.analysisqueryParams.studentId == "") {
if (this.queryParams.studentId == "") {
this.$message.error("请先选择学生");
} else {
this.testScore();

View File

@ -632,7 +632,7 @@ export default {
max: el.maxScore,
});
});
console.log(seriesData, yindicator);
// console.log(seriesData, yindicator);
var myChart = echarts.init(document.getElementById("chart"));

View File

@ -917,7 +917,6 @@ export default {
listClassinfo(this.classqueryParams).then((response) => {
this.classinfoList = response.rows;
this.total2 = response.total;
// console.log(this.classinfoList);
});
},

View File

@ -91,7 +91,7 @@
>删除</el-button
>
</el-col>
<el-col :span="1.5">
<!-- <el-col :span="1.5">
<el-button
type="warning"
plain
@ -101,7 +101,7 @@
v-hasPermi="['system:testItemScore:export']"
>导出</el-button
>
</el-col>
</el-col> -->
<right-toolbar
:showSearch.sync="showSearch"
@queryTable="getList"
@ -327,9 +327,9 @@
<el-form ref="form" :model="form2" :rules="rules" label-width="130px">
<el-form-item label="所属幼儿园" prop="classId">
<el-button
this.xmname="row.className;"
type=""
@click="yryinnerVisible = true"
v-if="kindergartenName == '请选择幼儿园'"
style="
width: 360px;
text-align: left;
@ -337,14 +337,12 @@
color: #c0c4cc;
padding-left: -10px;
"
>请选择所属幼儿园</el-button
>{{ kindergartenName }}</el-button
>
<!-- <el-button
this.xmname="row.className;"
<el-button
type=""
@click="innerVisible = true"
v-if="xmname == '请选择所属幼儿园'"
@click="yryinnerVisible = true"
v-else
style="
width: 360px;
@ -352,15 +350,14 @@
height: 36px;
padding-left: -10px;
"
>{{ xmname }}</el-button
> -->
>{{ kindergartenName }}</el-button
>
</el-form-item>
<el-form-item label="所属班级" prop="classId">
<el-button
this.xmname="row.className;"
type=""
@click="innerVisible = true"
@click="handleQuery2"
v-if="xmname == '请选择所属班级'"
style="
width: 360px;
@ -373,9 +370,8 @@
>
<el-button
this.xmname="row.className;"
type=""
@click="innerVisible = true"
@click="handleQuery2"
v-else
style="
width: 360px;
@ -546,6 +542,79 @@
</div>
</el-dialog>
<!-- // -->
<el-dialog
width="850px"
title="选择所属幼儿园"
:visible.sync="yryinnerVisible"
append-to-body
:before-close="kindergartencancel"
>
<el-table :data="kindergartenList">
<el-table-column label="请选择" width="70" align="center">
<template slot-scope="scope">
<el-button
type="primary"
style="width: 15px; height: 15px"
circle
@click="kindergartenNameclick(scope.row)"
v-if="kindergartenId == scope.row.id"
></el-button>
<el-button
v-else
style="width: 15px; height: 15px"
circle
@click="kindergartenNameclick(scope.row)"
></el-button>
</template>
</el-table-column>
<el-table-column
property="kindergartenName"
label="幼儿园名字"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="kindergartenAddress"
label="幼儿园地址"
width="150"
align="center"
>
</el-table-column>
<el-table-column
label="幼儿园所在组织"
align="center"
prop="organizeName"
width="150"
>
</el-table-column>
<el-table-column
property="contacts"
label="联系人"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="phone"
label="联系电话"
width="150"
align="center"
>
</el-table-column>
</el-table>
<pagination
v-show="total6 > 0"
:total="total6"
:page.sync="kqueryParams.pageNum"
:limit.sync="kqueryParams.pageSize"
@pagination="getList"
/>
</el-dialog>
<!--所属班级 弹窗 -->
<el-dialog
@ -1156,7 +1225,10 @@ import {
testItems,
testScoreBatch,
} from "@/api/system/testItemScore";
import { tKindergartenInfo } from "@/api/system/kindergartenInfo";
import {
tKindergartenInfo,
listKindergartenInfo,
} from "@/api/system/kindergartenInfo";
import Treeselect from "@riophae/vue-treeselect";
export default {
name: "TestItemScore",
@ -1219,7 +1291,7 @@ export default {
//
loading: true,
itemScore: "",
yryinnerVisible: false,
testItemScoreLists: [],
xmname: "请选择所属班级",
@ -1235,7 +1307,23 @@ export default {
testScoreBatchs: [],
innerVisible4: false,
itemNumbername: "请选择批次编号",
//
kqueryParams: {
pageNum: 1,
pageSize: 10,
organizeId: null,
kindergartenName: null,
kindergartenAddress: null,
kindergartenType: null,
phone: null,
contacts: null,
},
//list
kindergartenList: [],
//
kindergartenName: "请选择幼儿园",
//ID
kindergartenId: "",
//
ids: [],
@ -1251,6 +1339,7 @@ export default {
total3: 0,
total4: 0,
total5: 0,
total6: 0,
//
classInfos: [],
//
@ -1278,7 +1367,9 @@ export default {
queryParams2: {
pageNum: 1,
pageSize: 10,
kindergartenId: "",
className: null,
classType: null,
},
//
queryParams3: {
@ -1396,6 +1487,18 @@ export default {
},
methods: {
//
kindergartenNameclick(row) {
this.form2.kindergartenId = row.id;
this.queryParams2.kindergartenId = row.id;
this.kindergartenName = row.kindergartenName;
this.kindergartenId = row.id;
this.yryinnerVisible = false;
},
//
kindergartencancel() {
this.yryinnerVisible = false;
},
//
NumberCheck(num) {
let str = this.form2.itemScore;
@ -1435,45 +1538,42 @@ export default {
NumberCheck3(num) {
let str = this.form.itemScore;
//
if (Number.isNaN(Number.parseFloat(str))) {
if (Number.isNaN(Number.parseFloat(str))) {
} else {
//
if (str.indexOf(".") != -1) {
var str_ = str.substr(str.indexOf(".") +1);
var str_ = str.substr(str.indexOf(".") + 1);
if (str_.indexOf(".") != -1) {
str = str.substr(0, str.indexOf(".") + str_.indexOf(".") + 1);
}
}
//
str = parseFloat(str).toFixed(3)
this.realVal = str.substring(0, str.length - 1)
str = parseFloat(str).toFixed(3);
this.realVal = str.substring(0, str.length - 1);
// str = str.replace(/[^\d^\.]+/g, "");
// this.form.itemAvgScore = str;
console.log(this.realVal)
console.log(this.realVal);
}
},
NumberCheck4(num) {
let str = this.form.itemFraction;
//
if (Number.isNaN(Number.parseFloat(str))) {
if (Number.isNaN(Number.parseFloat(str))) {
} else {
//
if (str.indexOf(".") != -1) {
var str_ = str.substr(str.indexOf(".") +1);
var str_ = str.substr(str.indexOf(".") + 1);
if (str_.indexOf(".") != -1) {
str = str.substr(0, str.indexOf(".") + str_.indexOf(".") + 1);
}
}
//
str = parseFloat(str).toFixed(3)
this.realVal = str.substring(0, str.length - 1)
str = parseFloat(str).toFixed(3);
this.realVal = str.substring(0, str.length - 1);
// str = str.replace(/[^\d^\.]+/g, "");
// this.form.itemAvgScore = str;
}
},
//
@ -1561,28 +1661,24 @@ export default {
this.form2.batchCode = row.batchCode;
},
/** 查询个人成绩录入管理列表 */
getList() {
//
this.loading = true;
classInfo(this.queryParams2).then((res) => {
this.classInfos = res.rows;
this.total2 = res.total;
this.loading = false;
});
//
testItems(this.queryParams4).then((res) => {
console.log(res);
this.testItemss = res.rows;
this.total4 = res.total;
this.loading = false;
});
//list
listKindergartenInfo(this.kqueryParams).then((response) => {
this.kindergartenList = response.rows;
this.total6 = response.total;
});
//
testScoreBatch(this.queryParams5).then((res) => {
console.log(res);
this.testScoreBatchs = res.rows;
this.total5 = res.total;
this.loading = false;
@ -1590,7 +1686,6 @@ export default {
listTestItemScore(this.queryParams).then((response) => {
this.testItemScoreList = response.rows;
console.log(this.testItemScoreList);
this.total = response.total;
this.loading = false;
});
@ -1600,13 +1695,14 @@ export default {
this.itemResultTypelist = res.data;
this.ResultType1 = this.itemResultTypelist[0];
this.ResultType2 = this.itemResultTypelist[1];
console.log(this.ResultType1);
});
},
//
cancel() {
this.open = false;
this.reset();
this.kindergartenName = "请选择幼儿园";
this.kindergartenId = "";
this.xmname = "请选择所属班级";
this.stname = "请选择学生姓名";
this.testname = "请选择测试项目名称";
@ -1615,6 +1711,8 @@ export default {
this.itemId3 = "";
this.itemId4 = "";
this.itemId5 = "";
this.queryParams2.kindergartenId = "";
this.queryParams3.classId = "";
},
cancel2() {
this.open2 = false;
@ -1666,12 +1764,16 @@ export default {
//
handleQuery2() {
this.queryParams2.pageNum = 1;
classInfo(this.queryParams).then((response) => {
this.classInfo = response.rows;
this.total = response.total;
this.loading = false;
this.getList();
});
if (this.queryParams2.kindergartenId == "") {
this.$message.error("请先选择幼儿园");
} else {
classInfo(this.queryParams2).then((response) => {
this.classInfos = response.rows;
this.total = response.total;
this.loading = false;
this.innerVisible = true;
});
}
},
//
handleQuery3() {
@ -1760,6 +1862,7 @@ export default {
this.form.itemFraction = this.realVal;
this.form.itemScore = this.realVal;
this.form2.itemFraction = this.realVal;
console.log(this.form2);
this.$refs["form"].validate((valid) => {
if (valid) {
if (this.form.id != null) {