'考试管理人员管理'
This commit is contained in:
@ -214,10 +214,10 @@
|
|||||||
padding: 10px 20px;
|
padding: 10px 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
::v-deep .el-pagination__total,
|
// ::v-deep .el-pagination__total,
|
||||||
::v-deep .el-pagination__jump {
|
// ::v-deep .el-pagination__jump {
|
||||||
color: #bdc7da;
|
// color: #bdc7da;
|
||||||
}
|
// }
|
||||||
|
|
||||||
::v-deep .el-radio {
|
::v-deep .el-radio {
|
||||||
color: rgb(206, 208, 220);
|
color: rgb(206, 208, 220);
|
||||||
|
|||||||
@ -187,7 +187,7 @@ const handleExceed = (files, fileList) => {
|
|||||||
const beforeImgUpload = (file) => {
|
const beforeImgUpload = (file) => {
|
||||||
if (props.isImg) {
|
if (props.isImg) {
|
||||||
let isIMG = false;
|
let isIMG = false;
|
||||||
if (getSuffix(file.name) === "IMG") {
|
if (getSuffix(file.name) === "IMG" || getSuffix(file.name) === "MUSIC") {
|
||||||
isIMG = true;
|
isIMG = true;
|
||||||
}
|
}
|
||||||
const isLt5M = file.size / 1024 / 1024 < 5;
|
const isLt5M = file.size / 1024 / 1024 < 5;
|
||||||
|
|||||||
@ -8,13 +8,14 @@
|
|||||||
-->
|
-->
|
||||||
<template>
|
<template>
|
||||||
<div class="fenye" :style="{ top: tableHeight + 'px' }">
|
<div class="fenye" :style="{ top: tableHeight + 'px' }">
|
||||||
|
{{ pageData.configer }}
|
||||||
<el-pagination
|
<el-pagination
|
||||||
:current-page="
|
:current-page="
|
||||||
pageData.configer.currentPage ||
|
pageData.configer.currentPage ||
|
||||||
pageData.configer.pageNo ||
|
pageData.configer.pageNo ||
|
||||||
pageData.configer.current ||
|
pageData.configer.current ||
|
||||||
pageData.configer.pageCurrent ||
|
pageData.configer.pageNum ||
|
||||||
pageData.configer.pageNum"
|
pageData.configer.pageCurrent"
|
||||||
:page-size="pageData.configer.pageSize || pageData.configer.size"
|
:page-size="pageData.configer.pageSize || pageData.configer.size"
|
||||||
:page-sizes="pageSizeArr"
|
:page-sizes="pageSizeArr"
|
||||||
:small="small"
|
:small="small"
|
||||||
@ -84,8 +85,8 @@ watchEffect(() => {
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
::v-deep .el-pagination.is-background .btn-next, ::v-deep .el-pagination.is-background .btn-prev, ::v-deep .el-pagination.is-background .el-pager li{
|
// ::v-deep .el-pagination.is-background .btn-next, ::v-deep .el-pagination.is-background .btn-prev, ::v-deep .el-pagination.is-background .el-pager li{
|
||||||
background-color: transparent;
|
// background-color: transparent;
|
||||||
color: white;
|
// color: white;
|
||||||
}
|
// }
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@ -43,7 +43,8 @@ onMounted(() => {
|
|||||||
|
|
||||||
// 路由跳转
|
// 路由跳转
|
||||||
function goToHome() {
|
function goToHome() {
|
||||||
window.location.href = "/";
|
router.push(`/unitInformation`);
|
||||||
|
// window.location.href = "/";
|
||||||
}
|
}
|
||||||
|
|
||||||
const active = ref("");
|
const active = ref("");
|
||||||
|
|||||||
@ -92,15 +92,15 @@ const changeSize = (val) => {
|
|||||||
|
|
||||||
// 获取列表
|
// 获取列表
|
||||||
const getList = () => {
|
const getList = () => {
|
||||||
// pageData.tableConfiger.loading = true;
|
pageData.tableConfiger.loading = true;
|
||||||
// let data = { ...pageData.pageConfiger, ...queryFrom.value };
|
let data = { ...pageData.pageConfiger, ...queryFrom.value };
|
||||||
// qcckGet(data, "/mosty-jbld/jbldzsd/selectPage").then((res) => {
|
qcckPost(data, "/mosty-base/baxx/njpxry/page").then((res) => {
|
||||||
// pageData.tableData = res.records || [];
|
pageData.tableData = res.records || [];
|
||||||
// pageData.total = res.total;
|
pageData.total = res.total;
|
||||||
// pageData.tableConfiger.loading = false;
|
pageData.tableConfiger.loading = false;
|
||||||
// }).catch(() => {
|
}).catch(() => {
|
||||||
// pageData.tableConfiger.loading = false;
|
pageData.tableConfiger.loading = false;
|
||||||
// });
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
@ -125,4 +125,4 @@ const tabHeightFn = () => {
|
|||||||
.el-loading-mask {
|
.el-loading-mask {
|
||||||
background: rgba(0, 0, 0, 0.5) !important;
|
background: rgba(0, 0, 0, 0.5) !important;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@ -18,8 +18,12 @@
|
|||||||
import { qcckPost , qcckGet} from "@/api/qcckApi.js";
|
import { qcckPost , qcckGet} from "@/api/qcckApi.js";
|
||||||
import FormMessage from "@/components/aboutTable/FormMessage.vue";
|
import FormMessage from "@/components/aboutTable/FormMessage.vue";
|
||||||
import { ref, reactive,defineEmits,getCurrentInstance } from 'vue';
|
import { ref, reactive,defineEmits,getCurrentInstance } from 'vue';
|
||||||
|
|
||||||
const emit = defineEmits(["refresh"]);
|
const emit = defineEmits(["refresh"]);
|
||||||
|
|
||||||
const { proxy } = getCurrentInstance();
|
const { proxy } = getCurrentInstance();
|
||||||
|
const { D_BAXX_KTLX } = proxy.dict("D_BAXX_KTLX");
|
||||||
|
|
||||||
const dialogForm = ref(false);
|
const dialogForm = ref(false);
|
||||||
const title = ref('');
|
const title = ref('');
|
||||||
const FormRef = ref();
|
const FormRef = ref();
|
||||||
@ -41,7 +45,7 @@ const rules = reactive({
|
|||||||
|
|
||||||
const formList = reactive([
|
const formList = reactive([
|
||||||
[
|
[
|
||||||
{ label: "题型", prop: "type", type: "select", options: [{label:'单选题',value:'1'},{label:'多选题',value:'2'},{label:'判断题',value:'3'}] },
|
{ label: "题型", prop: "type", type: "select", options: D_BAXX_KTLX },
|
||||||
{ label: "题目", prop: "tm", type: "input" },
|
{ label: "题目", prop: "tm", type: "input" },
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
@ -60,11 +64,11 @@ const formList = reactive([
|
|||||||
|
|
||||||
|
|
||||||
// 初始化数据
|
// 初始化数据
|
||||||
const init = (type, id,) => {
|
const init = (type, row = {}) => {
|
||||||
dialogForm.value = true;
|
dialogForm.value = true;
|
||||||
openType.value = type;
|
openType.value = type;
|
||||||
title.value = type == "add" ? "新增" : "编辑";
|
title.value = type == "add" ? "新增" : "编辑";
|
||||||
if(id) getDateById(id)
|
listQuery.value = { ...row }
|
||||||
};
|
};
|
||||||
|
|
||||||
const save = () => {
|
const save = () => {
|
||||||
|
|||||||
@ -24,8 +24,8 @@
|
|||||||
</template>
|
</template>
|
||||||
<!-- 操作 -->
|
<!-- 操作 -->
|
||||||
<template #controls="{ row }">
|
<template #controls="{ row }">
|
||||||
<el-link type="primary" link @click="addEdit('edit', row.id)">编辑</el-link>
|
<el-link type="primary" link @click="addEdit('edit', row)">编辑</el-link>
|
||||||
<el-link type="primary" link @click="addEdit('detail', row.id)">详情</el-link>
|
<el-link type="primary" link @click="addEdit('detail', row)">详情</el-link>
|
||||||
<el-link type="danger" link @click="handleDelete(row.id)">删除</el-link>
|
<el-link type="danger" link @click="handleDelete(row.id)">删除</el-link>
|
||||||
</template>
|
</template>
|
||||||
</MyTable>
|
</MyTable>
|
||||||
@ -114,7 +114,7 @@ const changeSize = (val) => {
|
|||||||
const getList = () => {
|
const getList = () => {
|
||||||
pageData.tableConfiger.loading = true;
|
pageData.tableConfiger.loading = true;
|
||||||
let data = { ...pageData.pageConfiger, ...queryFrom.value };
|
let data = { ...pageData.pageConfiger, ...queryFrom.value };
|
||||||
qcckGet(data, "/mosty-base/baxx/tkgl/page").then((res) => {
|
qcckPost(data, "/mosty-base/baxx/tkgl/page").then((res) => {
|
||||||
pageData.tableData = res.records || [];
|
pageData.tableData = res.records || [];
|
||||||
pageData.total = res.total;
|
pageData.total = res.total;
|
||||||
pageData.tableConfiger.loading = false;
|
pageData.tableConfiger.loading = false;
|
||||||
@ -135,9 +135,9 @@ const handleDelete = (ids) => {
|
|||||||
};
|
};
|
||||||
|
|
||||||
// 详情
|
// 详情
|
||||||
const addEdit = (type, id) => {
|
const addEdit = (type, row) => {
|
||||||
nextTick(() => {
|
nextTick(() => {
|
||||||
detailDiloag.value.init(type, id);
|
detailDiloag.value.init(type, row);
|
||||||
})
|
})
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@ -26,12 +26,15 @@ const FormRef = ref();
|
|||||||
const loading = ref(false);
|
const loading = ref(false);
|
||||||
const listQuery = ref({});
|
const listQuery = ref({});
|
||||||
const openType = ref("")
|
const openType = ref("")
|
||||||
|
|
||||||
|
const { D_PXDG_PXLX } = proxy.$dict("D_PXDG_PXLX")
|
||||||
|
|
||||||
const rules = reactive({
|
const rules = reactive({
|
||||||
pxlx: [{ required: true, message: "请输入视频标题", trigger: "blur" }],
|
pxlx: [{ required: true, message: "请输入视频标题", trigger: "blur" }],
|
||||||
});
|
});
|
||||||
const formList = reactive([
|
const formList = reactive([
|
||||||
[
|
[
|
||||||
{ label: "培训类型", prop: "pxlx", type: "input" },
|
{ label: "培训类型", prop: "pxlx", type: "select", options: D_PXDG_PXLX },
|
||||||
{ label: "教学项目", prop: "jxxm", type: "input" },
|
{ label: "教学项目", prop: "jxxm", type: "input" },
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
|
|||||||
@ -45,14 +45,17 @@ import Search from "@/components/aboutTable/Search.vue";
|
|||||||
import DetailForm from "./components/detailForm.vue";
|
import DetailForm from "./components/detailForm.vue";
|
||||||
import { qcckGet, qcckPost, qcckDelete } from "@/api/qcckApi.js";
|
import { qcckGet, qcckPost, qcckDelete } from "@/api/qcckApi.js";
|
||||||
import { reactive, ref, onMounted, getCurrentInstance, nextTick } from "vue";
|
import { reactive, ref, onMounted, getCurrentInstance, nextTick } from "vue";
|
||||||
|
|
||||||
const { proxy } = getCurrentInstance();
|
const { proxy } = getCurrentInstance();
|
||||||
|
const { D_PXDG_PXLX } = proxy.$dict("D_PXDG_PXLX")
|
||||||
|
|
||||||
const detailDiloag = ref();
|
const detailDiloag = ref();
|
||||||
const searchBox = ref(); //搜索框
|
const searchBox = ref(); //搜索框
|
||||||
const baseUrl = 'data:image/jpeg;base64,'
|
const baseUrl = 'data:image/jpeg;base64,'
|
||||||
const searchConfiger = ref([
|
const searchConfiger = ref([
|
||||||
{
|
{
|
||||||
label: "教学项目",
|
label: "教学项目",
|
||||||
prop: "questionContent",
|
prop: "jxxm",
|
||||||
placeholder: "请输入教学项目",
|
placeholder: "请输入教学项目",
|
||||||
showType: "input"
|
showType: "input"
|
||||||
},
|
},
|
||||||
@ -74,8 +77,8 @@ const pageData = reactive({
|
|||||||
},
|
},
|
||||||
controlsWidth: 180,
|
controlsWidth: 180,
|
||||||
tableColumn: [
|
tableColumn: [
|
||||||
{ label: "培训类型", prop: "questionType"},
|
{ label: "培训类型", prop: "pxlx", options: D_PXDG_PXLX },
|
||||||
{ label: "教学项目", prop: "questionContent" },
|
{ label: "教学项目", prop: "jxxm" },
|
||||||
]
|
]
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -102,15 +105,15 @@ const changeSize = (val) => {
|
|||||||
|
|
||||||
// 获取列表
|
// 获取列表
|
||||||
const getList = () => {
|
const getList = () => {
|
||||||
// pageData.tableConfiger.loading = true;
|
pageData.tableConfiger.loading = true;
|
||||||
// let data = { ...pageData.pageConfiger, ...queryFrom.value };
|
let data = { ...pageData.pageConfiger, ...queryFrom.value };
|
||||||
// qcckGet(data, "/mosty-jbld/jbldzsd/selectPage").then((res) => {
|
qcckPost(data, "/mosty-base/baxx/jxda/page").then((res) => {
|
||||||
// pageData.tableData = res.records || [];
|
pageData.tableData = res.records || [];
|
||||||
// pageData.total = res.total;
|
pageData.total = res.total;
|
||||||
// pageData.tableConfiger.loading = false;
|
pageData.tableConfiger.loading = false;
|
||||||
// }).catch(() => {
|
}).catch(() => {
|
||||||
// pageData.tableConfiger.loading = false;
|
pageData.tableConfiger.loading = false;
|
||||||
// });
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
@ -145,4 +148,4 @@ const tabHeightFn = () => {
|
|||||||
.el-loading-mask {
|
.el-loading-mask {
|
||||||
background: rgba(0, 0, 0, 0.5) !important;
|
background: rgba(0, 0, 0, 0.5) !important;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@ -10,9 +10,11 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import { computed, ref, reactive } from 'vue';
|
import { computed, ref, reactive, getCurrentInstance } from 'vue';
|
||||||
|
import { qcckPost } from "@/api/qcckApi.js";
|
||||||
import FormMessage from '@/components/aboutTable/FormMessage.vue'
|
import FormMessage from '@/components/aboutTable/FormMessage.vue'
|
||||||
|
|
||||||
|
const { proxy } = getCurrentInstance()
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
modelValue: {
|
modelValue: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
@ -20,7 +22,7 @@ const props = defineProps({
|
|||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|
||||||
const emits = defineEmits(['update:modelValue'])
|
const emits = defineEmits(['update:modelValue', 'refresh'])
|
||||||
|
|
||||||
const visible = computed({
|
const visible = computed({
|
||||||
get() {
|
get() {
|
||||||
@ -39,16 +41,16 @@ const formData = ref({})
|
|||||||
|
|
||||||
const formList = reactive([
|
const formList = reactive([
|
||||||
[
|
[
|
||||||
{ label: "成绩", prop: "cj", type: "input" },
|
{ label: "成绩", prop: "ksfs", type: "input" },
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
{ label: "卷面", prop: "jm", type: "upload", limit: 1 },
|
{ label: "卷面", prop: "kszp", type: "upload", limit: 3 },
|
||||||
],
|
],
|
||||||
])
|
])
|
||||||
|
|
||||||
const rules = {
|
const rules = {
|
||||||
cj: [{ required: true, message: "请输入考试成绩", trigger: "change" }],
|
ksfs: [{ required: true, message: "请输入考试成绩", trigger: "change" }],
|
||||||
jm: [{ required: true, message: "请输上传卷面", trigger: "change" }],
|
kszp: [{ required: true, message: "请输上传卷面", trigger: "change" }],
|
||||||
}
|
}
|
||||||
|
|
||||||
const open = (row = {}, type = 'updata') => {
|
const open = (row = {}, type = 'updata') => {
|
||||||
@ -68,15 +70,18 @@ const handleClose = () => {
|
|||||||
visible.value = false
|
visible.value = false
|
||||||
}
|
}
|
||||||
|
|
||||||
const handleSubmit = () => {
|
const handleSubmit = async () => {
|
||||||
try {
|
try {
|
||||||
loading.value = true
|
loading.value = true
|
||||||
FormRef.value.submit(res => {
|
await FormRef.value.submit()
|
||||||
console.log(res)
|
const { pxryid = "" } = formData.value
|
||||||
visible.value = false
|
await qcckPost({ ...formData.value, pxryid }, `mosty/base/baxx/pxry/lrcj`)
|
||||||
})
|
proxy.$message.success('上传成绩成功')
|
||||||
|
emits('refresh')
|
||||||
|
visible.value = false
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.log(error)
|
console.log(error)
|
||||||
|
proxy.$message.error('上传成绩失败')
|
||||||
} finally {
|
} finally {
|
||||||
loading.value = false
|
loading.value = false
|
||||||
}
|
}
|
||||||
|
|||||||
@ -15,7 +15,9 @@
|
|||||||
<el-descriptions-item label="考试辖区">{{ formData.ksxq }}</el-descriptions-item>
|
<el-descriptions-item label="考试辖区">{{ formData.ksxq }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="考试地址">{{ formData.ksdz }}</el-descriptions-item>
|
<el-descriptions-item label="考试地址">{{ formData.ksdz }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="监考民警">{{ formData.jkmj }}</el-descriptions-item>
|
<el-descriptions-item label="监考民警">{{ formData.jkmj }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="考试方式">{{ formData.ksfs }}</el-descriptions-item>
|
<el-descriptions-item label="考试方式">
|
||||||
|
<DictTag :value="formData.ksfs" :options="D_BAXX_KSFS" />
|
||||||
|
</el-descriptions-item>
|
||||||
</el-descriptions>
|
</el-descriptions>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -26,7 +28,7 @@
|
|||||||
>
|
>
|
||||||
<!-- 操作 -->
|
<!-- 操作 -->
|
||||||
<template #controls="{ row }">
|
<template #controls="{ row }">
|
||||||
<el-link v-if="!visible">申请证件</el-link>
|
<el-link v-if="!visible" @click="handleCertificate(row)">申请证件</el-link>
|
||||||
<template v-else>
|
<template v-else>
|
||||||
<el-link type="primary" @click="addEdit('updata', row)">上传成绩</el-link>
|
<el-link type="primary" @click="addEdit('updata', row)">上传成绩</el-link>
|
||||||
<el-link type="primary" @click="addEdit('view', row)">查看成绩</el-link>
|
<el-link type="primary" @click="addEdit('view', row)">查看成绩</el-link>
|
||||||
@ -35,7 +37,7 @@
|
|||||||
</MyTable>
|
</MyTable>
|
||||||
<!-- </el-descriptions> -->
|
<!-- </el-descriptions> -->
|
||||||
|
|
||||||
<view-and-upload-dialog ref="viewAndUploadRef" v-model="viewAndUploadVisible" />
|
<view-and-upload-dialog ref="viewAndUploadRef" v-model="viewAndUploadVisible" @refresh="getList" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
@ -47,6 +49,7 @@ import MyTable from '@/components/aboutTable/MyTable.vue';
|
|||||||
import viewAndUploadDialog from './viewAndUploadDialog.vue';
|
import viewAndUploadDialog from './viewAndUploadDialog.vue';
|
||||||
|
|
||||||
const { proxy } = getCurrentInstance()
|
const { proxy } = getCurrentInstance()
|
||||||
|
const { D_BAXX_KSFS } = proxy.$dict("D_BAXX_KSFS")
|
||||||
const title = ref('保安线下考试详情')
|
const title = ref('保安线下考试详情')
|
||||||
const loading = ref(false)
|
const loading = ref(false)
|
||||||
const disabled = ref(false)
|
const disabled = ref(false)
|
||||||
@ -66,7 +69,7 @@ const props = defineProps({
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
const emits = defineEmits(['update:modelValue'])
|
const emits = defineEmits(['update:modelValue', 'refresh'])
|
||||||
|
|
||||||
const dialogVisible = computed({
|
const dialogVisible = computed({
|
||||||
get() {
|
get() {
|
||||||
@ -107,7 +110,21 @@ const close = () => {
|
|||||||
dialogVisible.value = false
|
dialogVisible.value = false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 根据项目id获取培训人员
|
||||||
|
const getList = async ({ id = "" }) => {
|
||||||
|
const res = await qcckPost({
|
||||||
|
...pageData.pageConfiger,
|
||||||
|
sfcjpx: 1,
|
||||||
|
pxxmid: id
|
||||||
|
}, `/mosty-base/baxx/pxry/page`)
|
||||||
|
if (res) {
|
||||||
|
pageData.tableData = res.records || [];
|
||||||
|
pageData.total = res.total;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
const open = (row = {}, type = 'add') => {
|
const open = (row = {}, type = 'add') => {
|
||||||
|
getList(row)
|
||||||
disabled.value = false
|
disabled.value = false
|
||||||
dialogVisible.value = true
|
dialogVisible.value = true
|
||||||
formData.value = { ...row }
|
formData.value = { ...row }
|
||||||
@ -139,6 +156,18 @@ const addEdit = (type, row) => {
|
|||||||
viewAndUploadRef.value?.open(row, type)
|
viewAndUploadRef.value?.open(row, type)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 申请保安证
|
||||||
|
const handleCertificate = async ({ pxryid = ''}) => {
|
||||||
|
try {
|
||||||
|
await qcckPost({ id: pxryid }, `/mosty-base/baxx/pxry/sqzj`)
|
||||||
|
proxy.$message.success("申请证件成功")
|
||||||
|
emits("refresh");
|
||||||
|
close();
|
||||||
|
} catch (error) {
|
||||||
|
proxy.$message.success("申请证件失败")
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
defineExpose({ open })
|
defineExpose({ open })
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@ -111,7 +111,7 @@ const getList = async () => {
|
|||||||
}, `/mosty-base/baxx/ksgl/page`)
|
}, `/mosty-base/baxx/ksgl/page`)
|
||||||
|
|
||||||
if(res) {
|
if(res) {
|
||||||
pageData.tableData = res.records || [];
|
pageData.tableData = [{}];
|
||||||
pageData.total = res.total;
|
pageData.total = res.total;
|
||||||
}
|
}
|
||||||
} finally {
|
} finally {
|
||||||
|
|||||||
@ -9,10 +9,8 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="cntinfo">
|
<div class="cntinfo">
|
||||||
<FormMessage ref="FormRef" :disabled="disabled" v-model="formData" :rules="rules" :formList="formList" :labelWidth='120'>
|
<FormMessage ref="FormRef" :disabled="disabled" v-model="formData" :rules="rules" :formList="formList" :labelWidth='120'>
|
||||||
<!-- <template #zb>
|
<!-- <template #xtCjsj>
|
||||||
<el-input v-model="formData.zb" placeholder="请选择巡逻路线">
|
<el-input v-model="formData.xtCjsj" placeholder="请输入申请时间" />
|
||||||
<template #append><el-button type="primary" @click="chackLat">开始绘制</el-button></template>
|
|
||||||
</el-input>
|
|
||||||
</template> -->
|
</template> -->
|
||||||
</FormMessage>
|
</FormMessage>
|
||||||
</div>
|
</div>
|
||||||
@ -76,6 +74,10 @@ const formList = reactive([
|
|||||||
])
|
])
|
||||||
|
|
||||||
const rules = {
|
const rules = {
|
||||||
|
ryzpzm: [{ required: true, message: "请上传身份证正面", trigger: "change" }],
|
||||||
|
ryzpfm: [{ required: true, message: "请上传身份证反面", trigger: "change" }],
|
||||||
|
// tjbj: [{ required: true, message: "请上传体检报告", trigger: "change" }],
|
||||||
|
wfzzmjl: [{ required: true, message: "请上传无犯罪记录证明", trigger: "change" }],
|
||||||
xm: [{ required: true, message: "请输入姓名", trigger: "change" }],
|
xm: [{ required: true, message: "请输入姓名", trigger: "change" }],
|
||||||
zjhm: [
|
zjhm: [
|
||||||
{ required: true, message: "请输入证件号码", trigger: "change" },
|
{ required: true, message: "请输入证件号码", trigger: "change" },
|
||||||
@ -124,6 +126,7 @@ const close = () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const open = (row = {}, type = 'add') => {
|
const open = (row = {}, type = 'add') => {
|
||||||
|
FormRef.value?.reset()
|
||||||
disabled.value = false
|
disabled.value = false
|
||||||
dialogVisible.value = true
|
dialogVisible.value = true
|
||||||
formData.value = { ...row }
|
formData.value = { ...row }
|
||||||
|
|||||||
@ -14,6 +14,10 @@
|
|||||||
<template #bxxLx="{ row }">
|
<template #bxxLx="{ row }">
|
||||||
<DictTag :value="row.bxxLx" :tag="false" :options="D_BZ_BXDLX" />
|
<DictTag :value="row.bxxLx" :tag="false" :options="D_BZ_BXDLX" />
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
<template #pxsc="{ row }">
|
||||||
|
<span>{{ row.pxsc }}小时</span>
|
||||||
|
</template>
|
||||||
<!-- 操作 -->
|
<!-- 操作 -->
|
||||||
<template #controls="{ row }">
|
<template #controls="{ row }">
|
||||||
<el-link type="danger" @click="handleDelete([row.id])">删除</el-link>
|
<el-link type="danger" @click="handleDelete([row.id])">删除</el-link>
|
||||||
|
|||||||
@ -93,6 +93,7 @@ const close = () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const open = (row = {}, type = 'add') => {
|
const open = (row = {}, type = 'add') => {
|
||||||
|
FormRef.value?.reset()
|
||||||
disabled.value = false
|
disabled.value = false
|
||||||
dialogVisible.value = true
|
dialogVisible.value = true
|
||||||
formData.value = { ...row }
|
formData.value = { ...row }
|
||||||
|
|||||||
@ -39,37 +39,38 @@
|
|||||||
</el-row>
|
</el-row>
|
||||||
<el-divider />
|
<el-divider />
|
||||||
<!-- 人员 -->
|
<!-- 人员 -->
|
||||||
<el-row class="peoRow" v-for="(item, index) in formData.courceList" :key="index">
|
<el-row class="peoRow" v-for="(item, index) in formData.pxkcList" :key="index">
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="培训日期" :prop="`courceList[${index}].pxrq`" style="width: 100%;" :rules="rules.pxrq">
|
<el-form-item label="培训日期" :prop="`pxkcList[${index}].pxrq`" style="width: 100%;" :rules="rules.pxrq">
|
||||||
<el-date-picker v-model="item.pxrq" type="date" value-format="YYYY-MM-DD" placeholder="请输入培训日期" style="width: 100%;" />
|
<el-date-picker v-model="item.pxrq" type="date" value-format="YYYY-MM-DD" placeholder="请输入培训日期" style="width: 100%;" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="培训时间" prop="pxsj" style="width: 100%;">
|
<el-form-item label="培训时间" :prop="`pxkcList[${index}].pxsj`" style="width: 100%;" :rules="rules.pxsj">
|
||||||
<el-time-picker v-model="item.pxsj" value-format="HH:mm:ss" placeholder="请输入培训时间" style="width: 100%;" is-range range-separator="To" start-placeholder="开始时间" end-placeholder="结束时间"/>
|
<el-date-picker v-model="item.pxsj" placeholder="请选择培训开始时间" type="datetime" value-format="YYYY-MM-DD HH:mm:ss"/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="课程名称" :prop="`courceList[${index}].kcmc`" style="width: 100%;" :rules="rules.kcmc">
|
<el-form-item label="课程名称" :prop="`pxkcList[${index}].kcmc`" style="width: 100%;" :rules="rules.kcmc">
|
||||||
<el-input v-model="item.kcmc" placeholder="请输入课程名称" style="width: 100%;"></el-input>
|
<el-input v-model="item.kcmc" placeholder="请输入课程名称" style="width: 100%;"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="组织单位" :prop="`courceList[${index}].zzdw`" style="width: 100%;" :rules="rules.zzdw">
|
<el-form-item label="组织单位" :prop="`pxkcList[${index}].zzdw`" style="width: 100%;" :rules="rules.zzdw">
|
||||||
<el-input v-model="item.zzdw" placeholder="请输入组织单位" style="width: 100%;"></el-input>
|
<el-input v-model="item.zzdw" placeholder="请输入组织单位" style="width: 100%;"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="授课教员" :prop="`courceList[${index}].skjy`" style="width: 100%;" :rules="rules.skjy">
|
<el-form-item label="授课教员" :prop="`pxkcList[${index}].skjy`" style="width: 100%;" :rules="rules.skjy">
|
||||||
<el-select v-model="item.skjy" placeholder="请选择授课教员" style="width: 100%;">
|
<el-input v-model="item.skjy" placeholder="请选择授课教员" style="width: 100%;"></el-input>
|
||||||
|
<!-- <el-select v-model="item.skjy" placeholder="请选择授课教员" style="width: 100%;">
|
||||||
<el-option label="张三" value="张三"></el-option>
|
<el-option label="张三" value="张三"></el-option>
|
||||||
<el-option label="李四" value="李四"></el-option>
|
<el-option label="李四" value="李四"></el-option>
|
||||||
</el-select>
|
</el-select> -->
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="培训内容" :prop="`courceList[${index}].pxnc`" style="width: 100%;" :rules="rules.pxnr">
|
<el-form-item label="培训内容" :prop="`pxkcList[${index}].pxnr`" style="width: 100%;" :rules="rules.pxnr">
|
||||||
<el-input v-model="item.pxnr" placeholder="请输入培训内容" style="width: 100%;"></el-input>
|
<el-input v-model="item.pxnr" placeholder="请输入培训内容" style="width: 100%;"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
@ -81,15 +82,19 @@
|
|||||||
<el-button type="primary" @click="addItem">新增课程</el-button>
|
<el-button type="primary" @click="addItem">新增课程</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-form>
|
</el-form>
|
||||||
<div class="table-title">培训保安人员 <el-icon size="20px" style="top: 4px;" color="green"><CirclePlusFilled /></el-icon> </div>
|
<div class="table-title" @click="hanbleClickSelect">培训保安人员 <el-icon size="20px" style="top: 4px;" color="green"><CirclePlusFilled /></el-icon> </div>
|
||||||
<MyTable :tableData="pageData.tableData" :tableColumn="pageData.tableColumn" :key="pageData.keyCount" :tableConfiger="pageData.tableConfiger" :controlsWidth="pageData.controlsWidth">
|
<MyTable :tableData="pageData.tableData" :tableColumn="pageData.tableColumn" :key="pageData.keyCount" :tableConfiger="pageData.tableConfiger" :controlsWidth="pageData.controlsWidth">
|
||||||
<!-- 操作 -->
|
<template #pxsc="{ row }">
|
||||||
<template #controls="{ row }">
|
<span>{{ row.pxsc }}h</span>
|
||||||
<el-link type="warning" @click="addEdit('updata', row)">删除</el-link>
|
</template>
|
||||||
</template>
|
<!-- 操作 -->
|
||||||
|
<template #controls="{ row }">
|
||||||
|
<el-link type="warning" @click="handleDelItem(row)">删除</el-link>
|
||||||
|
</template>
|
||||||
</MyTable>
|
</MyTable>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<select-personnel-dialog ref="selectPersonnelRef" v-model="visible" @change="handleChange" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -97,9 +102,13 @@
|
|||||||
import { qcckPost } from "@/api/qcckApi.js";
|
import { qcckPost } from "@/api/qcckApi.js";
|
||||||
import MyTable from '@/components/aboutTable/MyTable.vue';
|
import MyTable from '@/components/aboutTable/MyTable.vue';
|
||||||
import { ref, computed, reactive, getCurrentInstance } from 'vue'
|
import { ref, computed, reactive, getCurrentInstance } from 'vue'
|
||||||
|
import SelectPersonnelDialog from "./selectPersonnelDialog.vue";
|
||||||
|
|
||||||
|
const { proxy } = getCurrentInstance()
|
||||||
|
const visible = ref(false)
|
||||||
const showDialog = ref(false)
|
const showDialog = ref(false)
|
||||||
const formData = ref({
|
const formData = ref({
|
||||||
courceList: [{
|
pxkcList: [{
|
||||||
pxkcxm: '', //课程名称
|
pxkcxm: '', //课程名称
|
||||||
pxzcdw: '', //组织单位
|
pxzcdw: '', //组织单位
|
||||||
pxfcy: '', //授课教员
|
pxfcy: '', //授课教员
|
||||||
@ -107,9 +116,10 @@ const formData = ref({
|
|||||||
}] //课程
|
}] //课程
|
||||||
})
|
})
|
||||||
|
|
||||||
|
const emits = defineEmits(['refresh'])
|
||||||
const FormRef = ref(null)
|
const FormRef = ref(null)
|
||||||
const pageData = reactive({
|
const pageData = reactive({
|
||||||
tableData: [{xm: '张三', sfzh: '123456789012345678', lxdh: '13800000000'}],
|
tableData: [],
|
||||||
keyCount: 0,
|
keyCount: 0,
|
||||||
tableConfiger: {
|
tableConfiger: {
|
||||||
rowHieght: 61,
|
rowHieght: 61,
|
||||||
@ -126,8 +136,8 @@ const pageData = reactive({
|
|||||||
{ label: "姓名", prop: "xm" },
|
{ label: "姓名", prop: "xm" },
|
||||||
{ label: "证件号码", prop: "sfzh" },
|
{ label: "证件号码", prop: "sfzh" },
|
||||||
{ label: "联系号码", prop: "lxdh" },
|
{ label: "联系号码", prop: "lxdh" },
|
||||||
{ label: "线上培训时长", prop: "sfzh" },
|
{ label: "线上培训时长", prop: "pxsc", showSolt: true },
|
||||||
{ label: "所属单位", prop: "lxdh" },
|
{ label: "所属单位", prop: "lxdw" },
|
||||||
]
|
]
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -141,11 +151,17 @@ const rules = {
|
|||||||
kcmc: [{ required: true, message: "请输入课程名称", trigger: "change" }],
|
kcmc: [{ required: true, message: "请输入课程名称", trigger: "change" }],
|
||||||
zzdw: [{ required: true, message: "请输入组织单位", trigger: "change" }],
|
zzdw: [{ required: true, message: "请输入组织单位", trigger: "change" }],
|
||||||
skjy: [{ required: true, message: "请选择授课教员", trigger: "change" }],
|
skjy: [{ required: true, message: "请选择授课教员", trigger: "change" }],
|
||||||
pxnr: [{ required: true, message: "请输入培训内容", trigger: "change" }]
|
pxnr: [{ required: true, message: "请输入培训内容", trigger: "change" }],
|
||||||
|
pxsj: [{ required: true, message: "请选择培训开始时间", trigger: "change" }],
|
||||||
|
}
|
||||||
|
|
||||||
|
const selectPersonnelRef = ref(null)
|
||||||
|
const hanbleClickSelect = () => {
|
||||||
|
selectPersonnelRef.value?.open()
|
||||||
}
|
}
|
||||||
|
|
||||||
const addItem = () => {
|
const addItem = () => {
|
||||||
formData.value.courceList.push({
|
formData.value.pxkcList.push({
|
||||||
pxkcxm: '', //课程名称
|
pxkcxm: '', //课程名称
|
||||||
pxzcdw: '', //组织单位
|
pxzcdw: '', //组织单位
|
||||||
pxfcy: '', //授课教员
|
pxfcy: '', //授课教员
|
||||||
@ -154,21 +170,39 @@ const addItem = () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const delItem = (item,index) => {
|
const delItem = (item,index) => {
|
||||||
if(formData.value.courceList.length === 1) return proxy.$message.error('请至少添加一门课程');
|
if(formData.value.pxkcList.length === 1) return proxy.$message.error('请至少添加一门课程');
|
||||||
formData.value.courceList.splice(index,1)
|
formData.value.pxkcList.splice(index,1)
|
||||||
}
|
}
|
||||||
|
|
||||||
const init = () => {
|
const init = () => {
|
||||||
showDialog.value = true
|
showDialog.value = true
|
||||||
}
|
}
|
||||||
|
|
||||||
const close = () => {
|
const close = () => {
|
||||||
showDialog.value = false
|
FormRef.value.resetFields()
|
||||||
|
showDialog.value = false
|
||||||
}
|
}
|
||||||
|
|
||||||
const save = async () => {
|
const handleDelItem = (row) => {
|
||||||
FormRef.value.validate((valid) => {
|
const index = pageData.tableData.findIndex(item => item.id === row.id)
|
||||||
|
pageData.tableData.splice(index, 1)
|
||||||
|
}
|
||||||
|
|
||||||
|
const handleChange = (val) => {
|
||||||
|
pageData.tableData = [...pageData.tableData, ...val]?.filter((i, index, arr) => arr?.findIndex(s => i?.id === s?.id) === index)
|
||||||
|
}
|
||||||
|
|
||||||
|
const save = () => {
|
||||||
|
if (pageData.tableData.length === 0) return proxy.$message.warning('请选择培训保安人员')
|
||||||
|
const ryidList = pageData.tableData?.map(i => i?.id)
|
||||||
|
const { pxkcList, pxxmid } = formData.value
|
||||||
|
FormRef.value.validate( async (valid) => {
|
||||||
|
const url = !formData.value?.id ? `/mosty-base/baxx/pxxm/add` : `/mosty-base/baxx/pxxm/edit`
|
||||||
|
const res = await qcckPost(formData.value, url)
|
||||||
|
await qcckPost({ pxkcList, pxxmid: res?.id, ryidList }, !formData.value?.id ? `/mosty-base/baxx/pxkc/saveList` : `/mosty-base/baxx/pxkc/updateList`)
|
||||||
|
proxy.$message.success('新增培训项目成功')
|
||||||
|
emits("refresh");
|
||||||
|
close()
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -16,22 +16,23 @@
|
|||||||
<el-descriptions-item label="培训结束时间">{{ formData.jssj }}</el-descriptions-item>
|
<el-descriptions-item label="培训结束时间">{{ formData.jssj }}</el-descriptions-item>
|
||||||
</el-descriptions>
|
</el-descriptions>
|
||||||
|
|
||||||
<el-descriptions column="2" border class="label" label-width="120px">
|
<template v-for="item in pageData.pxkcList" :key="item.id">
|
||||||
<el-descriptions-item label="培训日期">{{ courseInfo.pxrq }}</el-descriptions-item>
|
<el-descriptions column="2" border class="label" label-width="120px">
|
||||||
<el-descriptions-item label="培训时间">{{ courseInfo.pxsj }}</el-descriptions-item>
|
<el-descriptions-item label="培训日期">{{ item.pxrq }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="课程名称">{{ courseInfo.kcmc }}</el-descriptions-item>
|
<el-descriptions-item label="培训时间">{{ item.pxsj }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="组织单位">{{ courseInfo.zzdw }}</el-descriptions-item>
|
<el-descriptions-item label="课程名称">{{ item.kcmc }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="授课教员">{{ courseInfo.skjy }}</el-descriptions-item>
|
<el-descriptions-item label="组织单位">{{ item.zzdw }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="培训内容">{{ courseInfo.pxnr }}</el-descriptions-item>
|
<el-descriptions-item label="授课教员">{{ item.skjy }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="已培训人员" :span="2">{{ courseInfo.ypxry }}</el-descriptions-item>
|
<el-descriptions-item label="培训内容">{{ item.pxnr }}</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="已培训人员" :span="2">{{ item.ypxry }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="培训照片" :span="2">
|
<el-descriptions-item label="培训照片" :span="2">
|
||||||
<div class="imgWrapper">
|
<div class="imgWrapper">
|
||||||
<Upload v-model="courseInfo.pxzp" />
|
<Upload v-model="item.pxzp" />
|
||||||
</div>
|
</div>
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
</el-descriptions>
|
</el-descriptions>
|
||||||
|
</template>
|
||||||
|
|
||||||
<!-- <el-descriptions title="考试人员" column="2" border class="mt20"> -->
|
|
||||||
<div class="label">培训保安人员</div>
|
<div class="label">培训保安人员</div>
|
||||||
<MyTable :tableData="pageData.tableData" :tableColumn="pageData.tableColumn"
|
<MyTable :tableData="pageData.tableData" :tableColumn="pageData.tableColumn"
|
||||||
:key="pageData.keyCount" :tableConfiger="pageData.tableConfiger" :controlsWidth="pageData.controlsWidth"
|
:key="pageData.keyCount" :tableConfiger="pageData.tableConfiger" :controlsWidth="pageData.controlsWidth"
|
||||||
@ -41,7 +42,10 @@
|
|||||||
<el-link type="warning" @click="addEdit('updata', row)">删除</el-link>
|
<el-link type="warning" @click="addEdit('updata', row)">删除</el-link>
|
||||||
</template>
|
</template>
|
||||||
</MyTable>
|
</MyTable>
|
||||||
<!-- </el-descriptions> -->
|
<Pages @changeNo="changeNo" @changeSize="changeSize" :tableHeight="pageData.tableHeight" :pageConfiger="{
|
||||||
|
...pageData.pageConfiger,
|
||||||
|
total: pageData.total
|
||||||
|
}" />
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -51,6 +55,7 @@
|
|||||||
import { ref, computed, reactive, getCurrentInstance } from 'vue'
|
import { ref, computed, reactive, getCurrentInstance } from 'vue'
|
||||||
import { qcckPost } from "@/api/qcckApi.js";
|
import { qcckPost } from "@/api/qcckApi.js";
|
||||||
import MyTable from '@/components/aboutTable/MyTable.vue';
|
import MyTable from '@/components/aboutTable/MyTable.vue';
|
||||||
|
import Pages from "@/components/aboutTable/Pages.vue"
|
||||||
import Upload from "@/components/MyComponents/Upload/index.vue"
|
import Upload from "@/components/MyComponents/Upload/index.vue"
|
||||||
|
|
||||||
const { proxy } = getCurrentInstance()
|
const { proxy } = getCurrentInstance()
|
||||||
@ -83,7 +88,8 @@ const dialogVisible = computed({
|
|||||||
})
|
})
|
||||||
|
|
||||||
const pageData = reactive({
|
const pageData = reactive({
|
||||||
tableData: [{}],
|
tableData: [],
|
||||||
|
pxkcList: [],
|
||||||
keyCount: 0,
|
keyCount: 0,
|
||||||
tableConfiger: {
|
tableConfiger: {
|
||||||
haveControls: false,
|
haveControls: false,
|
||||||
@ -113,14 +119,36 @@ const close = () => {
|
|||||||
dialogVisible.value = false
|
dialogVisible.value = false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 根据项目id获取培训课程
|
||||||
|
const getPxkcList = async ({ id }) => {
|
||||||
|
const res = await qcckPost({ pxxmid: id }, `/mosty-base/baxx/pxkc/list`)
|
||||||
|
if (res) {
|
||||||
|
pageData.pxkcList = res
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// 获取保安信息培训课程管理详情
|
// 获取保安信息培训课程管理详情
|
||||||
const getbaInfo = async () => {
|
const getbaInfo = async ({ id = '' }) => {
|
||||||
const res = await qcckPost({}, `/mosty-base/baxx/pxkc/getInfo/${id}`)
|
const res = await qcckPost({ id }, `/mosty-base/baxx/pxkc/getInfo/${id}`)
|
||||||
if (res) {
|
if (res) {
|
||||||
courseInfo.value = res
|
courseInfo.value = res
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 根据项目id获取培训人员
|
||||||
|
const getList = async ({ id = "" }) => {
|
||||||
|
const res = await qcckPost({
|
||||||
|
...pageData.pageConfiger,
|
||||||
|
pxxmid: id
|
||||||
|
}, `/mosty-base/baxx/pxry/page`)
|
||||||
|
if (res) {
|
||||||
|
console.log(res);
|
||||||
|
|
||||||
|
pageData.tableData = res.records || [];
|
||||||
|
pageData.total = res.total;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
const open = (row = {}, type = 'view') => {
|
const open = (row = {}, type = 'view') => {
|
||||||
disabled.value = false
|
disabled.value = false
|
||||||
dialogVisible.value = true
|
dialogVisible.value = true
|
||||||
@ -128,10 +156,9 @@ const open = (row = {}, type = 'view') => {
|
|||||||
if (type === 'view') {
|
if (type === 'view') {
|
||||||
title.value = '保安线下考试详情'
|
title.value = '保安线下考试详情'
|
||||||
visible.value = true
|
visible.value = true
|
||||||
getbaInfo()
|
getbaInfo(row)
|
||||||
} else if (type === 'edit') {
|
getPxkcList(row)
|
||||||
title.value = '保安证申请'
|
getList(row)
|
||||||
visible.value = false
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -0,0 +1,121 @@
|
|||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<el-dialog
|
||||||
|
title="选择人员"
|
||||||
|
v-model="visible"
|
||||||
|
width="50%"
|
||||||
|
:before-close="handleClose"
|
||||||
|
>
|
||||||
|
<MyTable :tableData="pageData.tableData" :tableColumn="pageData.tableColumn" :tableHeight="pageData.tableHeight"
|
||||||
|
:key="pageData.keyCount" :tableConfiger="pageData.tableConfiger" :controlsWidth="pageData.controlsWidth"
|
||||||
|
@chooseData="handleChooseData"
|
||||||
|
>
|
||||||
|
<template #pxsc="{ row }">
|
||||||
|
<span>{{ row.pxsc }}h</span>
|
||||||
|
</template>
|
||||||
|
</MyTable>
|
||||||
|
|
||||||
|
<template #footer>
|
||||||
|
<el-button @click="handleClose">取 消</el-button>
|
||||||
|
<el-button type="primary" @click="handleSubmit">确 定</el-button>
|
||||||
|
</template>
|
||||||
|
</el-dialog>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup>
|
||||||
|
import { computed, ref, reactive, getCurrentInstance } from 'vue';
|
||||||
|
import { qcckPost } from "@/api/qcckApi.js";
|
||||||
|
import MyTable from '@/components/aboutTable/MyTable.vue';
|
||||||
|
|
||||||
|
const { proxy } = getCurrentInstance()
|
||||||
|
|
||||||
|
const props = defineProps({
|
||||||
|
modelValue: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false
|
||||||
|
},
|
||||||
|
defaultSelectKeys: {
|
||||||
|
type: Array,
|
||||||
|
default: () => []
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
const emits = defineEmits(['update:modelValue', 'change'])
|
||||||
|
|
||||||
|
const visible = computed({
|
||||||
|
get() {
|
||||||
|
return props.modelValue
|
||||||
|
},
|
||||||
|
set(val) {
|
||||||
|
emits('update:modelValue', val)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
const selectList = ref([])
|
||||||
|
|
||||||
|
const pageData = reactive({
|
||||||
|
tableData: [{}],
|
||||||
|
keyCount: 0,
|
||||||
|
tableConfiger: {
|
||||||
|
rowHieght: 61,
|
||||||
|
showIndex: false,
|
||||||
|
showSelectType: "checkBox",
|
||||||
|
haveControls: false,
|
||||||
|
loading: false
|
||||||
|
},
|
||||||
|
total: 0,
|
||||||
|
tableHeight: 300,
|
||||||
|
pageConfiger: {
|
||||||
|
pageSize: 10,
|
||||||
|
pageCurrent: 1
|
||||||
|
},
|
||||||
|
controlsWidth: 180,
|
||||||
|
tableColumn: [
|
||||||
|
{ label: "姓名", prop: "xm" },
|
||||||
|
{ label: "证件号码", prop: "sfzh" },
|
||||||
|
{ label: "联系电话", prop: "lxdh" },
|
||||||
|
{ label: "培训时长", prop: "pxsc", showSolt: true },
|
||||||
|
]
|
||||||
|
});
|
||||||
|
|
||||||
|
const open = async () => {
|
||||||
|
pageData.tableConfiger.loading = true;
|
||||||
|
|
||||||
|
try {
|
||||||
|
const res = await qcckPost({
|
||||||
|
...pageData.pageConfiger,
|
||||||
|
}, `/mosty-base/baxx/pxry/page`)
|
||||||
|
|
||||||
|
if (res) {
|
||||||
|
pageData.tableData = res.records || []
|
||||||
|
pageData.total = res.total
|
||||||
|
visible.value = true
|
||||||
|
}
|
||||||
|
} finally {
|
||||||
|
pageData.tableConfiger.loading = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
const handleClose = () => {
|
||||||
|
selectList.value = []
|
||||||
|
visible.value = false
|
||||||
|
}
|
||||||
|
|
||||||
|
const handleChooseData = (data) => {
|
||||||
|
selectList.value = data
|
||||||
|
}
|
||||||
|
|
||||||
|
const handleSubmit = () => {
|
||||||
|
if (selectList.value.length === 0) return proxy.$message.warning('请选择人员')
|
||||||
|
emits('change', selectList.value)
|
||||||
|
|
||||||
|
handleClose()
|
||||||
|
}
|
||||||
|
|
||||||
|
defineExpose({ open })
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
|
||||||
|
</style>
|
||||||
@ -8,19 +8,10 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="cntinfo">
|
<div class="cntinfo">
|
||||||
<el-descriptions column="2" border label-width="120px">
|
<form-message ref="formRef" v-model="formData" :rules="rules" :formList="formList" label-width="120px">
|
||||||
<el-descriptions-item label="培训项目名称">{{ formData.xmmc }}</el-descriptions-item>
|
|
||||||
<el-descriptions-item label="考试时间">{{ formData.kskssj }}</el-descriptions-item>
|
|
||||||
<el-descriptions-item label="考试辖区">{{ formData.ksxq }}</el-descriptions-item>
|
|
||||||
<el-descriptions-item label="考试地址">{{ formData.ksdz }}</el-descriptions-item>
|
|
||||||
<el-descriptions-item label="监考民警">{{ formData.jkrxm }}</el-descriptions-item>
|
|
||||||
<el-descriptions-item label="考试方式">
|
|
||||||
<DictTag :value="formData.ksfs" :tag="false" :options="D_BAXX_KSFS" />
|
|
||||||
</el-descriptions-item>
|
|
||||||
</el-descriptions>
|
|
||||||
|
|
||||||
<!-- <el-descriptions title="考试人员" column="2" border class="mt20"> -->
|
</form-message>
|
||||||
<div class="label">培训保安人员</div>
|
<div class="table-title" @click="hanbleClickSelect">考试人员 <el-icon size="20px" style="top: 4px;" color="green"><CirclePlusFilled /></el-icon> </div>
|
||||||
<MyTable :tableData="pageData.tableData" :tableColumn="pageData.tableColumn"
|
<MyTable :tableData="pageData.tableData" :tableColumn="pageData.tableColumn"
|
||||||
:key="pageData.keyCount" :tableConfiger="pageData.tableConfiger" :controlsWidth="pageData.controlsWidth"
|
:key="pageData.keyCount" :tableConfiger="pageData.tableConfiger" :controlsWidth="pageData.controlsWidth"
|
||||||
>
|
>
|
||||||
@ -29,24 +20,26 @@
|
|||||||
<el-link type="warning" @click="addEdit('updata', row)">删除</el-link>
|
<el-link type="warning" @click="addEdit('updata', row)">删除</el-link>
|
||||||
</template>
|
</template>
|
||||||
</MyTable>
|
</MyTable>
|
||||||
<!-- </el-descriptions> -->
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<select-personnel-dialog ref="selectPersonnelRef" v-model="visible" @change="handleChange" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import { ref, computed, reactive, getCurrentInstance } from 'vue'
|
import { ref, computed, reactive, getCurrentInstance } from 'vue'
|
||||||
import { qcckPost } from "@/api/qcckApi.js";
|
import { qcckPost } from "@/api/qcckApi.js";
|
||||||
|
import FormMessage from "@/components/aboutTable/FormMessage.vue";
|
||||||
import MyTable from '@/components/aboutTable/MyTable.vue';
|
import MyTable from '@/components/aboutTable/MyTable.vue';
|
||||||
|
import selectPersonnelDialog from './selectPersonnelDialog.vue';
|
||||||
|
|
||||||
const { proxy } = getCurrentInstance()
|
const { proxy } = getCurrentInstance()
|
||||||
const { D_BAXX_KSFS } = proxy.$dict("D_BAXX_KSFS");
|
const { D_BAXX_KSFS } = proxy.$dict("D_BAXX_KSFS");
|
||||||
const title = ref('保安培训项目新增')
|
const title = ref('保安培训项目新增')
|
||||||
const loading = ref(false)
|
const loading = ref(false)
|
||||||
const disabled = ref(false)
|
const disabled = ref(false)
|
||||||
const FormRef = ref(null)
|
const formRef = ref(null)
|
||||||
const visible = ref(true)
|
const visible = ref(false)
|
||||||
const viewAndUploadRef = ref(null)
|
const viewAndUploadRef = ref(null)
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
@ -72,7 +65,7 @@ const dialogVisible = computed({
|
|||||||
})
|
})
|
||||||
|
|
||||||
const pageData = reactive({
|
const pageData = reactive({
|
||||||
tableData: [{}],
|
tableData: [],
|
||||||
keyCount: 0,
|
keyCount: 0,
|
||||||
tableConfiger: {
|
tableConfiger: {
|
||||||
rowHieght: 61,
|
rowHieght: 61,
|
||||||
@ -94,32 +87,48 @@ const pageData = reactive({
|
|||||||
]
|
]
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const formList = reactive([
|
||||||
|
[
|
||||||
|
{ label: "培训项目名称", prop: "xmmc", type: "input" },
|
||||||
|
{ label: "考试时间", prop: "kskssj", type: "date"},
|
||||||
|
],
|
||||||
|
[
|
||||||
|
{ label: "考试辖区", prop: "ksxq", type: "input" },
|
||||||
|
{ label: "考试地址", prop: "ksdz", type: "input"},
|
||||||
|
],
|
||||||
|
[
|
||||||
|
{ label: "考试方式", prop: "ksfs", type: "select", options: D_BAXX_KSFS },
|
||||||
|
],
|
||||||
|
])
|
||||||
|
|
||||||
|
const rules = {
|
||||||
|
xmmc: [{ required: true, message: '请输入培训项目名称', trigger: 'blur' }],
|
||||||
|
kskssj: [{ required: true, message: '请选择考试时间', trigger: 'blur' }],
|
||||||
|
ksxq: [{ required: true, message: '请输入考试辖区', trigger: 'blur' }],
|
||||||
|
ksdz: [{ required: true, message: '请输入考试地址', trigger: 'blur' }],
|
||||||
|
ksfs: [{ required: true, message: '请选择考试方式', trigger: 'blur' }],
|
||||||
|
}
|
||||||
|
|
||||||
const formData = ref({})
|
const formData = ref({})
|
||||||
|
|
||||||
const close = () => {
|
const close = () => {
|
||||||
dialogVisible.value = false
|
dialogVisible.value = false
|
||||||
}
|
}
|
||||||
|
|
||||||
const open = (row = {}, type = 'add') => {
|
const open = (row = {}) => {
|
||||||
disabled.value = false
|
disabled.value = false
|
||||||
dialogVisible.value = true
|
dialogVisible.value = true
|
||||||
formData.value = { ...row }
|
formData.value = { ...row }
|
||||||
if (type === 'view') {
|
title.value = '保安考试申请'
|
||||||
title.value = '保安线下考试详情'
|
|
||||||
visible.value = true
|
|
||||||
} else if (type === 'edit') {
|
|
||||||
title.value = '保安证申请'
|
|
||||||
visible.value = false
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
const save = () => {
|
const save = () => {
|
||||||
FormRef.value.submit(() => {
|
if (pageData.tableData.length === 0) return proxy.$message.warning('请选择考试人员')
|
||||||
|
formRef.value.submit(() => {
|
||||||
loading.value = true;
|
loading.value = true;
|
||||||
const url = !formData.value?.id ? `/mosty-base/baxx/cyry/add` : `/mosty-base/baxx/cyry/edit`;
|
qcckPost(formData.value, `mosty-base/baxx/pxxm/sqks`).then(() => {
|
||||||
qcckPost(formData.value, url).then(() => {
|
|
||||||
loading.value = false;
|
loading.value = false;
|
||||||
proxy.$message.success("保存成功");
|
proxy.$message.success("申请考试成功");
|
||||||
emits("refresh");
|
emits("refresh");
|
||||||
close();
|
close();
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
@ -128,6 +137,15 @@ const save = () => {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const selectPersonnelRef = ref(null)
|
||||||
|
const hanbleClickSelect = () => {
|
||||||
|
selectPersonnelRef.value?.open()
|
||||||
|
}
|
||||||
|
|
||||||
|
const handleChange = (val) => {
|
||||||
|
pageData.tableData = [...pageData.tableData, ...val]?.filter((i, index, arr) => arr?.findIndex(s => i?.id === s?.id) === index)
|
||||||
|
}
|
||||||
|
|
||||||
const addEdit = (type, row) => {
|
const addEdit = (type, row) => {
|
||||||
viewAndUploadRef.value?.open(row, type)
|
viewAndUploadRef.value?.open(row, type)
|
||||||
}
|
}
|
||||||
@ -138,6 +156,20 @@ defineExpose({ open })
|
|||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
@import "@/assets/css/layout.scss";
|
@import "@/assets/css/layout.scss";
|
||||||
|
|
||||||
|
::v-deep {
|
||||||
|
.el-form--inline {
|
||||||
|
padding: 0 !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.table-title{
|
||||||
|
line-height: 40px;
|
||||||
|
text-align: center;
|
||||||
|
background: #f5f5f5;
|
||||||
|
color: #333;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
.label {
|
.label {
|
||||||
margin-top: 20px;
|
margin-top: 20px;
|
||||||
color: #000;
|
color: #000;
|
||||||
|
|||||||
@ -30,7 +30,7 @@
|
|||||||
<view-project-details-dialog ref="viewProjectDetailsRef" v-model="isVisible" />
|
<view-project-details-dialog ref="viewProjectDetailsRef" v-model="isVisible" />
|
||||||
<preject-details-dialog ref="prejectDetailsRef" v-model="dialogVisible" />
|
<preject-details-dialog ref="prejectDetailsRef" v-model="dialogVisible" />
|
||||||
<!-- 新增 -->
|
<!-- 新增 -->
|
||||||
<AddPxxm ref="addPxxmRef" v-model="dialogVisible" />
|
<AddPxxm ref="addPxxmRef" v-model="dialogVisible" @refresh="getList" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -44,6 +44,7 @@ import PageTitle from "@/components/aboutTable/PageTitle.vue";
|
|||||||
import ViewProjectDetailsDialog from "./components/viewProjectDetailsDialog.vue";
|
import ViewProjectDetailsDialog from "./components/viewProjectDetailsDialog.vue";
|
||||||
import AddPxxm from './components/addPxxm.vue'
|
import AddPxxm from './components/addPxxm.vue'
|
||||||
import PrejectDetailsDialog from "./components/prejectDetailsDialog.vue";
|
import PrejectDetailsDialog from "./components/prejectDetailsDialog.vue";
|
||||||
|
import { get } from "lodash";
|
||||||
const addPxxmRef = ref()
|
const addPxxmRef = ref()
|
||||||
const prejectDetailsRef = ref(null);
|
const prejectDetailsRef = ref(null);
|
||||||
const viewProjectDetailsRef = ref(null)
|
const viewProjectDetailsRef = ref(null)
|
||||||
|
|||||||
@ -16,11 +16,15 @@
|
|||||||
<Upload v-model="formData.cszp" />
|
<Upload v-model="formData.cszp" />
|
||||||
</div>
|
</div>
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
<el-descriptions-item label="保安单位类型">{{ formData.type }}</el-descriptions-item>
|
<el-descriptions-item label="保安单位类型">
|
||||||
|
<DictTag :options="D_BAXX_DWLX" :value="formData.type" />
|
||||||
|
</el-descriptions-item>
|
||||||
<el-descriptions-item label="场所名称">{{ formData.csmc }}</el-descriptions-item>
|
<el-descriptions-item label="场所名称">{{ formData.csmc }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="场所代码">{{ formData.csdm }}</el-descriptions-item>
|
<el-descriptions-item label="场所代码">{{ formData.csdm }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="场所联系电话">{{ formData.csLxdh }}</el-descriptions-item>
|
<el-descriptions-item label="场所联系电话">{{ formData.csLxdh }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="经营状况">{{ formData.jyzk }}</el-descriptions-item>
|
<el-descriptions-item label="经营状况">
|
||||||
|
<DictTag :options="D_BZ_YLJYZK" :value="formData.jyzk" />
|
||||||
|
</el-descriptions-item>
|
||||||
<el-descriptions-item label="开业日期">{{ formData.kyrq }}</el-descriptions-item>
|
<el-descriptions-item label="开业日期">{{ formData.kyrq }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="单位注册地址" :span="3">{{ formData.zcdz }}</el-descriptions-item>
|
<el-descriptions-item label="单位注册地址" :span="3">{{ formData.zcdz }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="场所经营地址" :span="3">{{ formData.csjydz }}</el-descriptions-item>
|
<el-descriptions-item label="场所经营地址" :span="3">{{ formData.csjydz }}</el-descriptions-item>
|
||||||
@ -70,9 +74,11 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import { ref, computed, reactive } from 'vue'
|
import { ref, computed, getCurrentInstance } from 'vue'
|
||||||
import Upload from "@/components/MyComponents/Upload/index.vue"
|
import Upload from "@/components/MyComponents/Upload/index.vue"
|
||||||
|
|
||||||
|
const { proxy } = getCurrentInstance()
|
||||||
|
const { D_BAXX_DWLX, D_BZ_YLJYZK } = proxy.$dict("D_BAXX_DWLX", "D_BZ_YLJYZK")
|
||||||
const title = ref('保安培训项目新增')
|
const title = ref('保安培训项目新增')
|
||||||
const disabled = ref(false)
|
const disabled = ref(false)
|
||||||
const visible = ref(true)
|
const visible = ref(true)
|
||||||
|
|||||||
@ -4,9 +4,9 @@ function resolve(dir) {
|
|||||||
return path.join(__dirname, dir);
|
return path.join(__dirname, dir);
|
||||||
}
|
}
|
||||||
// const serverHost = "http://192.168.1.98:8006";//毛毛
|
// const serverHost = "http://192.168.1.98:8006";//毛毛
|
||||||
// const serverHost = "http://192.168.1.32:8066";//波哥
|
const serverHost = "http://192.168.1.32:8066";//波哥
|
||||||
// const serverHost = "http://192.168.0.231:8006"//线上
|
// const serverHost = "http://192.168.0.231:8006"//线上
|
||||||
const serverHost = "http://47.108.232.77:9537";//波哥
|
// const serverHost = "http://47.108.232.77:9537";//波哥
|
||||||
// const serverHost = "http://127.0.0.1:8006"
|
// const serverHost = "http://127.0.0.1:8006"
|
||||||
module.exports = {
|
module.exports = {
|
||||||
publicPath: "./",
|
publicPath: "./",
|
||||||
|
|||||||
Reference in New Issue
Block a user