一日流程评估计划管理完成

This commit is contained in:
zhanglipeng 2021-02-05 10:50:27 +08:00
parent 94cf3fa544
commit 865528266d
3 changed files with 59 additions and 20 deletions

View File

@ -110,18 +110,20 @@
<span>{{ parseTime(scope.row.month, "{y}-{m}-{d}") }}</span> <span>{{ parseTime(scope.row.month, "{y}-{m}-{d}") }}</span>
</template> </template>
</el-table-column> --> </el-table-column> -->
<el-table-column label="评估学年学期" align="center" prop="xnxq" />
<el-table-column label="评估班级" align="center" prop="classid" />
<el-table-column label="评估内容" align="center" prop="connent" />
<el-table-column <el-table-column
label="评估时间" label="评估学年学期"
align="center" align="center"
prop="starttime" prop="xnxq"
> :formatter="xnxqFormat"
<template slot-scope="scope"> />
<span>{{ parseTime(scope.row.starttime, "{y}-{m}-{d}") }}</span> <el-table-column
</template> label="评估班级"
</el-table-column> align="center"
prop="classid"
:formatter="classFormat"
/>
<el-table-column label="评估内容" align="center" prop="connent" :formatter="dayFlowFormat"/>
<el-table-column label="评估时间" align="center" prop="starttime" />
<!-- <el-table-column label="创建人" align="center" prop="createUserid" /> --> <!-- <el-table-column label="创建人" align="center" prop="createUserid" /> -->
<el-table-column <el-table-column
label="操作" label="操作"
@ -193,7 +195,14 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="评估内容" prop="connent"> <el-form-item label="评估内容" prop="connent">
<el-input v-model="form.connent" placeholder="请输入评估内容" /> <el-select v-model="form.connent" placeholder="请选择评估内容">
<el-option
v-for="dict in detailOptions"
:key="dict.id"
:label="dict.name"
:value="dict.id"
></el-option>
</el-select>
</el-form-item> </el-form-item>
<el-form-item label="评估时间" prop="starttime"> <el-form-item label="评估时间" prop="starttime">
<el-date-picker <el-date-picker
@ -201,8 +210,8 @@
size="small" size="small"
class="my-date-picker" class="my-date-picker"
v-model="form.starttime" v-model="form.starttime"
type="date" type="datetime"
value-format="yyyy-MM-dd" value-format="yyyy-MM-dd HH:mm:ss"
placeholder="选择评估时间" placeholder="选择评估时间"
> >
</el-date-picker> </el-date-picker>
@ -225,6 +234,7 @@ import {
updateDayflowassessmentplan, updateDayflowassessmentplan,
} from "@/api/benyi/dayflowassessmentplan"; } from "@/api/benyi/dayflowassessmentplan";
import { listClass } from "@/api/system/class"; import { listClass } from "@/api/system/class";
import { listDetail, getDetail } from "@/api/benyi/dayflow/dayflowmanger";
export default { export default {
name: "Dayflowassessmentplan", name: "Dayflowassessmentplan",
@ -250,6 +260,8 @@ export default {
xnxqOptions: [], xnxqOptions: [],
// //
classOptions: [], classOptions: [],
//
detailOptions: [],
// //
queryParams: { queryParams: {
pageNum: 1, pageNum: 1,
@ -266,21 +278,47 @@ export default {
form: {}, form: {},
// //
rules: { rules: {
xnxq: [{ required: true, message: "学年学期不能为空", trigger: "blur" }], xnxq: [
classid: [{ required: true, message: "班级不能为空", trigger: "blur" }], { required: true, message: "学年学期不能为空", trigger: "blur" },
connent: [{ required: true, message: "评估内容不能为空", trigger: "blur" }], ],
starttime: [{ required: true, message: "评估时间不能为空", trigger: "blur" }], classid: [{ required: true, message: "班级不能为空", trigger: "blur" }],
connent: [
{ required: true, message: "评估内容不能为空", trigger: "blur" },
],
starttime: [
{ required: true, message: "评估时间不能为空", trigger: "blur" },
],
}, },
}; };
}, },
created() { created() {
this.getList(); this.getList();
this.getClassList(); this.getClassList();
this.getDayFlowList();
this.getDicts("sys_xnxq").then((response) => { this.getDicts("sys_xnxq").then((response) => {
this.xnxqOptions = response.data; this.xnxqOptions = response.data;
}); });
}, },
methods: { methods: {
//
dayFlowFormat(row, column) {
// return this.selectDictLabel(this.classOptions, row.classid);
var actions = [];
var datas = this.detailOptions;
Object.keys(datas).map((key) => {
if (datas[key].id + "" == "" + row.connent) {
actions.push(datas[key].name);
return false;
}
});
return actions.join("");
},
/** 查询一日流程列表 */
getDayFlowList() {
listDetail(null).then((response) => {
this.detailOptions = response.rows;
});
},
// //
classFormat(row, column) { classFormat(row, column) {
// return this.selectDictLabel(this.classOptions, row.classid); // return this.selectDictLabel(this.classOptions, row.classid);
@ -362,6 +400,7 @@ export default {
const id = row.id || this.ids; const id = row.id || this.ids;
getDayflowassessmentplan(id).then((response) => { getDayflowassessmentplan(id).then((response) => {
this.form = response.data; this.form = response.data;
this.form.connent = parseInt(response.data.connent);
this.open = true; this.open = true;
this.title = "修改幼儿园一日流程评估计划"; this.title = "修改幼儿园一日流程评估计划";
}); });

View File

@ -56,8 +56,8 @@ public class ByDayflowassessmentplan extends BaseEntity {
/** /**
* 评估时间 * 评估时间
*/ */
@JsonFormat(pattern = "yyyy-MM-dd") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@Excel(name = "评估时间", width = 30, dateFormat = "yyyy-MM-dd") @Excel(name = "评估时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
private Date starttime; private Date starttime;
/** /**

View File

@ -25,7 +25,7 @@
<include refid="selectByDayflowassessmentplanVo"/> <include refid="selectByDayflowassessmentplanVo"/>
<where> <where>
<if test="deptId != null ">and dept_id = #{deptId}</if> <if test="deptId != null ">and dept_id = #{deptId}</if>
<if test="month != null ">and month = #{month}</if> <if test="month != null ">and date_format(starttime,'%Y-%m') = date_format(#{month},'%Y-%m')</if>
<if test="xnxq != null and xnxq != ''">and xnxq = #{xnxq}</if> <if test="xnxq != null and xnxq != ''">and xnxq = #{xnxq}</if>
<if test="classid != null and classid != ''">and classid = #{classid}</if> <if test="classid != null and classid != ''">and classid = #{classid}</if>
<if test="connent != null and connent != ''">and connent = #{connent}</if> <if test="connent != null and connent != ''">and connent = #{connent}</if>