From 6cc9faaa0830d824534c22e8a75bbcdd3d01b5c0 Mon Sep 17 00:00:00 2001 From: BianLzhaoMin <11485688+bianliangzhaomin123@user.noreply.gitee.com> Date: Wed, 13 Aug 2025 13:19:09 +0800 Subject: [PATCH] =?UTF-8?q?=E5=85=AC=E5=8F=B8=E7=AE=A1=E7=90=86=E5=AE=8C?= =?UTF-8?q?=E5=96=84=E6=8E=A5=E5=8F=A3=E8=B0=83=E8=AF=95=E5=AE=8C=E6=88=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../divide-company-manage.js | 2 +- src/assets/styles/sidebar.scss | 2 +- src/components/AttendanceCalendar/index.vue | 357 ++++++++++++++++++ .../red-and-green-count/index.vue | 8 +- .../divide-company-manage/config.js | 10 +- .../divide-company-manage/index.vue | 30 +- 6 files changed, 395 insertions(+), 14 deletions(-) create mode 100644 src/components/AttendanceCalendar/index.vue diff --git a/src/api/system/basic-type-config/divide-company-manage.js b/src/api/system/basic-type-config/divide-company-manage.js index fc54609..883c543 100644 --- a/src/api/system/basic-type-config/divide-company-manage.js +++ b/src/api/system/basic-type-config/divide-company-manage.js @@ -12,7 +12,7 @@ export function addAndEditDivideCompanyManageAPI(data) { // 删除分公司管理 export function deleteDivideCompanyManageAPI(data) { return request({ - url: '/system/dict/type/add', + url: '/bmw/subCompany/delSubCompany', method: 'post', data, }) diff --git a/src/assets/styles/sidebar.scss b/src/assets/styles/sidebar.scss index 4f1e5fb..f7f7a5c 100644 --- a/src/assets/styles/sidebar.scss +++ b/src/assets/styles/sidebar.scss @@ -225,7 +225,7 @@ } } -.el-menu-item.is-active { +.theme-dark .el-menu-item.is-active { color: #fff !important; } diff --git a/src/components/AttendanceCalendar/index.vue b/src/components/AttendanceCalendar/index.vue new file mode 100644 index 0000000..225fa31 --- /dev/null +++ b/src/components/AttendanceCalendar/index.vue @@ -0,0 +1,357 @@ + + + + + diff --git a/src/views/construction-person/red-green-light-mange/red-and-green-count/index.vue b/src/views/construction-person/red-green-light-mange/red-and-green-count/index.vue index 18217bf..19a87f2 100644 --- a/src/views/construction-person/red-green-light-mange/red-and-green-count/index.vue +++ b/src/views/construction-person/red-green-light-mange/red-and-green-count/index.vue @@ -1,11 +1,17 @@ diff --git a/src/views/system/basic-type-config/divide-company-manage/config.js b/src/views/system/basic-type-config/divide-company-manage/config.js index 979c918..e4809ca 100644 --- a/src/views/system/basic-type-config/divide-company-manage/config.js +++ b/src/views/system/basic-type-config/divide-company-manage/config.js @@ -1,17 +1,17 @@ export const formLabel = [ { f_label: '关键词', - f_model: 'keyword', + f_model: 'subCompanyName', f_type: 'ipt', isShow: false, // 是否展示label }, ] export const columnsList = [ - { t_props: 'projectName', t_label: '分公司名称' }, - { t_props: 'xmb', t_label: '所属公司名称' }, - { t_props: 'name', t_label: '状态', t_slot: 'isEnable' }, - { t_props: 'type', t_label: '更新时间' }, + { t_props: 'subCompanyName', t_label: '分公司名称' }, + { t_props: 'companyName', t_label: '所属公司名称' }, + { t_label: '状态', t_slot: 'isEnable' }, + { t_props: 'updateTime', t_label: '更新时间' }, ] export const dialogConfig = { diff --git a/src/views/system/basic-type-config/divide-company-manage/index.vue b/src/views/system/basic-type-config/divide-company-manage/index.vue index 94cc04a..34cc367 100644 --- a/src/views/system/basic-type-config/divide-company-manage/index.vue +++ b/src/views/system/basic-type-config/divide-company-manage/index.vue @@ -176,6 +176,7 @@ export default { // 公司下拉列表 companySelectList: [], + companySelectAllList: [], } }, @@ -183,7 +184,7 @@ export default { // 获取公司下拉列表 async getCompanySelectList() { const { rows: res } = await getCompanySelectListAPI() - this.companySelectList = res + this.companySelectAllList = res }, // 新增或修改 @@ -193,13 +194,18 @@ export default { if (type === 2) { const { comId, subCompanyName, isEnable, id } = data this.addOrEditForm = { comId, subCompanyName, isEnable, id } + this.companySelectList = this.companySelectAllList + } else { + this.companySelectList = this.companySelectAllList.filter( + (e) => e.isEnable !== 0, + ) } this.dialogConfig.outerVisible = true }, // 状态设置 onHandleChangeIsEnable(data) { - this.dialogConfig.outerTitle === '' + this.dialogConfig.outerTitle = '' this.onHandleAddOrEditJobTypeConfirm({ id: data.id, isEnable: data.isEnable, @@ -208,7 +214,19 @@ export default { // 删除 onHandleDeleteJobType(data) { - console.log(data, '删除') + this.$confirm('确定删除该分公司吗?', '提示', { + confirmButtonText: '确定', + cancelButtonText: '取消', + type: 'warning', + }).then(async () => { + const res = await deleteDivideCompanyManageAPI(data) + if (res.code === 200) { + this.$modal.msgSuccess('删除成功') + this.$refs.divideCompanyManageTableRef.getTableList() + } else { + this.$modal.msgError(res.msg) + } + }) }, // 取消 @@ -233,11 +251,11 @@ export default { async onHandleAddOrEditJobTypeConfirm(data) { const res = await addAndEditDivideCompanyManageAPI(data) if (res.code === 200) { - this.$message.success('操作成功') + this.$modal.msgSuccess('操作成功') this.handleCloseDialogOuter() this.$refs.divideCompanyManageTableRef.getTableList() } else { - this.$message.error(res.msg) + this.$modal.msgError(res.msg) } }, @@ -256,7 +274,7 @@ export default { }, created() { - // this.getCompanySelectList() + this.getCompanySelectList() }, }