From 6ed401470407adb48b55fbd9900b988a950e4314 Mon Sep 17 00:00:00 2001 From: yangjun <1173114630@qq.com> Date: Tue, 1 Apr 2025 09:50:16 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=91=98=E5=B7=A5?= =?UTF-8?q?=E5=9F=BA=E7=A1=80=E9=A1=B5=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../bizEmployeesInfo/BizEmployeesInfo.api.ts | 72 ++++ .../bizEmployeesInfo/BizEmployeesInfo.data.ts | 234 +++++++++++ .../bizEmployeesInfo/BizEmployeesInfoList.vue | 235 +++++++++++ .../components/BizEmployeesInfoForm.vue | 380 ++++++++++++++++++ .../components/BizEmployeesInfoModal.vue | 77 ++++ 5 files changed, 998 insertions(+) create mode 100644 src/views/biz/bizEmployeesInfo/BizEmployeesInfo.api.ts create mode 100644 src/views/biz/bizEmployeesInfo/BizEmployeesInfo.data.ts create mode 100644 src/views/biz/bizEmployeesInfo/BizEmployeesInfoList.vue create mode 100644 src/views/biz/bizEmployeesInfo/components/BizEmployeesInfoForm.vue create mode 100644 src/views/biz/bizEmployeesInfo/components/BizEmployeesInfoModal.vue diff --git a/src/views/biz/bizEmployeesInfo/BizEmployeesInfo.api.ts b/src/views/biz/bizEmployeesInfo/BizEmployeesInfo.api.ts new file mode 100644 index 0000000..c2e43be --- /dev/null +++ b/src/views/biz/bizEmployeesInfo/BizEmployeesInfo.api.ts @@ -0,0 +1,72 @@ +import { defHttp } from '/@/utils/http/axios'; +import { useMessage } from "/@/hooks/web/useMessage"; + +const { createConfirm } = useMessage(); + +enum Api { + list = '/bizEmployeesInfo/bizEmployeesInfo/list', + save='/bizEmployeesInfo/bizEmployeesInfo/add', + edit='/bizEmployeesInfo/bizEmployeesInfo/edit', + deleteOne = '/bizEmployeesInfo/bizEmployeesInfo/delete', + deleteBatch = '/bizEmployeesInfo/bizEmployeesInfo/deleteBatch', + importExcel = '/bizEmployeesInfo/bizEmployeesInfo/importExcel', + exportXls = '/bizEmployeesInfo/bizEmployeesInfo/exportXls', +} + +/** + * 导出api + * @param params + */ +export const getExportUrl = Api.exportXls; + +/** + * 导入api + */ +export const getImportUrl = Api.importExcel; + +/** + * 列表接口 + * @param params + */ +export const list = (params) => defHttp.get({ url: Api.list, params }); + +/** + * 删除单个 + * @param params + * @param handleSuccess + */ +export const deleteOne = (params,handleSuccess) => { + return defHttp.delete({url: Api.deleteOne, params}, {joinParamsToUrl: true}).then(() => { + handleSuccess(); + }); +} + +/** + * 批量删除 + * @param params + * @param handleSuccess + */ +export const batchDelete = (params, handleSuccess) => { + createConfirm({ + iconType: 'warning', + title: '确认删除', + content: '是否删除选中数据', + okText: '确认', + cancelText: '取消', + onOk: () => { + return defHttp.delete({url: Api.deleteBatch, data: params}, {joinParamsToUrl: true}).then(() => { + handleSuccess(); + }); + } + }); +} + +/** + * 保存或者更新 + * @param params + * @param isUpdate + */ +export const saveOrUpdate = (params, isUpdate) => { + let url = isUpdate ? Api.edit : Api.save; + return defHttp.post({ url: url, params }, { isTransformResponse: false }); +} diff --git a/src/views/biz/bizEmployeesInfo/BizEmployeesInfo.data.ts b/src/views/biz/bizEmployeesInfo/BizEmployeesInfo.data.ts new file mode 100644 index 0000000..64e61a4 --- /dev/null +++ b/src/views/biz/bizEmployeesInfo/BizEmployeesInfo.data.ts @@ -0,0 +1,234 @@ +import {BasicColumn} from '/@/components/Table'; +import {FormSchema} from '/@/components/Table'; +import { rules} from '/@/utils/helper/validator'; +import { render } from '/@/utils/common/renderUtils'; +import { getWeekMonthQuarterYear } from '/@/utils'; +//列表数据 +export const columns: BasicColumn[] = [ + { + title: '姓名', + align: "center", + dataIndex: 'name' + }, + { + title: '性别', + align: "center", + dataIndex: 'sex_dictText' + }, + { + title: '民族', + align: "center", + dataIndex: 'national' + }, + { + title: '身份证号', + align: "center", + dataIndex: 'idCard' + }, + { + title: '联系电话', + align: "center", + dataIndex: 'tel' + }, + { + title: '入职时间', + align: "center", + dataIndex: 'entryTime', + customRender:({text}) =>{ + text = !text ? "" : (text.length > 10 ? text.substr(0,10) : text); + return text; + }, + }, + { + title: '岗位级别', + align: "center", + dataIndex: 'postLevel_dictText' + }, + { + title: '出生日期', + align: "center", + dataIndex: 'dateOfBirth', + customRender:({text}) =>{ + text = !text ? "" : (text.length > 10 ? text.substr(0,10) : text); + return text; + }, + }, + { + title: '婚否', + align: "center", + dataIndex: 'marriedOrNot_dictText' + }, + { + title: '工资', + align: "center", + dataIndex: 'wages_dictText' + }, + { + title: '身高', + align: "center", + dataIndex: 'height' + }, + { + title: '体重', + align: "center", + dataIndex: 'weight' + }, + { + title: '家庭住址', + align: "center", + dataIndex: 'address' + }, + { + title: '是否吸烟', + align: "center", + dataIndex: 'isSmoking_dictText' + }, + { + title: '健康状况', + align: "center", + dataIndex: 'healthStatus_dictText' + }, + { + title: '户籍所在地', + align: "center", + dataIndex: 'houseAddress' + }, + { + title: '政治面貌', + align: "center", + dataIndex: 'politicalAppearance_dictText' + }, + { + title: '紧急联系人', + align: "center", + dataIndex: 'emergencyContact' + }, + { + title: '紧急联系人电话', + align: "center", + dataIndex: 'emergencyTel' + }, + { + title: '紧急联系人与本人关系', + align: "center", + dataIndex: 'emergencyRelationship' + }, + { + title: '户口性质', + align: "center", + dataIndex: 'hukouNature_dictText' + }, + { + title: '备注', + align: "center", + dataIndex: 'content' + }, + { + title: '身份证正面', + align: "center", + dataIndex: 'idCardPositive', + customRender: render.renderImage, + }, + { + title: '身份证反面', + align: "center", + dataIndex: 'idCardNegative', + customRender: render.renderImage, + }, + { + title: '合同正面', + align: "center", + dataIndex: 'contractPositive', + customRender: render.renderImage, + }, + { + title: '合同反面', + align: "center", + dataIndex: 'contractNegative', + customRender: render.renderImage, + }, + { + title: '健康证正面', + align: "center", + dataIndex: 'healthCertificatePositive', + customRender: render.renderImage, + }, + { + title: '健康证反面', + align: "center", + dataIndex: 'healthCertificateNegative', + customRender: render.renderImage, + }, + { + title: '银行卡正面', + align: "center", + dataIndex: 'bankPositive', + customRender: render.renderImage, + }, + { + title: '银行卡反面', + align: "center", + dataIndex: 'bankNegative', + customRender: render.renderImage, + }, + { + title: '资质证', + align: "center", + dataIndex: 'qualification', + customRender: render.renderImage, + }, + { + title: '无犯罪证明', + align: "center", + dataIndex: 'noCrimeCertificate', + customRender: render.renderImage, + }, + { + title: '区域', + align: "center", + dataIndex: 'regional' + }, + { + title: '服务标签', + align: "center", + dataIndex: 'serviceTag' + }, +]; + +// 高级查询数据 +export const superQuerySchema = { + name: {title: '姓名',order: 0,view: 'text', type: 'string',}, + sex: {title: '性别',order: 1,view: 'radio', type: 'string',dictCode: 'sex',}, + national: {title: '民族',order: 2,view: 'text', type: 'string',}, + idCard: {title: '身份证号',order: 3,view: 'text', type: 'string',}, + tel: {title: '联系电话',order: 4,view: 'text', type: 'string',}, + entryTime: {title: '入职时间',order: 5,view: 'date', type: 'string',}, + postLevel: {title: '岗位级别',order: 6,view: 'radio', type: 'string',dictCode: 'post_level',}, + dateOfBirth: {title: '出生日期',order: 7,view: 'date', type: 'string',}, + marriedOrNot: {title: '婚否',order: 8,view: 'radio', type: 'string',dictCode: 'married_or_not',}, + wages: {title: '工资',order: 9,view: 'radio', type: 'string',dictCode: 'wages',}, + height: {title: '身高',order: 10,view: 'number', type: 'number',}, + weight: {title: '体重',order: 11,view: 'number', type: 'number',}, + address: {title: '家庭住址',order: 12,view: 'text', type: 'string',}, + isSmoking: {title: '是否吸烟',order: 13,view: 'radio', type: 'string',dictCode: 'is_smoking',}, + healthStatus: {title: '健康状况',order: 14,view: 'radio', type: 'string',dictCode: 'health_status',}, + houseAddress: {title: '户籍所在地',order: 15,view: 'text', type: 'string',}, + politicalAppearance: {title: '政治面貌',order: 16,view: 'list', type: 'string',dictCode: 'political_appearance',}, + emergencyContact: {title: '紧急联系人',order: 17,view: 'text', type: 'string',}, + emergencyTel: {title: '紧急联系人电话',order: 18,view: 'text', type: 'string',}, + emergencyRelationship: {title: '紧急联系人与本人关系',order: 19,view: 'text', type: 'string',}, + hukouNature: {title: '户口性质',order: 20,view: 'radio', type: 'string',dictCode: 'hukou_nature',}, + content: {title: '备注',order: 21,view: 'text', type: 'string',}, + idCardPositive: {title: '身份证正面',order: 22,view: 'image', type: 'string',}, + idCardNegative: {title: '身份证反面',order: 23,view: 'image', type: 'string',}, + contractPositive: {title: '合同正面',order: 24,view: 'image', type: 'string',}, + contractNegative: {title: '合同反面',order: 25,view: 'image', type: 'string',}, + healthCertificatePositive: {title: '健康证正面',order: 26,view: 'image', type: 'string',}, + healthCertificateNegative: {title: '健康证反面',order: 27,view: 'image', type: 'string',}, + bankPositive: {title: '银行卡正面',order: 28,view: 'image', type: 'string',}, + bankNegative: {title: '银行卡反面',order: 29,view: 'image', type: 'string',}, + qualification: {title: '资质证',order: 30,view: 'image', type: 'string',}, + noCrimeCertificate: {title: '无犯罪证明',order: 31,view: 'image', type: 'string',}, + regional: {title: '区域',order: 32,view: 'text', type: 'string',}, + serviceTag: {title: '服务标签',order: 33,view: 'text', type: 'string',}, +}; diff --git a/src/views/biz/bizEmployeesInfo/BizEmployeesInfoList.vue b/src/views/biz/bizEmployeesInfo/BizEmployeesInfoList.vue new file mode 100644 index 0000000..0dc7a5a --- /dev/null +++ b/src/views/biz/bizEmployeesInfo/BizEmployeesInfoList.vue @@ -0,0 +1,235 @@ + + + + + + + + + 姓名 + + + + + + + 查询 + 重置 + 新增 + + + + + + + + + + + + + + + + 编辑 + + + 工作内容 + + + + + + + + + + + + + + 入职日期: {{item.entryTime}} + 身份证号: {{item.idCard}} + 联系电话: {{item.tel}} + 出生日期: {{item.dateOfBirth}} + + + + + + + + + + + + + + + + + + + diff --git a/src/views/biz/bizEmployeesInfo/components/BizEmployeesInfoForm.vue b/src/views/biz/bizEmployeesInfo/components/BizEmployeesInfoForm.vue new file mode 100644 index 0000000..949418a --- /dev/null +++ b/src/views/biz/bizEmployeesInfo/components/BizEmployeesInfoForm.vue @@ -0,0 +1,380 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/views/biz/bizEmployeesInfo/components/BizEmployeesInfoModal.vue b/src/views/biz/bizEmployeesInfo/components/BizEmployeesInfoModal.vue new file mode 100644 index 0000000..a21000a --- /dev/null +++ b/src/views/biz/bizEmployeesInfo/components/BizEmployeesInfoModal.vue @@ -0,0 +1,77 @@ + + + + + + + + + + From bd72faa11ecf9e850aeaeaa49bf117f263fea408 Mon Sep 17 00:00:00 2001 From: yangjun <1173114630@qq.com> Date: Wed, 2 Apr 2025 13:30:35 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=91=98=E5=B7=A5?= =?UTF-8?q?=E5=88=86=E9=85=8D=E6=A0=87=E7=AD=BE=E9=A1=B5=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../bizEmployeesInfo/BizEmployeesInfo.api.ts | 21 ++ .../bizEmployeesInfo/BizEmployeesInfo.data.ts | 53 ++++ .../BizEmployeesInfoList copy.vue | 227 ++++++++++++++++++ .../bizEmployeesInfo/BizEmployeesInfoList.vue | 15 +- .../EmployeesServiceTagForm.vue | 206 ++++++++++++++++ .../EmployeesServiceTagModal.vue | 65 +++++ 6 files changed, 584 insertions(+), 3 deletions(-) create mode 100644 src/views/biz/bizEmployeesInfo/BizEmployeesInfoList copy.vue create mode 100644 src/views/biz/bizEmployeesInfo/employeesServiceTag/EmployeesServiceTagForm.vue create mode 100644 src/views/biz/bizEmployeesInfo/employeesServiceTag/EmployeesServiceTagModal.vue diff --git a/src/views/biz/bizEmployeesInfo/BizEmployeesInfo.api.ts b/src/views/biz/bizEmployeesInfo/BizEmployeesInfo.api.ts index c2e43be..7046e41 100644 --- a/src/views/biz/bizEmployeesInfo/BizEmployeesInfo.api.ts +++ b/src/views/biz/bizEmployeesInfo/BizEmployeesInfo.api.ts @@ -11,6 +11,13 @@ enum Api { deleteBatch = '/bizEmployeesInfo/bizEmployeesInfo/deleteBatch', importExcel = '/bizEmployeesInfo/bizEmployeesInfo/importExcel', exportXls = '/bizEmployeesInfo/bizEmployeesInfo/exportXls', + + getEmployeesList = '/serviceTag/serviceTag/getEmployeesList', + queryTagsById = '/serviceTag/serviceTag/queryById', + checkTags='/bizEmployeesInfo/nuBizEmployeesServcieTags/add', + removeTags = '/bizEmployeesInfo/nuBizEmployeesServcieTags/delete', + getEmployessServiceTags = '/serviceTag/serviceTag/getEmployessServiceTags', + } /** @@ -29,7 +36,10 @@ export const getImportUrl = Api.importExcel; * @param params */ export const list = (params) => defHttp.get({ url: Api.list, params }); +export const getEmployessServiceTags = (params) => defHttp.get({ url: Api.getEmployessServiceTags, params }); +export const getEmployeesList = (params) => defHttp.get({ url: Api.getEmployeesList, params }); +export const queryTagsById = (params) => defHttp.get({ url: Api.queryTagsById, params }); /** * 删除单个 * @param params @@ -70,3 +80,14 @@ export const saveOrUpdate = (params, isUpdate) => { let url = isUpdate ? Api.edit : Api.save; return defHttp.post({ url: url, params }, { isTransformResponse: false }); } + + + +export const checkTags = (params) => { + let url = Api.checkTags; + return defHttp.post({ url: url, params }, { isTransformResponse: false }); +} +export const removeTags = (params) => { + let url = Api.removeTags; + return defHttp.delete({ url: url, params }, {joinParamsToUrl: true}); +} \ No newline at end of file diff --git a/src/views/biz/bizEmployeesInfo/BizEmployeesInfo.data.ts b/src/views/biz/bizEmployeesInfo/BizEmployeesInfo.data.ts index 64e61a4..e85d5ad 100644 --- a/src/views/biz/bizEmployeesInfo/BizEmployeesInfo.data.ts +++ b/src/views/biz/bizEmployeesInfo/BizEmployeesInfo.data.ts @@ -232,3 +232,56 @@ export const superQuerySchema = { regional: {title: '区域',order: 32,view: 'text', type: 'string',}, serviceTag: {title: '服务标签',order: 33,view: 'text', type: 'string',}, }; + + + + +//列表数据 +export const serviceTagcolumns: BasicColumn[] = [ + { + title: '服务标签名称', + align: "center", + dataIndex: 'tagName', + width:'50%' + }, + { + title: '备注', + align: "center", + dataIndex: 'description' + }, +]; + +//列表数据 +export const employeesTagcolumns: BasicColumn[] = [ + { + title: '序号', + dataIndex: 'rowIndex', + key: 'rowIndex', + width: 60, + align: 'center', + customRender: function ({ text }) { + if (text == undefined) { + return ''; + } else { + return parseInt(text) + 1; + } + }, + }, + { + title: '服务标签名称', + align: "center", + dataIndex: 'tagName', + width:'50%' + }, + { + title: '备注', + align: "center", + dataIndex: 'description' + }, + { + title: '操作', + key:'action', + align: "center", + width:'140px', + }, +]; \ No newline at end of file diff --git a/src/views/biz/bizEmployeesInfo/BizEmployeesInfoList copy.vue b/src/views/biz/bizEmployeesInfo/BizEmployeesInfoList copy.vue new file mode 100644 index 0000000..50937b5 --- /dev/null +++ b/src/views/biz/bizEmployeesInfo/BizEmployeesInfoList copy.vue @@ -0,0 +1,227 @@ + + + + + + + + + 姓名 + + + + + + + 查询 + 重置 + + + + + + + + + + + 新增 + 导出 + 导入 + + + + + + + + + + + + + + + + diff --git a/src/views/biz/bizEmployeesInfo/BizEmployeesInfoList.vue b/src/views/biz/bizEmployeesInfo/BizEmployeesInfoList.vue index 0dc7a5a..3cdda5d 100644 --- a/src/views/biz/bizEmployeesInfo/BizEmployeesInfoList.vue +++ b/src/views/biz/bizEmployeesInfo/BizEmployeesInfoList.vue @@ -34,7 +34,7 @@ 编辑 - 工作内容 + 服务标签 @@ -70,6 +70,7 @@ + @@ -79,14 +80,16 @@ import { list, deleteOne, batchDelete, getImportUrl, getExportUrl } from './BizEmployeesInfo.api'; import { downloadFile } from '/@/utils/common/renderUtils'; import BizEmployeesInfoModal from './components/BizEmployeesInfoModal.vue' -import { defHttp } from '/@/utils/http/axios'; -import { getFileAccessHttpUrl } from '/@/utils/common/compUtils'; + import EmployeesServiceTagModal from '/@/views/biz/bizEmployeesInfo/employeesServiceTag/employeesServiceTagModal.vue' + import { defHttp } from '/@/utils/http/axios'; + import { getFileAccessHttpUrl } from '/@/utils/common/compUtils'; import { Pagination } from 'ant-design-vue'; const APagination = Pagination; const formRef = ref(); const queryParam = reactive({}); const registerModal = ref(); + const registerServiceTagModal = ref(); const dataList = ref([]); const current = ref(1); const pageSize = ref(8); @@ -103,6 +106,7 @@ import { getFileAccessHttpUrl } from '/@/utils/common/compUtils'; sm: 20, }); +//当没有员工头像时,默认展示企业logo function handleHeadPath(headPath){ console.log('headPath--->',headPath); if(headPath){ @@ -110,7 +114,12 @@ import { getFileAccessHttpUrl } from '/@/utils/common/compUtils'; }else{ return '../../../../../public/resource/img/logo.png'; } + } +//分配服务标签 + function handleFwbq(info){ + registerServiceTagModal.value.disableSubmit = false; + registerServiceTagModal.value.init(info); } /** diff --git a/src/views/biz/bizEmployeesInfo/employeesServiceTag/EmployeesServiceTagForm.vue b/src/views/biz/bizEmployeesInfo/employeesServiceTag/EmployeesServiceTagForm.vue new file mode 100644 index 0000000..ed0a273 --- /dev/null +++ b/src/views/biz/bizEmployeesInfo/employeesServiceTag/EmployeesServiceTagForm.vue @@ -0,0 +1,206 @@ + + + + + + + + + + 可选服务标签 + + + + + + + + + + + + 已选服务标签 + + + + 移除 + + 详情 + + + + + + + + 详情 + + + + + + {{ (index+1) +'、 '+ item.categoryName +'-'+item.typeName +'-'+item.directiveName }} + ({{item.tagsName}}) + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/views/biz/bizEmployeesInfo/employeesServiceTag/EmployeesServiceTagModal.vue b/src/views/biz/bizEmployeesInfo/employeesServiceTag/EmployeesServiceTagModal.vue new file mode 100644 index 0000000..b4bc95f --- /dev/null +++ b/src/views/biz/bizEmployeesInfo/employeesServiceTag/EmployeesServiceTagModal.vue @@ -0,0 +1,65 @@ + + + + + + + + + +
入职日期: {{item.entryTime}}
身份证号: {{item.idCard}}
联系电话: {{item.tel}}
出生日期: {{item.dateOfBirth}}