Commit c34a1512 authored by 赵啸非's avatar 赵啸非

Merge remote-tracking branch 'origin/master'

parents 6f9308d0 6e924bf4
<template>
<!-- 弹出框表单 -->
<el-drawer
:title="title"
:visible.sync="open"
:direction="direction"
size="50%">
<el-form ref="form" :model="form" :rules="rules" label-width="120px">
<el-row>
<Field label="班次ID" prop="shiftsId" v-model="form.shiftsId" placeholder="请输入班次ID"/>
<Field label="班次名称" prop="shiftsName" v-model="form.shiftsName" placeholder="请输入班次名称"/>
<Field label="上班打卡时间" prop="goWorkDate" v-model="form.goWorkDate" type="date" />
<Field label="上班打卡前时间段,单位分钟" prop="goWorkDateBefore" v-model="form.goWorkDateBefore" placeholder="请输入上班打卡前时间段,单位分钟"/>
<Field label="上班打卡前时间段,单位分钟" prop="goWorkDateAfter" v-model="form.goWorkDateAfter" placeholder="请输入上班打卡前时间段,单位分钟"/>
<Field label="下班打卡时间" prop="offWorkDate" v-model="form.offWorkDate" type="date" />
<Field label="下班打卡前时间段,单位分钟" prop="offWorkDateBefore" v-model="form.offWorkDateBefore" placeholder="请输入下班打卡前时间段,单位分钟"/>
<Field label="下班打卡前时间段,单位分钟" prop="offWorkDateAfter" v-model="form.offWorkDateAfter" placeholder="请输入下班打卡前时间段,单位分钟"/>
<Field label="备注" prop="remark" v-model="form.remark" type="textarea" placeholder="请输入备注"/>
<!-- 弹出框表单 -->
<el-drawer
:title="title"
:visible.sync="open"
:direction="direction"
size="50%"
>
<el-form ref="form" :model="form" :rules="rules" label-width="120px">
<el-row>
<Field
label="班次ID"
prop="shiftsId"
v-model="form.shiftsId"
placeholder="请输入班次ID"
/>
<Field
label="班次名称"
prop="shiftsName"
v-model="form.shiftsName"
placeholder="请输入班次名称"
/>
<Field
label="上班打卡时间"
prop="goWorkDate"
v-model="form.goWorkDate"
type="date"
/>
<Field
label="上班打卡前时间段,单位分钟"
prop="goWorkDateBefore"
v-model="form.goWorkDateBefore"
placeholder="请输入上班打卡前时间段,单位分钟"
/>
<Field
label="上班打卡前时间段,单位分钟"
prop="goWorkDateAfter"
v-model="form.goWorkDateAfter"
placeholder="请输入上班打卡前时间段,单位分钟"
/>
<Field
label="下班打卡时间"
prop="offWorkDate"
v-model="form.offWorkDate"
type="date"
/>
<Field
label="下班打卡前时间段,单位分钟"
prop="offWorkDateBefore"
v-model="form.offWorkDateBefore"
placeholder="请输入下班打卡前时间段,单位分钟"
/>
<Field
label="下班打卡前时间段,单位分钟"
prop="offWorkDateAfter"
v-model="form.offWorkDateAfter"
placeholder="请输入下班打卡前时间段,单位分钟"
/>
<Field
label="备注"
prop="remark"
v-model="form.remark"
type="textarea"
placeholder="请输入备注"
/>
</el-row>
</el-row>
<form-buttons @submit='submitForm' noCancelBtn />
</el-form>
</el-drawer>
<form-buttons @submit="submitForm" noCancelBtn />
</el-form>
</el-drawer>
</template>
<script>
import form from "@/assets/mixins/formdialog";
export default {
name: "AttendanceClassDetailDetail",
mixins: [form],
components: {
},
created() {
this.changePath("attendance/class/detail")
},
data() {
return {
// 遮罩层
loading: true,
// 弹出层标题
title: "考勤班次详细信息",
// 是否显示弹出层
open: false,
direction:"rtl",
toString:[
],
toDate:[
"goWorkDate",
"offWorkDate",
],
// 表单校验
rules: {
createTime: [
{required: true,message: "请选择创建时间" },
],
}
};
},
import form from "@/assets/mixins/formdialog";
export default {
name: "AttendanceClassDetailDetail",
mixins: [form],
components: {},
created() {
this.changePath("attendance/class/detail");
},
data() {
return {
// 遮罩层
loading: true,
// 弹出层标题
title: "考勤班次详细信息",
// 是否显示弹出层
open: false,
direction: "rtl",
toString: [],
toDate: ["goWorkDate", "offWorkDate"],
// 表单校验
rules: {
createTime: [{ required: true, message: "请选择创建时间" }],
},
};
},
methods: {
/** 编辑 */
edit(row) {
this.reset()
this.query = { id: row.id };
this.urls.currUrl ="attendance/class/detail/edit";
this.getData();
this.pageInfo.type="edit"
this.title = "修改考勤班次详细信息";
},
/** 新增 */
add(row) {
this.reset()
this.urls.currUrl = "attendance/class/detail/add";
this.getData();
this.pageInfo.type="add"
this.title = "新增考勤班次详细信息";
},
/** 查看*/
view(row) {
this.reset()
this.query = { id: row.id };
this.urls.currUrl ="attendance/class/detail/view";
this.getData();
this.pageInfo.type="view"
this.title = "考勤班次详细信息详细";
},
/**取消按钮 */
cancel() {
this.open = false;
},
/**获取数据后弹框 */
afterRender(data) {
this.open = true;
},
methods: {
/** 编辑 */
edit(row) {
this.reset();
this.query = { id: row.id };
this.urls.currUrl = "attendance/class/detail/edit";
this.getData();
this.pageInfo.type = "edit";
this.title = "修改考勤班次详细信息";
},
/** 新增 */
add(row) {
this.reset();
this.urls.currUrl = "attendance/class/detail/add";
this.getData();
this.pageInfo.type = "add";
this.title = "新增考勤班次详细信息";
},
/** 查看*/
view(row) {
this.reset();
this.query = { id: row.id };
this.urls.currUrl = "attendance/class/detail/view";
this.getData();
this.pageInfo.type = "view";
this.title = "考勤班次详细信息详细";
},
/**取消按钮 */
cancel() {
this.open = false;
},
/**获取数据后弹框 */
afterRender(data) {
this.open = true;
},
afterSubmit(data) {
this.open = false;
this.$emit("ok");
},
afterSubmit(data) {
this.open = false;
this.$emit("ok");
},
// 表单重置
reset() {
this.form = {
shiftsId : null,
shiftsName : "",
goWorkDate : null,
goWorkDateBefore : null,
goWorkDateAfter : null,
offWorkDate : null,
offWorkDateBefore : null,
offWorkDateAfter : null,
remark : "",
};
this.resetForm("form");
},
resetForm(refName) {
if (this.$refs[refName]) {
this.$refs[refName].resetFields();
}
},
},
};
// 表单重置
reset() {
this.form = {
shiftsId: null,
shiftsName: "",
goWorkDate: null,
goWorkDateBefore: null,
goWorkDateAfter: null,
offWorkDate: null,
offWorkDateBefore: null,
offWorkDateAfter: null,
remark: "",
};
this.resetForm("form");
},
resetForm(refName) {
if (this.$refs[refName]) {
this.$refs[refName].resetFields();
}
},
},
};
</script>
......@@ -7,7 +7,7 @@
<Field label="班次负责人" prop="classResponsiblePersonId" type="select" :enumData="dict.workManId"
v-model="form.classResponsiblePersonId" placeholder="请选择班次负责人"/>
</el-row>
<el-form-item label="上下班时间" prop="attendanceClassDetailList">
<el-form-item label="上下班考勤时间" prop="attendanceClassDetailList">
<el-button type="text" @click="handleAddAttendanceClassDetail">添加</el-button>
<div class="bancifor" v-for="(item,index) in attendanceClassDetailList" :key="index">
<div class="title flex flex-align-center flex-pack-justify">
......@@ -17,7 +17,7 @@
<el-button type="danger" size="mini" @click="handleDeleteAttendanceClassDetail(index)">删除</el-button>
</div>
<div>
<span>上班时间</span>
<span>上班考勤时间</span>
<el-time-picker
size="mini"
style="width:150px"
......@@ -25,12 +25,12 @@
value-format="HH:mm"
format="HH:mm"
v-model="item.goWorkDate"
placeholder="上班时间">
placeholder="上班考勤时间">
</el-time-picker>
</div>
<div>
<span>打开时段: </span>
<span>上班前</span>
<span>上班前签到</span>
<el-time-picker
size="mini"
style="width:150px"
......@@ -41,7 +41,7 @@
placeholder="未设置">
</el-time-picker>
<span class="ml20">——</span>
<span class="ml20">上班后</span>
<span class="ml20">上班后签到</span>
<el-time-picker
size="mini"
style="width:150px"
......@@ -53,7 +53,7 @@
</el-time-picker>
</div>
<div>
<span>下班时间</span>
<span>下班考勤时间</span>
<el-time-picker
size="mini"
style="width:150px"
......@@ -61,12 +61,12 @@
format="HH:mm"
value-format="HH:mm"
v-model="item.offWorkDate"
placeholder="下班时间">
placeholder="下班考勤时间">
</el-time-picker>
</div>
<div>
<span>打开时段:</span>
<span>下班前</span>
<span>下班前签退</span>
<el-time-picker
size="mini"
style="width:150px"
......@@ -77,7 +77,7 @@
placeholder="未设置">
</el-time-picker>
<span class="ml20">——</span>
<span class="ml20">下班后</span>
<span class="ml20">下班后签退</span>
<el-time-picker
size="mini"
style="width:150px"
......@@ -189,40 +189,40 @@
this.attendanceClassDetailList.push(obj);
},
// 判断添加上下班时间
// 判断添加上下班考勤时间
judgeStatus(arr,index){
console.log(arr,index,'ces')
let status = true
if(arr.length == 0){
}else{
if(arr[index].goWorkDate === ''){
this.$message.error('请选择上班时间')
this.$message.error('请选择上班考勤时间')
status = false
return
}
if(arr[index].goWorkDateBefore === ''){
this.$message.error('请选择允许上班前打卡时间')
this.$message.error('请选择允许上班前签到打卡时间')
status = false
return
}
if(arr[index].goWorkDateAfter === ''){
this.$message.error('请选择允许上班后打卡时间')
this.$message.error('请选择允许上班后签到打卡时间')
status = false
return
}
if(arr[index].offWorkDate === ''){
this.$message.error('请选择下班时间')
this.$message.error('请选择下班考勤时间')
status = false
return
}
if(arr[index].offWorkDateBefore === ''){
this.$message.error('请选择允许下班前打卡时间')
this.$message.error('请选择允许下班前签退打卡时间')
status = false
return
}
if(arr[index].offWorkDateAfter === ''){
this.$message.error('请选择允许下班后打卡时间')
this.$message.error('请选择允许下班后签退打卡时间')
status = false
return
}
......@@ -248,7 +248,7 @@
transFormMinut(arr[index].goWorkDateBefore)
if(currentwokeTime <= lastoffTime){
this.$message.error(`第${index}上班时间需大于第${index-1}上班时间`)
this.$message.error(`第${index}上班考勤时间需大于第${index-1}上班考勤时间`)
status = false
return
}
......
<template>
<!-- 弹出框表单 -->
<el-drawer
:title="title"
:visible.sync="open"
:direction="direction"
size="50%">
<el-form ref="form" :model="form" :rules="rules" label-width="120px">
<el-row>
<Field label="班次名称" prop="className" v-model="form.className" placeholder="请输入班次名称"/>
<Field label="班次负责人ID" prop="classResponsiblePersonId" v-model="form.classResponsiblePersonId" placeholder="请输入班次负责人ID"/>
<Field label="班次负责人名称" prop="classResponsiblePersonName" v-model="form.classResponsiblePersonName" placeholder="请输入班次负责人名称"/>
<Field label="备注" prop="remark" v-model="form.remark" type="textarea" placeholder="请输入备注"/>
<!-- 弹出框表单 -->
<el-drawer
:title="title"
:visible.sync="open"
:direction="direction"
size="50%"
>
<el-form ref="form" :model="form" :rules="rules" label-width="120px">
<el-row>
<Field
label="班次名称"
prop="className"
v-model="form.className"
placeholder="请输入班次名称"
/>
<Field
label="班次负责人ID"
prop="classResponsiblePersonId"
v-model="form.classResponsiblePersonId"
placeholder="请输入班次负责人ID"
/>
<Field
label="班次负责人名称"
prop="classResponsiblePersonName"
v-model="form.classResponsiblePersonName"
placeholder="请输入班次负责人名称"
/>
<Field
label="备注"
prop="remark"
v-model="form.remark"
type="textarea"
placeholder="请输入备注"
/>
</el-row>
<el-divider content-position="center">考勤班次详细信息信息</el-divider>
<br />
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
icon="el-icon-plus"
size="mini"
@click="handleAddAttendanceClassDetail"
>添加</el-button
>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
icon="el-icon-delete"
size="mini"
@click="handleDeleteAttendanceClassDetail"
>删除</el-button
>
</el-col>
</el-row>
</el-row>
<el-divider content-position="center">考勤班次详细信息信息</el-divider>
<br/>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button type="primary" icon="el-icon-plus" size="mini" @click="handleAddAttendanceClassDetail">添加</el-button>
</el-col>
<el-col :span="1.5">
<el-button type="danger" icon="el-icon-delete" size="mini" @click="handleDeleteAttendanceClassDetail">删除</el-button>
</el-col>
</el-row>
<el-table
:data="attendanceClassDetailList"
:row-class-name="rowAttendanceClassDetailIndex"
@selection-change="handleAttendanceClassDetailSelectionChange"
ref="attendanceClassDetail"
>
<el-table-column type="selection" width="50" align="center" />
<el-table-column label="序号" align="center" prop="index" width="50" />
<el-table-column label="班次名称" prop="shiftsName">
<template slot-scope="scope">
<el-input
v-model="scope.row.shiftsName"
placeholder="请输入班次名称"
/>
</template>
</el-table-column>
<el-table-column label="上班打卡时间" prop="goWorkDate">
<template slot-scope="scope">
<el-input
v-model="scope.row.goWorkDate"
placeholder="请输入上班打卡时间"
/>
</template>
</el-table-column>
<el-table-column
label="上班打卡前时间段,单位分钟"
prop="goWorkDateBefore"
>
<template slot-scope="scope">
<el-input
v-model="scope.row.goWorkDateBefore"
placeholder="请输入上班打卡前时间段,单位分钟"
/>
</template>
</el-table-column>
<el-table-column
label="上班打卡前时间段,单位分钟"
prop="goWorkDateAfter"
>
<template slot-scope="scope">
<el-input
v-model="scope.row.goWorkDateAfter"
placeholder="请输入上班打卡前时间段,单位分钟"
/>
</template>
</el-table-column>
<el-table-column label="下班打卡时间" prop="offWorkDate">
<template slot-scope="scope">
<el-input
v-model="scope.row.offWorkDate"
placeholder="请输入下班打卡时间"
/>
</template>
</el-table-column>
<el-table-column
label="下班打卡前时间段,单位分钟"
prop="offWorkDateBefore"
>
<template slot-scope="scope">
<el-input
v-model="scope.row.offWorkDateBefore"
placeholder="请输入下班打卡前时间段,单位分钟"
/>
</template>
</el-table-column>
<el-table-column
label="下班打卡前时间段,单位分钟"
prop="offWorkDateAfter"
>
<template slot-scope="scope">
<el-input
v-model="scope.row.offWorkDateAfter"
placeholder="请输入下班打卡前时间段,单位分钟"
/>
</template>
</el-table-column>
<el-table-column label="备注" prop="remark">
<template slot-scope="scope">
<el-input v-model="scope.row.remark" placeholder="请输入备注" />
</template>
</el-table-column>
<el-table-column label="创建用户" prop="createUserId">
<template slot-scope="scope">
<el-input
v-model="scope.row.createUserId"
placeholder="请输入创建用户"
/>
</template>
</el-table-column>
<el-table-column label="创建时间" prop="createTime">
<template slot-scope="scope">
<el-input
v-model="scope.row.createTime"
placeholder="请输入创建时间"
/>
</template>
</el-table-column>
<el-table-column label="更新用户" prop="updateUserId">
<template slot-scope="scope">
<el-input
v-model="scope.row.updateUserId"
placeholder="请输入更新用户"
/>
</template>
</el-table-column>
<el-table-column label="更新时间" prop="updateTime">
<template slot-scope="scope">
<el-input
v-model="scope.row.updateTime"
placeholder="请输入更新时间"
/>
</template>
</el-table-column>
</el-table>
<el-table :data="attendanceClassDetailList" :row-class-name="rowAttendanceClassDetailIndex" @selection-change="handleAttendanceClassDetailSelectionChange" ref="attendanceClassDetail">
<el-table-column type="selection" width="50" align="center" />
<el-table-column label="序号" align="center" prop="index" width="50"/>
<el-table-column label="班次名称" prop="shiftsName">
<template slot-scope="scope">
<el-input v-model="scope.row.shiftsName" placeholder="请输入班次名称" />
</template>
</el-table-column>
<el-table-column label="上班打卡时间" prop="goWorkDate">
<template slot-scope="scope">
<el-input v-model="scope.row.goWorkDate" placeholder="请输入上班打卡时间" />
</template>
</el-table-column>
<el-table-column label="上班打卡前时间段,单位分钟" prop="goWorkDateBefore">
<template slot-scope="scope">
<el-input v-model="scope.row.goWorkDateBefore" placeholder="请输入上班打卡前时间段,单位分钟" />
</template>
</el-table-column>
<el-table-column label="上班打卡前时间段,单位分钟" prop="goWorkDateAfter">
<template slot-scope="scope">
<el-input v-model="scope.row.goWorkDateAfter" placeholder="请输入上班打卡前时间段,单位分钟" />
</template>
</el-table-column>
<el-table-column label="下班打卡时间" prop="offWorkDate">
<template slot-scope="scope">
<el-input v-model="scope.row.offWorkDate" placeholder="请输入下班打卡时间" />
</template>
</el-table-column>
<el-table-column label="下班打卡前时间段,单位分钟" prop="offWorkDateBefore">
<template slot-scope="scope">
<el-input v-model="scope.row.offWorkDateBefore" placeholder="请输入下班打卡前时间段,单位分钟" />
</template>
</el-table-column>
<el-table-column label="下班打卡前时间段,单位分钟" prop="offWorkDateAfter">
<template slot-scope="scope">
<el-input v-model="scope.row.offWorkDateAfter" placeholder="请输入下班打卡前时间段,单位分钟" />
</template>
</el-table-column>
<el-table-column label="备注" prop="remark">
<template slot-scope="scope">
<el-input v-model="scope.row.remark" placeholder="请输入备注" />
</template>
</el-table-column>
<el-table-column label="创建用户" prop="createUserId">
<template slot-scope="scope">
<el-input v-model="scope.row.createUserId" placeholder="请输入创建用户" />
</template>
</el-table-column>
<el-table-column label="创建时间" prop="createTime">
<template slot-scope="scope">
<el-input v-model="scope.row.createTime" placeholder="请输入创建时间" />
</template>
</el-table-column>
<el-table-column label="更新用户" prop="updateUserId">
<template slot-scope="scope">
<el-input v-model="scope.row.updateUserId" placeholder="请输入更新用户" />
</template>
</el-table-column>
<el-table-column label="更新时间" prop="updateTime">
<template slot-scope="scope">
<el-input v-model="scope.row.updateTime" placeholder="请输入更新时间" />
</template>
</el-table-column>
</el-table>
<form-buttons @submit='submitForm' noCancelBtn />
</el-form>
</el-drawer>
<form-buttons @submit="submitForm" noCancelBtn />
</el-form>
</el-drawer>
</template>
<script>
import form from "@/assets/mixins/formdialog";
export default {
name: "AttendanceClassDetail",
mixins: [form],
components: {
},
created() {
this.changePath("attendance/class")
},
data() {
return {
// 子表选中数据
checkedAttendanceClassDetail: [],
// 考勤班次详细信息表格数据
attendanceClassDetailList: [],
// 遮罩层
loading: true,
// 弹出层标题
title: "考勤班次信息",
// 是否显示弹出层
open: false,
direction:"rtl",
toString:[
],
toDate:[
],
// 表单校验
rules: {
createTime: [
{required: true,message: "请选择创建时间" },
],
}
};
},
import form from "@/assets/mixins/formdialog";
export default {
name: "AttendanceClassDetail",
mixins: [form],
components: {},
created() {
this.changePath("attendance/class");
},
data() {
return {
// 子表选中数据
checkedAttendanceClassDetail: [],
// 考勤班次详细信息表格数据
attendanceClassDetailList: [],
// 遮罩层
loading: true,
// 弹出层标题
title: "考勤班次信息",
// 是否显示弹出层
open: false,
direction: "rtl",
toString: [],
toDate: [],
// 表单校验
rules: {
createTime: [{ required: true, message: "请选择创建时间" }],
},
};
},
methods: {
/** 考勤班次详细信息序号 */
rowAttendanceClassDetailIndex({ row, rowIndex }) {
row.index = rowIndex + 1;
},
/** 考勤班次详细信息添加按钮操作 */
handleAddAttendanceClassDetail() {
let obj = {};
obj.shiftsName = "";
obj.goWorkDate = "";
obj.goWorkDateBefore = "";
obj.goWorkDateAfter = "";
obj.offWorkDate = "";
obj.offWorkDateBefore = "";
obj.offWorkDateAfter = "";
obj.remark = "";
obj.createUserId = "";
obj.createTime = "";
obj.updateUserId = "";
obj.updateTime = "";
this.attendanceClassDetailList.push(obj);
},
/** 考勤班次详细信息删除按钮操作 */
handleDeleteAttendanceClassDetail() {
if (this.checkedAttendanceClassDetail.length == 0) {
this.$alert("请先选择要删除的考勤班次详细信息数据", "提示", { confirmButtonText: "确定", });
} else {
this.attendanceClassDetailList.splice(this.checkedAttendanceClassDetail[0].index - 1, 1);
}
},
/** 单选框选中数据 */
handleAttendanceClassDetailSelectionChange(selection) {
if (selection.length > 1) {
this.$refs.attendanceClassDetail.clearSelection();
this.$refs.attendanceClassDetail.toggleRowSelection(selection.pop());
} else {
this.checkedAttendanceClassDetail = selection;
}
},
// 渲染前置处理
beforeRender(data) {
if(data.entity.attendanceClassDetailList) {
this.attendanceClassDetailList = data.entity.attendanceClassDetailList;
}
return data
},
/** 编辑 */
edit(row) {
this.reset()
this.query = { id: row.id };
this.urls.currUrl ="attendance/class/edit";
this.getData();
this.pageInfo.type="edit"
this.title = "修改考勤班次信息";
},
/** 新增 */
add(row) {
this.reset()
this.urls.currUrl = "attendance/class/add";
this.getData();
this.pageInfo.type="add"
this.title = "新增考勤班次信息";
},
/** 查看*/
view(row) {
this.reset()
this.query = { id: row.id };
this.urls.currUrl ="attendance/class/view";
this.getData();
this.pageInfo.type="view"
this.title = "考勤班次信息详细";
},
/**取消按钮 */
cancel() {
this.open = false;
},
/**获取数据后弹框 */
afterRender(data) {
this.open = true;
},
methods: {
/** 考勤班次详细信息序号 */
rowAttendanceClassDetailIndex({ row, rowIndex }) {
row.index = rowIndex + 1;
},
/** 考勤班次详细信息添加按钮操作 */
handleAddAttendanceClassDetail() {
let obj = {};
obj.shiftsName = "";
obj.goWorkDate = "";
obj.goWorkDateBefore = "";
obj.goWorkDateAfter = "";
obj.offWorkDate = "";
obj.offWorkDateBefore = "";
obj.offWorkDateAfter = "";
obj.remark = "";
obj.createUserId = "";
obj.createTime = "";
obj.updateUserId = "";
obj.updateTime = "";
this.attendanceClassDetailList.push(obj);
},
/** 考勤班次详细信息删除按钮操作 */
handleDeleteAttendanceClassDetail() {
if (this.checkedAttendanceClassDetail.length == 0) {
this.$alert("请先选择要删除的考勤班次详细信息数据", "提示", {
confirmButtonText: "确定",
});
} else {
this.attendanceClassDetailList.splice(
this.checkedAttendanceClassDetail[0].index - 1,
1
);
}
},
/** 单选框选中数据 */
handleAttendanceClassDetailSelectionChange(selection) {
if (selection.length > 1) {
this.$refs.attendanceClassDetail.clearSelection();
this.$refs.attendanceClassDetail.toggleRowSelection(selection.pop());
} else {
this.checkedAttendanceClassDetail = selection;
}
},
// 渲染前置处理
beforeRender(data) {
if (data.entity.attendanceClassDetailList) {
this.attendanceClassDetailList = data.entity.attendanceClassDetailList;
}
return data;
},
/** 编辑 */
edit(row) {
this.reset();
this.query = { id: row.id };
this.urls.currUrl = "attendance/class/edit";
this.getData();
this.pageInfo.type = "edit";
this.title = "修改考勤班次信息";
},
/** 新增 */
add(row) {
this.reset();
this.urls.currUrl = "attendance/class/add";
this.getData();
this.pageInfo.type = "add";
this.title = "新增考勤班次信息";
},
/** 查看*/
view(row) {
this.reset();
this.query = { id: row.id };
this.urls.currUrl = "attendance/class/view";
this.getData();
this.pageInfo.type = "view";
this.title = "考勤班次信息详细";
},
/**取消按钮 */
cancel() {
this.open = false;
},
/**获取数据后弹框 */
afterRender(data) {
this.open = true;
},
afterSubmit(data) {
this.open = false;
this.$emit("ok");
},
afterSubmit(data) {
this.open = false;
this.$emit("ok");
},
// 表单重置
reset() {
this.form = {
className : "",
classResponsiblePersonId : null,
classResponsiblePersonName : "",
remark : "",
};
this.resetForm("form");
},
resetForm(refName) {
if (this.$refs[refName]) {
this.$refs[refName].resetFields();
}
},
},
};
// 表单重置
reset() {
this.form = {
className: "",
classResponsiblePersonId: null,
classResponsiblePersonName: "",
remark: "",
};
this.resetForm("form");
},
resetForm(refName) {
if (this.$refs[refName]) {
this.$refs[refName].resetFields();
}
},
},
};
</script>
......@@ -712,7 +712,7 @@ export default {
indicator: names.map((v) => {
return {
name: v,
max: 150,
max: Math.max(...[...add, ...sub]),
};
}),
center: ["45%", "50%"],
......@@ -734,10 +734,10 @@ export default {
value: add,
name: "加分",
symbol: "rect",
symbolSize: 12,
// symbolSize: 12,
areaStyle: { color: "#56A3F1" }, //雷达覆盖区域背景颜色
label: {
show: true,
show: false,
formatter: function (params) {
return params.value;
},
......
......@@ -95,7 +95,6 @@ export default {
data() {
return {
switchValue: "0",
searchValue: "",
index: -1,
dataArr: [],
......@@ -227,7 +226,7 @@ export default {
type: this.activeName,
page: this.query.page,
orderColList: this.typeArr,
name: this.searchValue,
name: `%${this.searchValue}%`,
}).then((res) => {
if (res.code == 1) {
this.tableData = res.data;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment