From 409d4257a184e6333e70751ac87fe71702adbfad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=BC=A0=E5=90=8C=E6=B5=B7?= <14166000+zhangtonghai@user.noreply.gitee.com> Date: Mon, 14 Oct 2024 10:53:12 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E5=AE=A2=E6=88=B7=20=E5=AE=A2=E6=88=B7?= =?UTF-8?q?=E5=B1=9E=E6=80=A7=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/baseinfo/infoclient/TenantAuditStepModal.vue | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/views/baseinfo/infoclient/TenantAuditStepModal.vue b/src/views/baseinfo/infoclient/TenantAuditStepModal.vue index 328c65fc..e0c0621d 100644 --- a/src/views/baseinfo/infoclient/TenantAuditStepModal.vue +++ b/src/views/baseinfo/infoclient/TenantAuditStepModal.vue @@ -415,13 +415,12 @@ 'isContract', ] if (CustomerOrSupplier.value == 'isCustomer') { - console.log('客户') updateSchema({ label: '客户属性', field: 'ArrclientTag', component: 'ApiSelect', colProps: { span: 12 }, - defaultValue: 'isController', + defaultValue: ['isController'], componentProps: () => { return { api: () => { @@ -446,8 +445,8 @@ } }, }) + setFieldsValue({ ArrclientTag: ['isController'] }) } else if (CustomerOrSupplier.value == 'isSupplier') { - console.log('供应商') updateSchema({ label: '客户属性', field: 'ArrclientTag', @@ -478,14 +477,14 @@ } }, }) + setFieldsValue({ ArrclientTag: [] }) } else if (CustomerOrSupplier.value == 'isCustomerAndisSupplier') { - console.log('供应商及客户') updateSchema({ label: '客户属性', field: 'ArrclientTag', component: 'ApiSelect', colProps: { span: 12 }, - defaultValue: 'isController', + defaultValue: ['isController'], componentProps: ({ formModel }) => { return { api: () => { @@ -504,6 +503,7 @@ } }, }) + setFieldsValue({ ArrclientTag: ['isController'] }) } } function ChangeCustomerOrSupplier() { From b2660508d27ee8ed05effcef3d6cc0d864e6100a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=BC=A0=E5=90=8C=E6=B5=B7?= <14166000+zhangtonghai@user.noreply.gitee.com> Date: Mon, 14 Oct 2024 12:03:49 +0800 Subject: [PATCH 2/3] =?UTF-8?q?=E5=AE=A2=E6=88=B7=20=E5=B9=B2=E7=B3=BB?= =?UTF-8?q?=E4=BA=BA=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../TenantAuditStepModal.vue | 9 ++-- .../infoclient/ClientStakeholder/api.ts | 8 ++-- .../infoclient/ClientStakeholder/columns.tsx | 45 +++++++++++++++++-- .../infoclient/ClientStakeholder/index.vue | 25 ++++++++--- 4 files changed, 70 insertions(+), 17 deletions(-) diff --git a/src/views/baseinfo/infoclient/ClientStakeholder/TenantAuditStepModal.vue b/src/views/baseinfo/infoclient/ClientStakeholder/TenantAuditStepModal.vue index 2c05ca94..3527187c 100644 --- a/src/views/baseinfo/infoclient/ClientStakeholder/TenantAuditStepModal.vue +++ b/src/views/baseinfo/infoclient/ClientStakeholder/TenantAuditStepModal.vue @@ -3,7 +3,7 @@ v-bind="$attrs" :use-wrapper="true" :title="getTitle" - width="60%" + width="30%" @register="registerModal" @ok="handleSave" > @@ -57,6 +57,8 @@ }) const [registerModal, { setModalProps, closeModal }] = useModalInner(async (data) => { + console.log(data) + resetFields() setModalProps({ confirmLoading: false, loading: true }) isUpdate.value = !!data?.isUpdate @@ -68,12 +70,9 @@ setFieldsValue({ ...res.data, }) - // console.log('返回数据Form', getFieldsValue()); - // setFieldsValue({ trainId: unref(res.data.trainId) }); } - // setModalProps({ confirmLoading: false }); } else { - setFieldsValue({ permissionIdentity: unref(2) }) + setFieldsValue({ clientId: data.clientId }) } setModalProps({ loading: false }) }) diff --git a/src/views/baseinfo/infoclient/ClientStakeholder/api.ts b/src/views/baseinfo/infoclient/ClientStakeholder/api.ts index c2904cd6..508f8555 100644 --- a/src/views/baseinfo/infoclient/ClientStakeholder/api.ts +++ b/src/views/baseinfo/infoclient/ClientStakeholder/api.ts @@ -33,12 +33,12 @@ export function ApiGet(query) { params: query, }) } -// 获取客户干系人 (Auth) -export function ApiEdit(query) { +// 更新客户干系人 (Auth) +export function ApiEdit(data) { return request({ url: Api.edit, - method: 'get', - params: query, + method: 'post', + data, }) } // 详情 (Auth) diff --git a/src/views/baseinfo/infoclient/ClientStakeholder/columns.tsx b/src/views/baseinfo/infoclient/ClientStakeholder/columns.tsx index defd34ee..d8a0a4ff 100644 --- a/src/views/baseinfo/infoclient/ClientStakeholder/columns.tsx +++ b/src/views/baseinfo/infoclient/ClientStakeholder/columns.tsx @@ -1,4 +1,5 @@ import { BasicColumn, FormSchema } from '/@/components/Table' +import { GetUserList } from '/@/api/common' export const columns: BasicColumn[] = [ { @@ -45,20 +46,57 @@ export const formSchema: FormSchema[] = [ show: false, }, { - field: 'carrierId', label: '', + field: 'clientId', component: 'Input', show: false, }, + { + label: '干系人Name', + field: 'createByName', + component: 'Input', + show: false, + }, + { + label: '干系人', + field: 'createBy', + component: 'ApiSelect', + required: false, + defaultValue: null, + dynamicDisabled: false, + colProps: { span: 24 }, + componentProps: ({ formModel }) => { + return { + api: GetUserList, + labelField: 'label', + valueField: 'value', + resultField: 'data', + getPopupContainer: () => document.body, + onChange: (e, obj) => { + if (e && obj) { + console.log(e, obj) + formModel.createBy = obj.value + formModel.createByName = obj.label + } + if (!e && !obj) { + formModel.createBy = '' + formModel.createByName = '' + } + }, + } + }, + }, + { field: 'startDate', label: '生效日期', component: 'DatePicker', required: true, - colProps: { span: 20 }, + colProps: { span: 24 }, defaultValue: '', componentProps: { style: 'width:100%', + getPopupContainer: () => document.body, }, }, { @@ -66,10 +104,11 @@ export const formSchema: FormSchema[] = [ label: '失效日期', component: 'DatePicker', required: true, - colProps: { span: 20 }, + colProps: { span: 24 }, defaultValue: '', componentProps: { style: 'width:100%', + getPopupContainer: () => document.body, }, }, { diff --git a/src/views/baseinfo/infoclient/ClientStakeholder/index.vue b/src/views/baseinfo/infoclient/ClientStakeholder/index.vue index fdfa400a..868012f5 100644 --- a/src/views/baseinfo/infoclient/ClientStakeholder/index.vue +++ b/src/views/baseinfo/infoclient/ClientStakeholder/index.vue @@ -1,15 +1,16 @@ --> + + From 06e15e3c0dd3514d624bacbe0d6313ac30eba3cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=BC=A0=E5=90=8C=E6=B5=B7?= <14166000+zhangtonghai@user.noreply.gitee.com> Date: Mon, 14 Oct 2024 14:39:14 +0800 Subject: [PATCH 3/3] =?UTF-8?q?=E5=B7=A5=E4=BD=9C=E6=B5=81=E6=A8=A1?= =?UTF-8?q?=E6=9D=BF=20=20=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/baseinfo/clientflowtemplate/columns.tsx | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/src/views/baseinfo/clientflowtemplate/columns.tsx b/src/views/baseinfo/clientflowtemplate/columns.tsx index c2d11516..8bc7326b 100644 --- a/src/views/baseinfo/clientflowtemplate/columns.tsx +++ b/src/views/baseinfo/clientflowtemplate/columns.tsx @@ -92,17 +92,16 @@ export const formSchema: FormSchema[] = [ { field: 'status', label: '是否启用', - component: 'RadioButtonGroup', - defaultValue: 1, - colProps: { span: 12 }, + component: 'Switch', + colProps: { span: 6 }, + defaultValue: 0, componentProps: { - options: [ - { label: '是', value: 0 }, - { label: '否', value: 1 }, - ], + checkedChildren: '启用', + checkedValue: 0, + unCheckedChildren: '禁用', + unCheckedValue: 1, }, }, - { field: 'columnView', label: '关联表',