优化儿童体检表
This commit is contained in:
parent
7c5ac8e992
commit
381e15ef9c
@ -1,10 +1,21 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="app-container">
|
<div class="app-container">
|
||||||
<el-form :model="queryParams" ref="queryForm" :inline="true" label-width="68px">
|
<el-form
|
||||||
|
:model="queryParams"
|
||||||
|
ref="queryForm"
|
||||||
|
:inline="true"
|
||||||
|
label-width="68px"
|
||||||
|
clearable
|
||||||
|
size="small"
|
||||||
|
>
|
||||||
<el-form-item label="班级信息" prop="classInfo">
|
<el-form-item label="班级信息" prop="classInfo">
|
||||||
<el-select v-model="queryParams.classInfo" placeholder="请选择班级信息" clearable size="small">
|
<el-select v-model="queryParams.classInfo" placeholder="请选择班级信息">
|
||||||
<el-option label="请选择字典生成" value />
|
<el-option
|
||||||
|
v-for="dict in classInfoOptions"
|
||||||
|
:key="dict.bjbh"
|
||||||
|
:label="dict.bjmc"
|
||||||
|
:value="dict.bjbh"
|
||||||
|
></el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="检查日期" prop="checkTime">
|
<el-form-item label="检查日期" prop="checkTime">
|
||||||
@ -171,13 +182,25 @@
|
|||||||
<!-- 添加或修改儿童常规体检记录对话框 -->
|
<!-- 添加或修改儿童常规体检记录对话框 -->
|
||||||
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
|
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
|
||||||
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
||||||
<el-form-item label="班级信息">
|
<el-form-item label="班级信息" prop="classInfo">
|
||||||
<el-select v-model="form.classInfo" placeholder="请选择班级信息">
|
<el-select v-model="form.classInfo" placeholder="请选择班级信息" @change="classInfoChange">
|
||||||
<el-option label="请选择字典生成" value />
|
<el-option
|
||||||
|
v-for="dict in classInfoOptions"
|
||||||
|
:key="dict.bjbh"
|
||||||
|
:label="dict.bjmc"
|
||||||
|
:value="dict.bjbh"
|
||||||
|
></el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="学校名称" prop="schoolName">
|
<el-form-item label="幼儿id" prop="childId">
|
||||||
<el-input v-model="form.schoolName" placeholder="请输入学校名称" />
|
<el-select v-model="form.childId" placeholder="请选择班级信息" >
|
||||||
|
<el-option
|
||||||
|
v-for="dict in (childInfoOptions.filter(c=>c.classid == this.form.classInfo))"
|
||||||
|
:key="dict.id"
|
||||||
|
:label="dict.name"
|
||||||
|
:value="dict.id"
|
||||||
|
></el-option>
|
||||||
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="检查日期" prop="checkTime">
|
<el-form-item label="检查日期" prop="checkTime">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
@ -255,9 +278,6 @@
|
|||||||
></el-option>
|
></el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="创建人" prop="createuser">
|
|
||||||
<el-input v-model="form.createuser" placeholder="请输入创建人" />
|
|
||||||
</el-form-item>
|
|
||||||
</el-form>
|
</el-form>
|
||||||
<div slot="footer" class="dialog-footer">
|
<div slot="footer" class="dialog-footer">
|
||||||
<el-button type="primary" @click="submitForm">确 定</el-button>
|
<el-button type="primary" @click="submitForm">确 定</el-button>
|
||||||
@ -276,6 +296,8 @@ import {
|
|||||||
updateHealthcheck,
|
updateHealthcheck,
|
||||||
exportHealthcheck
|
exportHealthcheck
|
||||||
} from "@/api/benyi/healthcheck";
|
} from "@/api/benyi/healthcheck";
|
||||||
|
import { listClass } from "@/api/system/class";
|
||||||
|
import { listChild } from "@/api/benyi/child";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "Healthcheck",
|
name: "Healthcheck",
|
||||||
@ -297,6 +319,10 @@ export default {
|
|||||||
title: "",
|
title: "",
|
||||||
// 是否显示弹出层
|
// 是否显示弹出层
|
||||||
open: false,
|
open: false,
|
||||||
|
//班级类型 字典
|
||||||
|
classInfoOptions: [],
|
||||||
|
// 班级下幼儿列表
|
||||||
|
childInfoOptions: [],
|
||||||
// 视力评价字典
|
// 视力评价字典
|
||||||
visionAssessmentOptions: [],
|
visionAssessmentOptions: [],
|
||||||
// 是否龋齿字典
|
// 是否龋齿字典
|
||||||
@ -307,6 +333,7 @@ export default {
|
|||||||
heightAssessmentOptions: [],
|
heightAssessmentOptions: [],
|
||||||
// 总评价字典
|
// 总评价字典
|
||||||
totalAssessmentOptions: [],
|
totalAssessmentOptions: [],
|
||||||
|
|
||||||
// 查询参数
|
// 查询参数
|
||||||
queryParams: {
|
queryParams: {
|
||||||
pageNum: 1,
|
pageNum: 1,
|
||||||
@ -330,12 +357,15 @@ export default {
|
|||||||
},
|
},
|
||||||
// 表单参数
|
// 表单参数
|
||||||
form: {},
|
form: {},
|
||||||
|
|
||||||
// 表单校验
|
// 表单校验
|
||||||
rules: {}
|
rules: {}
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.getList();
|
this.getList();
|
||||||
|
this.getclassinfo();
|
||||||
|
|
||||||
this.getDicts("sys_vision_assessment").then(response => {
|
this.getDicts("sys_vision_assessment").then(response => {
|
||||||
this.visionAssessmentOptions = response.data;
|
this.visionAssessmentOptions = response.data;
|
||||||
});
|
});
|
||||||
@ -353,6 +383,14 @@ export default {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
// 班级选择框变化后触发
|
||||||
|
classInfoChange() {
|
||||||
|
this.queryParams.childId = null;
|
||||||
|
listChild(null).then(response => {
|
||||||
|
this.childInfoOptions = response.rows;
|
||||||
|
});
|
||||||
|
|
||||||
|
},
|
||||||
/** 查询儿童常规体检记录列表 */
|
/** 查询儿童常规体检记录列表 */
|
||||||
getList() {
|
getList() {
|
||||||
this.loading = true;
|
this.loading = true;
|
||||||
@ -362,6 +400,12 @@ export default {
|
|||||||
this.loading = false;
|
this.loading = false;
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
// 查询所有班级信息
|
||||||
|
getclassinfo() {
|
||||||
|
listClass(null).then(response => {
|
||||||
|
this.classInfoOptions = response.rows;
|
||||||
|
});
|
||||||
|
},
|
||||||
// 视力评价字典翻译
|
// 视力评价字典翻译
|
||||||
visionAssessmentFormat(row, column) {
|
visionAssessmentFormat(row, column) {
|
||||||
return this.selectDictLabel(
|
return this.selectDictLabel(
|
||||||
|
@ -3,6 +3,7 @@ package com.ruoyi.project.benyi.domain;
|
|||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
|
|
||||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import com.ruoyi.project.system.domain.ByClass;
|
||||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||||
import com.ruoyi.framework.aspectj.lang.annotation.Excel;
|
import com.ruoyi.framework.aspectj.lang.annotation.Excel;
|
||||||
@ -121,6 +122,8 @@ public class ByChildHealthCheck extends BaseEntity {
|
|||||||
|
|
||||||
private ByChild byChild;
|
private ByChild byChild;
|
||||||
|
|
||||||
|
private ByClass byClass;
|
||||||
|
|
||||||
private Long createuser;
|
private Long createuser;
|
||||||
|
|
||||||
public void setId(Long id) {
|
public void setId(Long id) {
|
||||||
@ -272,6 +275,7 @@ public class ByChildHealthCheck extends BaseEntity {
|
|||||||
.append("createtime", getCreatetime())
|
.append("createtime", getCreatetime())
|
||||||
.append("createuser", getCreateuser())
|
.append("createuser", getCreateuser())
|
||||||
.append("byChild", getByChild())
|
.append("byChild", getByChild())
|
||||||
|
.append("byClass", getByChild())
|
||||||
.toString();
|
.toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -290,4 +294,12 @@ public class ByChildHealthCheck extends BaseEntity {
|
|||||||
public void setByChild(ByChild byChild) {
|
public void setByChild(ByChild byChild) {
|
||||||
this.byChild = byChild;
|
this.byChild = byChild;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public ByClass getByClass() {
|
||||||
|
return byClass;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setByClass(ByClass byClass) {
|
||||||
|
this.byClass = byClass;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -23,6 +23,26 @@
|
|||||||
<result property="createtime" column="createtime"/>
|
<result property="createtime" column="createtime"/>
|
||||||
<result property="createuser" column="createuser"/>
|
<result property="createuser" column="createuser"/>
|
||||||
<association property="byChild" column="id" javaType="ByChild" resultMap="ByChildResult" />
|
<association property="byChild" column="id" javaType="ByChild" resultMap="ByChildResult" />
|
||||||
|
<association property="byClass" column="bjbh" javaType="ByClass" resultMap="ByClassResult" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<resultMap type="ByClass" id="ByClassResult">
|
||||||
|
<result property="bjbh" column="bjbh"/>
|
||||||
|
<result property="deptId" column="dept_id"/>
|
||||||
|
<result property="bjtype" column="bjtype"/>
|
||||||
|
<result property="bhxh" column="bhxh"/>
|
||||||
|
<result property="xn" column="xn"/>
|
||||||
|
<result property="bjmc" column="bjmc"/>
|
||||||
|
<result property="bjrych" column="bjrych"/>
|
||||||
|
<result property="jbny" column="jbny"/>
|
||||||
|
<result property="zbjs" column="zbjs"/>
|
||||||
|
<result property="zbjsxm" column="zbjsxm"/>
|
||||||
|
<result property="pbjs" column="pbjs"/>
|
||||||
|
<result property="pbjsxm" column="pbjsxm"/>
|
||||||
|
<result property="zljs" column="zljs"/>
|
||||||
|
<result property="zljsxm" column="zljsxm"/>
|
||||||
|
<result property="isdel" column="isdel"/>
|
||||||
|
<result property="createtime" column="createtime"/>
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<resultMap type="ByChild" id="ByChildResult">
|
<resultMap type="ByChild" id="ByChildResult">
|
||||||
@ -71,9 +91,10 @@
|
|||||||
|
|
||||||
<sql id="selectByChildHealthCheckVo">
|
<sql id="selectByChildHealthCheckVo">
|
||||||
select h.id, h.child_id, h.class_info, h.school_name, h.check_time, h.doctor_name, h.eyes_vision_left, h.eyes_vision_right, h.vision_assessment, h.decayed_tooth, h.weight, h.weight_assessment, h.height, h.height_assessment, h.total_assessment, h.createtime, h.createuser,
|
select h.id, h.child_id, h.class_info, h.school_name, h.check_time, h.doctor_name, h.eyes_vision_left, h.eyes_vision_right, h.vision_assessment, h.decayed_tooth, h.weight, h.weight_assessment, h.height, h.height_assessment, h.total_assessment, h.createtime, h.createuser,
|
||||||
c.id, c.schoolid, c.classid, c.name
|
c.id, c.schoolid, c.classid, c.name, b.bjbh, b.bjmc
|
||||||
from by_child_health_check h
|
from by_child_health_check h
|
||||||
left join by_child c on h.child_id = c.id
|
left join by_child c on h.child_id = c.id
|
||||||
|
left join by_class b on h.class_info = b.bjbh
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="selectByChildHealthCheckList" parameterType="ByChildHealthCheck" resultMap="ByChildHealthCheckResult">
|
<select id="selectByChildHealthCheckList" parameterType="ByChildHealthCheck" resultMap="ByChildHealthCheckResult">
|
||||||
@ -109,7 +130,7 @@
|
|||||||
|
|
||||||
<select id="selectByChildHealthCheckById" parameterType="Long" resultMap="ByChildHealthCheckResult">
|
<select id="selectByChildHealthCheckById" parameterType="Long" resultMap="ByChildHealthCheckResult">
|
||||||
<include refid="selectByChildHealthCheckVo"/>
|
<include refid="selectByChildHealthCheckVo"/>
|
||||||
where id = #{id}
|
where h.id = #{id}
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<insert id="insertByChildHealthCheck" parameterType="ByChildHealthCheck" useGeneratedKeys="true" keyProperty="id">
|
<insert id="insertByChildHealthCheck" parameterType="ByChildHealthCheck" useGeneratedKeys="true" keyProperty="id">
|
||||||
|
Loading…
x
Reference in New Issue
Block a user