From baddb052ccd4a91ef1881ba663e6a4e55b05f4fb Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期三, 14 十月 2026 15:51:55 +0800
Subject: [PATCH] feat(hrm): 社保公积金方案表单加「适用部门」与默认缴费基数,修比例输入精度
---
src/views/mes/qc/ipqc/data.ts | 168 +++++++++++++++++++++++++++++++++-----------------------
1 files changed, 99 insertions(+), 69 deletions(-)
diff --git a/src/views/mes/qc/ipqc/data.ts b/src/views/mes/qc/ipqc/data.ts
index 86522b9..5103269 100644
--- a/src/views/mes/qc/ipqc/data.ts
+++ b/src/views/mes/qc/ipqc/data.ts
@@ -5,12 +5,7 @@
import { h, markRaw } from 'vue';
-import {
- DICT_TYPE,
- MesAutoCodeRuleCode,
- MesProTaskStatusEnum,
- MesProWorkOrderStatusEnum,
-} from '@vben/constants';
+import { DICT_TYPE, MesAutoCodeRuleCode } from '@vben/constants';
import { getDictOptions } from '@vben/hooks';
import { Button } from 'ant-design-vue';
@@ -19,10 +14,7 @@
import { getTemplateItemOptionList } from '#/api/mes/qc/template/item';
import { getSimpleUserList } from '#/api/system/user';
import { getRangePickerDefaultProps } from '#/utils';
-import { MdItemSelect } from '#/views/mes/md/item/components';
-import { MdWorkstationSelect } from '#/views/mes/md/workstation/components';
-import { ProTaskSelect } from '#/views/mes/pro/task/components';
-import { ProWorkOrderSelect } from '#/views/mes/pro/workorder/components';
+import { MdmItemSelect } from '#/views/basicData/mdm/components';
/** 琛ㄥ崟绫诲瀷 */
export type FormType = 'create' | 'detail' | 'update';
@@ -152,60 +144,31 @@
},
},
{
- fieldName: 'workOrderId',
- label: '鐢熶骇璁㈠崟',
- component: markRaw(ProWorkOrderSelect),
+ fieldName: 'itemId',
+ label: '浜у搧鐗╂枡',
+ component: markRaw(MdmItemSelect),
componentProps: {
- placeholder: '璇烽�夋嫨鐢熶骇璁㈠崟',
- status: MesProWorkOrderStatusEnum.CONFIRMED,
- // 璁㈠崟鍙樻洿鏃舵竻绌虹敓浜т换鍔�
- onChange: () => formApi?.setFieldValue('taskId', undefined),
+ placeholder: '璇烽�夋嫨浜у搧鐗╂枡',
},
rules: 'selectRequired',
dependencies: {
triggerFields: ['sourceDocId'],
componentProps: (values) => ({
disabled: !!values.sourceDocId,
- placeholder: '璇烽�夋嫨鐢熶骇璁㈠崟',
- status: MesProWorkOrderStatusEnum.CONFIRMED,
- onChange: () => formApi?.setFieldValue('taskId', undefined),
+ placeholder: '璇烽�夋嫨浜у搧鐗╂枡',
}),
},
},
{
- fieldName: 'workstationId',
- label: '宸ヤ綅',
- component: markRaw(MdWorkstationSelect),
+ fieldName: 'batchCode',
+ label: '鎵瑰彿',
+ component: 'Input',
componentProps: {
- placeholder: '璇烽�夋嫨宸ヤ綅',
+ allowClear: true,
+ maxlength: 100,
+ placeholder: '璇疯緭鍏ユ壒鍙�',
},
- rules: 'selectRequired',
- dependencies: {
- triggerFields: ['sourceDocId'],
- componentProps: (values) => ({
- disabled: !!values.sourceDocId,
- placeholder: '璇烽�夋嫨宸ヤ綅',
- }),
- },
- },
- {
- fieldName: 'taskId',
- label: '鐢熶骇浠诲姟',
- component: markRaw(ProTaskSelect),
- componentProps: {
- placeholder: '璇烽�夋嫨鐢熶骇浠诲姟',
- statuses: [MesProTaskStatusEnum.PREPARE],
- },
- dependencies: {
- triggerFields: ['sourceDocId', 'workOrderId', 'workstationId'],
- componentProps: (values) => ({
- disabled: !!values.sourceDocId || !values.workOrderId,
- placeholder: '璇烽�夋嫨鐢熶骇浠诲姟',
- statuses: [MesProTaskStatusEnum.PREPARE],
- workOrderId: values.workOrderId,
- workstationId: values.workstationId,
- }),
- },
+ rules: 'required',
},
{
fieldName: 'templateId',
@@ -220,23 +183,22 @@
},
rules: 'selectRequired',
dependencies: {
- triggerFields: ['workOrderId', 'taskId'],
+ triggerFields: ['itemId'],
componentProps: (values) => ({
api: getTemplateItemOptionList,
autoSelect: 'first',
labelField: 'templateName',
valueField: 'templateId',
- disabled: formType !== 'create' || !values.workOrderId,
- params: values.workOrderId
+ disabled: formType !== 'create' || !values.itemId,
+ params: values.itemId
? {
qcType: 2,
- workOrderId: values.workOrderId,
- taskId: values.taskId,
+ itemId: values.itemId,
}
: {},
- placeholder: values.workOrderId
+ placeholder: values.itemId
? '璇烽�夋嫨璐ㄦ鏂规'
- : '璇峰厛閫夋嫨鐢熶骇璁㈠崟',
+ : '璇峰厛閫夋嫨浜у搧鐗╂枡',
}),
},
},
@@ -369,6 +331,57 @@
rules: 'required',
},
{
+ fieldName: 'samplingLocation',
+ label: '閲囨牱鍦扮偣',
+ component: 'Input',
+ componentProps: {
+ maxlength: 100,
+ placeholder: '璇疯緭鍏ラ噰鏍峰湴鐐�',
+ },
+ },
+ {
+ fieldName: 'certificateNo',
+ label: '璇佷功缂栧彿',
+ component: 'Input',
+ componentProps: {
+ maxlength: 50,
+ placeholder: '璇疯緭鍏ヨ瘉涔︾紪鍙�',
+ },
+ },
+ {
+ fieldName: 'executeStandard',
+ label: '鎵ц鏍囧噯',
+ component: 'Input',
+ componentProps: {
+ maxlength: 50,
+ placeholder: '濡� GB/T 6027锛岄�夋嫨璐ㄦ鏂规鍚庤嚜鍔ㄥ甫鍏�',
+ },
+ },
+ {
+ fieldName: 'auditUserId',
+ label: '澶嶆牳浜�',
+ component: 'ApiSelect',
+ componentProps: {
+ allowClear: true,
+ api: getSimpleUserList,
+ labelField: 'nickname',
+ placeholder: '璇烽�夋嫨澶嶆牳浜�',
+ valueField: 'id',
+ },
+ },
+ {
+ fieldName: 'approveUserId',
+ label: '瀹℃牳浜�',
+ component: 'ApiSelect',
+ componentProps: {
+ allowClear: true,
+ api: getSimpleUserList,
+ labelField: 'nickname',
+ placeholder: '璇烽�夋嫨瀹℃牳浜�',
+ valueField: 'id',
+ },
+ },
+ {
fieldName: 'checkResult',
label: '妫�娴嬬粨鏋�',
component: 'Select',
@@ -414,17 +427,18 @@
},
},
{
- fieldName: 'workOrderId',
- label: '鐢熶骇璁㈠崟',
- component: markRaw(ProWorkOrderSelect),
+ fieldName: 'batchCode',
+ label: '鎵瑰彿',
+ component: 'Input',
componentProps: {
- placeholder: '璇烽�夋嫨鐢熶骇璁㈠崟',
+ allowClear: true,
+ placeholder: '璇疯緭鍏ユ壒鍙�',
},
},
{
fieldName: 'itemId',
label: '浜у搧鐗╂枡',
- component: markRaw(MdItemSelect),
+ component: markRaw(MdmItemSelect),
componentProps: {
placeholder: '璇烽�夋嫨浜у搧鐗╂枡',
},
@@ -474,11 +488,6 @@
},
},
{
- field: 'workOrderCode',
- title: '鐢熶骇璁㈠崟缂栧彿',
- width: 140,
- },
- {
field: 'itemCode',
title: '浜у搧鐗╂枡缂栫爜',
width: 130,
@@ -492,6 +501,11 @@
field: 'itemSpecification',
title: '瑙勬牸鍨嬪彿',
width: 130,
+ },
+ {
+ field: 'batchCode',
+ title: '鎵瑰彿',
+ width: 140,
},
{
field: 'unitName',
@@ -513,6 +527,12 @@
},
},
{
+ field: 'indicatorResultSummary',
+ title: '妫�娴嬬粨鏋滐紙妫�楠岄」锛�',
+ minWidth: 200,
+ showOverflow: 'tooltip',
+ },
+ {
field: 'inspectDate',
title: '妫�娴嬫棩鏈�',
width: 120,
@@ -521,6 +541,16 @@
{
field: 'inspectorNickname',
title: '妫�娴嬩汉鍛�',
+ width: 100,
+ },
+ {
+ field: 'auditNickname',
+ title: '澶嶆牳浜�',
+ width: 100,
+ },
+ {
+ field: 'approveNickname',
+ title: '瀹℃牳浜�',
width: 100,
},
{
@@ -534,7 +564,7 @@
},
{
title: '鎿嶄綔',
- width: 180,
+ width: 420,
fixed: 'right',
slots: { default: 'actions' },
},
--
Gitblit v1.9.3