mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-14 05:16:45 +08:00
feat:增加考勤查询学员
This commit is contained in:
@@ -513,14 +513,14 @@ export default {
|
|||||||
align: "center",
|
align: "center",
|
||||||
className: "h",
|
className: "h",
|
||||||
},
|
},
|
||||||
// {
|
{
|
||||||
// title: "所在岗位",
|
title: "所在岗位",
|
||||||
// dataIndex: "gang",
|
dataIndex: "gang",
|
||||||
// key: "gang",
|
key: "gang",
|
||||||
// width: 50,
|
width: 50,
|
||||||
// align: "center",
|
align: "center",
|
||||||
// className: "h",
|
className: "h",
|
||||||
// },
|
},
|
||||||
{
|
{
|
||||||
title: "签到时间",
|
title: "签到时间",
|
||||||
dataIndex: "cur",
|
dataIndex: "cur",
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
>
|
>
|
||||||
<div class="drawerMain">
|
<div class="drawerMain">
|
||||||
<div class="header">
|
<div class="header">
|
||||||
<div class="headerTitle">【面授】学员</div>
|
<div class="headerTitle">【面授】{{ datasource?.name }}</div>
|
||||||
<img
|
<img
|
||||||
style="width: 29px; height: 29px; cursor: pointer"
|
style="width: 29px; height: 29px; cursor: pointer"
|
||||||
src="../../assets/images/basicinfo/close.png"
|
src="../../assets/images/basicinfo/close.png"
|
||||||
@@ -18,10 +18,13 @@
|
|||||||
<div class="main">
|
<div class="main">
|
||||||
<div class="titl">
|
<div class="titl">
|
||||||
<div class="endtime">
|
<div class="endtime">
|
||||||
起止时间:2022-07-21 14:00 ~ 2022-7-30 14:00
|
起止时间:{{
|
||||||
|
datasource && datasource.startTime ? datasource.startTime : "-"
|
||||||
|
}}
|
||||||
|
~
|
||||||
|
{{ datasource && datasource.endTime ? datasource.endTime : "-" }}
|
||||||
</div>
|
</div>
|
||||||
<div class="endtime" style="margin-left: 64px">签到时间:14:00</div>
|
<div class="endtime" style="margin-left: 64px">签到时间:14:00</div>
|
||||||
<div class="endtime" style="margin-left: 40px">签退时间:21:00</div>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="search">
|
<div class="search">
|
||||||
@@ -189,6 +192,7 @@
|
|||||||
import { toRefs, reactive } from "vue";
|
import { toRefs, reactive } from "vue";
|
||||||
import ImpStu from "../../components/drawers/AddLevelImportStu";
|
import ImpStu from "../../components/drawers/AddLevelImportStu";
|
||||||
import SignQR from "./SignQR.vue";
|
import SignQR from "./SignQR.vue";
|
||||||
|
import * as api from "../../api/index1";
|
||||||
export default {
|
export default {
|
||||||
name: "FaceManage",
|
name: "FaceManage",
|
||||||
components: {
|
components: {
|
||||||
@@ -200,6 +204,12 @@ export default {
|
|||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: false,
|
default: false,
|
||||||
},
|
},
|
||||||
|
datasource: {
|
||||||
|
type: Object,
|
||||||
|
default: function () {
|
||||||
|
return {};
|
||||||
|
},
|
||||||
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
setup(props, ctx) {
|
setup(props, ctx) {
|
||||||
@@ -216,7 +226,8 @@ export default {
|
|||||||
closable: false, //modal右上角的关闭按钮
|
closable: false, //modal右上角的关闭按钮
|
||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
currentPage: 1,
|
currentPage: 1,
|
||||||
tableDataTotal: 100,
|
tableDataTotal: -1,
|
||||||
|
tableDataTotal2: 0,
|
||||||
selectedRowKeys: [],
|
selectedRowKeys: [],
|
||||||
projectNameList: [
|
projectNameList: [
|
||||||
{
|
{
|
||||||
@@ -243,129 +254,29 @@ export default {
|
|||||||
projectNameList2: [
|
projectNameList2: [
|
||||||
{
|
{
|
||||||
id: 1,
|
id: 1,
|
||||||
value: "项目一",
|
value: "1",
|
||||||
label: "项目一",
|
label: "正常",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: 2,
|
id: 2,
|
||||||
value: "项目二",
|
value: "2",
|
||||||
label: "项目二",
|
label: "异常",
|
||||||
},
|
|
||||||
{
|
|
||||||
id: 3,
|
|
||||||
value: "项目三",
|
|
||||||
label: "项目三",
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: 4,
|
|
||||||
value: "项目四",
|
|
||||||
label: "项目四",
|
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
tableData: [
|
tableData: [
|
||||||
{
|
// {
|
||||||
key: 1,
|
// key: 1,
|
||||||
name: "张三",
|
// name: "张三",
|
||||||
com: "产研部",
|
// com: "产研部",
|
||||||
gang: "产品经理",
|
// gang: "产品经理",
|
||||||
cur: "-",
|
// cur: "-",
|
||||||
jin: "-",
|
// jin: "-",
|
||||||
time: "缺勤",
|
// time: "缺勤",
|
||||||
state: "异常",
|
// state: "异常",
|
||||||
signIn: false, //签到
|
// signIn: false, //签到
|
||||||
signOut: false, //签退
|
// signOut: false, //签退
|
||||||
leave: false, //请假
|
// leave: false, //请假
|
||||||
},
|
// },
|
||||||
{
|
|
||||||
key: 2,
|
|
||||||
name: "张三",
|
|
||||||
com: "产研部",
|
|
||||||
gang: "产品经理",
|
|
||||||
cur: "2022-10-31 23:12",
|
|
||||||
jin: "-",
|
|
||||||
time: "签到/签退",
|
|
||||||
state: "正常",
|
|
||||||
signIn: true, //签到
|
|
||||||
signOut: true, //签退
|
|
||||||
leave: false, //请假
|
|
||||||
},
|
|
||||||
{
|
|
||||||
key: 3,
|
|
||||||
name: "张三",
|
|
||||||
com: "产研部",
|
|
||||||
gang: "产品经理",
|
|
||||||
cur: "2022-10-31 23:12",
|
|
||||||
jin: "2022-10-31 23:12",
|
|
||||||
time: "迟到",
|
|
||||||
state: "异常",
|
|
||||||
signIn: false, //签到
|
|
||||||
signOut: true, //签退
|
|
||||||
leave: false, //请假
|
|
||||||
},
|
|
||||||
{
|
|
||||||
key: 4,
|
|
||||||
name: "张三",
|
|
||||||
com: "产研部",
|
|
||||||
gang: "产品经理",
|
|
||||||
cur: "2022-10-31 23:12",
|
|
||||||
jin: "2022-10-31 23:12",
|
|
||||||
time: "早退",
|
|
||||||
state: "异常",
|
|
||||||
signIn: true, //签到
|
|
||||||
signOut: false, //签退
|
|
||||||
leave: false, //请假
|
|
||||||
},
|
|
||||||
{
|
|
||||||
key: 5,
|
|
||||||
name: "张三",
|
|
||||||
com: "产研部",
|
|
||||||
gang: "产品经理",
|
|
||||||
cur: "2022-10-31 23:12",
|
|
||||||
jin: "2022-10-31 23:12",
|
|
||||||
time: "签到/签退",
|
|
||||||
state: "正常",
|
|
||||||
signIn: true, //签到
|
|
||||||
signOut: true, //签退
|
|
||||||
leave: false, //请假
|
|
||||||
},
|
|
||||||
{
|
|
||||||
key: 6,
|
|
||||||
name: "张三",
|
|
||||||
com: "产研部",
|
|
||||||
gang: "产品经理",
|
|
||||||
cur: "2022-10-31 23:12",
|
|
||||||
jin: "2022-10-31 23:12",
|
|
||||||
time: "签到/签退",
|
|
||||||
state: "正常",
|
|
||||||
signIn: true, //签到
|
|
||||||
signOut: true, //签退
|
|
||||||
leave: false, //请假
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: "张三",
|
|
||||||
com: "产研部",
|
|
||||||
gang: "产品经理",
|
|
||||||
cur: "2022-10-31 23:12",
|
|
||||||
jin: "2022-10-31 23:12",
|
|
||||||
time: "签到/签退",
|
|
||||||
state: "正常",
|
|
||||||
signIn: true, //签到
|
|
||||||
signOut: true, //签退
|
|
||||||
leave: false, //请假
|
|
||||||
},
|
|
||||||
{
|
|
||||||
key: 8,
|
|
||||||
name: "张三",
|
|
||||||
com: "产研部",
|
|
||||||
gang: "产品经理",
|
|
||||||
cur: "2022-10-31 23:12",
|
|
||||||
jin: "2022-10-31 23:12",
|
|
||||||
time: "请假",
|
|
||||||
state: "正常",
|
|
||||||
signIn: false, //签到
|
|
||||||
signOut: false, //签退
|
|
||||||
leave: true, //请假
|
|
||||||
},
|
|
||||||
],
|
],
|
||||||
tableOptions: [
|
tableOptions: [
|
||||||
{
|
{
|
||||||
@@ -383,30 +294,42 @@ export default {
|
|||||||
],
|
],
|
||||||
// selectOption: [],
|
// selectOption: [],
|
||||||
});
|
});
|
||||||
|
const afterVisibleChange = (bol) => {
|
||||||
|
if (bol == true) {
|
||||||
|
getStudent();
|
||||||
|
}
|
||||||
|
};
|
||||||
|
//考勤
|
||||||
const selectProjectName = (value, index) => {
|
const selectProjectName = (value, index) => {
|
||||||
console.log("value", value, index);
|
console.log("value", value, index);
|
||||||
};
|
};
|
||||||
|
//签到状态
|
||||||
const selectProjectName2 = (value, index) => {
|
const selectProjectName2 = (value, index) => {
|
||||||
console.log("value", value, index);
|
console.log("value", value, index);
|
||||||
};
|
};
|
||||||
const closeDrawer = () => {
|
const closeDrawer = () => {
|
||||||
ctx.emit("update:FSvisible", false);
|
ctx.emit("update:FSvisible", false);
|
||||||
};
|
};
|
||||||
|
//导入学员
|
||||||
const showImpStu = () => {
|
const showImpStu = () => {
|
||||||
state.AddImpStuvisible = true;
|
state.AddImpStuvisible = true;
|
||||||
};
|
};
|
||||||
|
//批量签到
|
||||||
const showCopyModal = () => {
|
const showCopyModal = () => {
|
||||||
state.copyModal = true;
|
state.copyModal = true;
|
||||||
};
|
};
|
||||||
const closeCopyModal = () => {
|
const closeCopyModal = () => {
|
||||||
state.copyModal = false;
|
state.copyModal = false;
|
||||||
};
|
};
|
||||||
const closeStopModal = () => {
|
|
||||||
state.stopModal = false;
|
// const closeStopModal = () => {
|
||||||
};
|
// state.stopModal = false;
|
||||||
|
// };
|
||||||
|
//显示签到二维码弹窗
|
||||||
const signQR = () => {
|
const signQR = () => {
|
||||||
state.signQRvisible = true;
|
state.signQRvisible = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
const onSelectChange = (selectedRowKeys) => {
|
const onSelectChange = (selectedRowKeys) => {
|
||||||
console.log("selectedRowKeys changed: ", selectedRowKeys);
|
console.log("selectedRowKeys changed: ", selectedRowKeys);
|
||||||
state.selectedRowKeys = selectedRowKeys;
|
state.selectedRowKeys = selectedRowKeys;
|
||||||
@@ -454,27 +377,37 @@ export default {
|
|||||||
const columns = [
|
const columns = [
|
||||||
{
|
{
|
||||||
title: "工号",
|
title: "工号",
|
||||||
dataIndex: "com",
|
dataIndex: "studentUserNo",
|
||||||
// width: "30%",
|
// width: "30%",
|
||||||
key: "com",
|
key: "studentUserNo",
|
||||||
width: 50,
|
width: 50,
|
||||||
align: "center",
|
align: "center",
|
||||||
className: "h",
|
className: "h",
|
||||||
|
customRender: (text) => {
|
||||||
|
return (
|
||||||
|
<div class="racona">
|
||||||
|
<span>
|
||||||
|
{text.record.studentUserNo ? text.record.studentUserNo : "-"}
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "姓名",
|
title: "姓名",
|
||||||
dataIndex: "name",
|
dataIndex: "studentName",
|
||||||
// width: "30%",
|
// width: "30%",
|
||||||
key: "name",
|
key: "studentName",
|
||||||
width: 50,
|
width: 50,
|
||||||
align: "left",
|
align: "left",
|
||||||
className: "classify",
|
className: "classify",
|
||||||
scopedSlots: { customRender: "action" }, //引入的插槽
|
scopedSlots: { customRender: "action" }, //引入的插槽
|
||||||
customRender: (text) => {
|
customRender: (text) => {
|
||||||
// console.log(text.record.checked1);
|
|
||||||
return (
|
return (
|
||||||
<div class="racona">
|
<div class="racona">
|
||||||
<span> {text.record.name}</span>
|
<span>
|
||||||
|
{text.record.studentName ? text.record.studentName : "-"}
|
||||||
|
</span>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
@@ -556,6 +489,49 @@ export default {
|
|||||||
];
|
];
|
||||||
return columns;
|
return columns;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
//获取学员
|
||||||
|
const getStudent = () => {
|
||||||
|
console.log("我是传递的查询参数", {
|
||||||
|
pageNo: state.currentPage,
|
||||||
|
pageSize: state.pageSize,
|
||||||
|
currentStageId: props.datasource.chapterId,
|
||||||
|
type: 2,
|
||||||
|
pid: props.datasource.routerId,
|
||||||
|
taskId: props.datasource.routerTaskId,
|
||||||
|
taskType: props.datasource.type,
|
||||||
|
studentName: state.name,
|
||||||
|
});
|
||||||
|
api
|
||||||
|
.AssessmentManagementMessage({
|
||||||
|
pageNo: state.currentPage,
|
||||||
|
pageSize: state.pageSize,
|
||||||
|
currentStageId: props.datasource.chapterId,
|
||||||
|
type: 2,
|
||||||
|
pid: props.datasource.routerId,
|
||||||
|
taskId: props.datasource.routerTaskId,
|
||||||
|
taskType: props.datasource.type,
|
||||||
|
studentName: state.name,
|
||||||
|
})
|
||||||
|
.then((res) => {
|
||||||
|
console.log("获取面授学员", res);
|
||||||
|
if (res.data.code == 200) {
|
||||||
|
let newData = [];
|
||||||
|
for (let i = 0; i < res.data.data.records.length; i++) {
|
||||||
|
res.data.data.records[i].key = res.data.data.records[i].id;
|
||||||
|
newData.push(res.data.data.records[i]);
|
||||||
|
}
|
||||||
|
state.tableData = newData;
|
||||||
|
state.tableDataTotal = res.data.data.total;
|
||||||
|
state.tableDataTotal2 = res.data.data.total;
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.catch((err) => {
|
||||||
|
console.log(err);
|
||||||
|
state.tableData = [];
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
return {
|
return {
|
||||||
...toRefs(state),
|
...toRefs(state),
|
||||||
selectProjectName,
|
selectProjectName,
|
||||||
@@ -567,8 +543,9 @@ export default {
|
|||||||
showImpStu,
|
showImpStu,
|
||||||
showCopyModal,
|
showCopyModal,
|
||||||
closeCopyModal,
|
closeCopyModal,
|
||||||
closeStopModal,
|
// closeStopModal,
|
||||||
signQR,
|
signQR,
|
||||||
|
afterVisibleChange,
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -458,7 +458,7 @@
|
|||||||
:style="{
|
:style="{
|
||||||
display: item.type === 2 ? 'flex' : 'none',
|
display: item.type === 2 ? 'flex' : 'none',
|
||||||
}"
|
}"
|
||||||
@click="showFS"
|
@click="showFS(item)"
|
||||||
>
|
>
|
||||||
学员
|
学员
|
||||||
</div>
|
</div>
|
||||||
@@ -908,7 +908,7 @@
|
|||||||
v-model:studentId="studentId"
|
v-model:studentId="studentId"
|
||||||
/>
|
/>
|
||||||
<!-- 面授学员抽屉 -->
|
<!-- 面授学员抽屉 -->
|
||||||
<face-stu v-model:FSvisible="FSvisible" />
|
<face-stu v-model:FSvisible="FSvisible" :datasource="studentData" />
|
||||||
<!-- 活动考勤抽屉 -->
|
<!-- 活动考勤抽屉 -->
|
||||||
<active-attendance
|
<active-attendance
|
||||||
v-model:AAvisible="AAvisible"
|
v-model:AAvisible="AAvisible"
|
||||||
@@ -1395,6 +1395,8 @@ export default {
|
|||||||
commonLevelName: "",
|
commonLevelName: "",
|
||||||
examLevelName: "",
|
examLevelName: "",
|
||||||
evaluationLevelName: "",
|
evaluationLevelName: "",
|
||||||
|
|
||||||
|
studentData: "",
|
||||||
});
|
});
|
||||||
|
|
||||||
const levelList = reactive({
|
const levelList = reactive({
|
||||||
@@ -1602,8 +1604,10 @@ export default {
|
|||||||
state.copyModal = false;
|
state.copyModal = false;
|
||||||
};
|
};
|
||||||
//面授学员的弹窗
|
//面授学员的弹窗
|
||||||
const showFS = () => {
|
const showFS = (item) => {
|
||||||
state.FSvisible = true;
|
state.FSvisible = true;
|
||||||
|
state.studentData = item;
|
||||||
|
console.log("studentData", state.studentData);
|
||||||
};
|
};
|
||||||
//考勤的抽屉
|
//考勤的抽屉
|
||||||
const showAA = (course) => {
|
const showAA = (course) => {
|
||||||
|
|||||||
Reference in New Issue
Block a user