一日流程评估

This commit is contained in:
zhanglipeng 2021-04-08 21:56:39 +08:00
parent 5dfb5ed052
commit 8cecc91d81
5 changed files with 81 additions and 101 deletions

View File

@ -222,6 +222,9 @@ aside {
&.justify-between { &.justify-between {
justify-content: space-between; justify-content: space-between;
} }
&.justify-end {
justify-content: flex-end;
}
} }
ul, ul,

View File

@ -459,7 +459,7 @@ export const constantRoutes = [{
component: Layout, component: Layout,
hidden: true, hidden: true,
children: [{ children: [{
path: 'teacher/:id(\\d+)', path: 'teacher',
component: () => component: () =>
import ('@/views/benyi/dayflowassessment/teacher'), import ('@/views/benyi/dayflowassessment/teacher'),
name: 'dayflowassessmentteacher', name: 'dayflowassessmentteacher',

View File

@ -445,7 +445,7 @@ export default {
this.$router.push({ path: "/benyi/dayflowassessment/teacher/" + id }); this.$router.push({ path: "/benyi/dayflowassessment/teacher/" + id });
}, },
handleAdd() { handleAdd() {
this.$router.push({ path: "/benyi/dayflowassessment/teacher/0"}); this.$router.push({ path: "/benyi/dayflowassessment/teacher"});
}, },
/** 修改按钮操作 */ /** 修改按钮操作 */
handleUpdate(row) { handleUpdate(row) {

View File

@ -34,18 +34,6 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :xs="24" :ms="12" :md="5">
<el-form-item label="评估内容" prop="bzid">
<el-select v-model="form.bzid" 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-col>
</el-row> </el-row>
</el-form> </el-form>
<div class="mb8 btn-list"> <div class="mb8 btn-list">
@ -60,38 +48,47 @@
> >
</div> </div>
<el-tabs v-model="activeName" type="card"> <el-tabs v-model="activeName" type="card">
<el-tab-pane
v-for="item in detailOptions"
:key="item.id"
:label="item.name"
:name="item.name"
>
<div <div
class="block" class="block"
v-for="itemTask in dayflowtaskList" v-for="itemTask in dayflowtaskList.filter(
(p) => p.detailId == item.id
)"
:key="itemTask.code" :key="itemTask.code"
> >
<h2 class="block-item-title flex align-center"> <h2 class="block-item-title flex align-center">
{{ itemTask.taskLable }} {{ itemTask.taskLable }}
</h2> </h2>
<div <div
class="checkbox-content" class="checkbox-content"
v-for="itemBz in dayflowstandardList.filter( v-for="(itemBz, index) in dayflowstandardList.filter(
(p) => p.taskCode == itemTask.code (p) => p.taskCode == itemTask.code
)" )"
:key="itemBz.id" :key="itemBz.id"
> >
<p class="checkbox-item flex align-center"> <div class="checkbox-item flex align-center justify-between" :class="{'line': index !== 0}">
<el-row v-model="checkList"> <p class="left-info">
<div :label="itemBz.id" :key="itemBz.id" {{ itemBz.standardTitle }}
>{{ itemBz.standardTitle }}分值: {{ itemBz.score }}
<el-input-number
v-model="num"
:precision="1"
:step="0.1"
:min="-itemBz.score"
:max="itemBz.score"
></el-input-number
></div>
</el-row>
</p> </p>
<div class="right-number flex align-center justify-end">
<span>分值: {{ itemBz.score }}</span>
<el-input-number
class="number-input"
v-model="itemBz.mrz"
:precision="2"
:step="0.1"
:max="itemBz.score"
></el-input-number>
</div> </div>
</div> </div>
</div>
</div>
</el-tab-pane>
</el-tabs> </el-tabs>
</div> </div>
</template> </template>
@ -115,15 +112,8 @@ export default {
data() { data() {
return { return {
num: 0,
dayflowassessmentId: null,
// //
loading: true, loading: true,
//
ids: [],
//
assessmentcontentList: [],
// id // id
dayflowtaskList: [], dayflowtaskList: [],
// //
@ -152,37 +142,27 @@ export default {
scope: undefined, scope: undefined,
sort: undefined, sort: undefined,
}, },
activeName: "一日流程评估", activeName: "早间接待",
checked: false,
checkList: [],
//
form: {},
// //
rules: { rules: {
classid: [{ required: true, message: "班级不能为空", trigger: "blur" }], classid: [{ required: true, message: "班级不能为空", trigger: "blur" }],
pgdx: [ pgdx: [
{ required: true, message: "评估对象不能为空", trigger: "blur" }, { required: true, message: "评估对象不能为空", trigger: "blur" },
], ],
bzid: [
{ required: true, message: "评估内容不能为空", trigger: "blur" },
],
}, },
}; };
}, },
created() { created() {
// this.getList();
const dayflowassessmentId = this.$route.params && this.$route.params.id;
// this.dayflowassessmentId = dayflowassessmentId;
this.getClassList(); this.getClassList();
this.getDayFlowList(); this.getDayFlowList();
this.getTaskList();
}, },
watch: { watch: {
"form.classid": function (val) { "form.classid": function (val) {
this.getUserListByBjbh(val); this.getUserListByBjbh(val);
this.getTaskList();
}, },
"form.bzid": function (val) { "form.pgdx": function (val) {
this.dayflowassessmentId = val;
this.queryParams_detail.detailId = val;
this.getTaskList(); this.getTaskList();
}, },
}, },
@ -219,7 +199,7 @@ export default {
}, },
/** 查询一日流程任务列表 */ /** 查询一日流程任务列表 */
getTaskList() { getTaskList() {
listDayflowtask(this.queryParams_detail).then((response) => { listDayflowtask(null).then((response) => {
this.dayflowtaskList = response.rows; this.dayflowtaskList = response.rows;
}); });
listStandard(null).then((response) => { listStandard(null).then((response) => {
@ -257,44 +237,12 @@ export default {
}, },
/** 提交按钮 */ /** 提交按钮 */
submitForm: function () { submitForm: function () {
this.$confirm("确认评估数据?评估后数据不能取消", "警告", { console.log(this.dayflowstandardList);
confirmButtonText: "确定", this.$refs["form"].validate((valid) => {
cancelButtonText: "取消", if (valid) {
type: "warning",
callback: (action) => {
if (action === "confirm") {
var items = "";
this.checkList.forEach((item) => {
//
items = items + item + ",";
});
if (this.checkList.length == 0) {
this.msgError("请至少选择一项数据");
} else {
this.form.id = this.dayflowassessmentId;
// this.form.classid = this.classid;
this.form.items = items;
this.form.pgdx = this.teacherName;
this.form.bzbh = this.zbjsxm;
this.form.planid = this.planid;
this.form.kfz = this.kfz;
this.form.bzmf = this.bzmf;
updateDayflowassessment(this.form).then((response) => {
if (response.code === 200) {
this.msgSuccess("评估成功");
this.$router.go(-1);
this.$store.dispatch("tagsView/delView", this.$route);
// this.$router.push({
// path:
// "/benyi/dayflowassessment",
// });
} }
}); });
}
} else {
}
},
});
}, },
}, },
}; };
@ -324,9 +272,14 @@ div {
// } // }
} }
} }
.number-input {
width: 120px;
}
.block { .block {
padding: 10px; padding: 10px;
color: #333; color: #333;
.block-item-title { .block-item-title {
padding: 10px 0; padding: 10px 0;
margin: 0; margin: 0;
@ -340,6 +293,18 @@ div {
background: #1890ff; background: #1890ff;
} }
} }
.checkbox-item {
padding: 6px 0;
&.line {
border-top: 1px solid #dadada;
}
.left-info {
line-height: 22px;
}
.right-number {
flex: 0 0 205px;
}
}
.block-content { .block-content {
border-radius: 5px; border-radius: 5px;
@ -361,6 +326,7 @@ div {
.checkbox-item { .checkbox-item {
font-size: 14px; font-size: 14px;
line-height: 22px; line-height: 22px;
} }
.check-info { .check-info {
padding-left: 24px; padding-left: 24px;

View File

@ -74,6 +74,8 @@ public class ByDayFlowStandard extends BaseEntity {
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date updatetime; private Date updatetime;
private String mrz;
public void setId(Long id) { public void setId(Long id) {
this.id = id; this.id = id;
} }
@ -146,6 +148,14 @@ public class ByDayFlowStandard extends BaseEntity {
this.updatetime = updatetime; this.updatetime = updatetime;
} }
public String getMrz() {
return mrz;
}
public void setMrz(String mrz) {
this.mrz = mrz;
}
@Override @Override
public String toString() { public String toString() {
return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE) return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
@ -159,6 +169,7 @@ public class ByDayFlowStandard extends BaseEntity {
.append("updateuser", getUpdateuser()) .append("updateuser", getUpdateuser())
.append("updatetime", getUpdatetime()) .append("updatetime", getUpdatetime())
.append("score", getScore()) .append("score", getScore())
.append("mrz", getMrz())
.toString(); .toString();
} }