| | |
| | | </ProFormItemV2> |
| | | </ProFormColItem> |
| | | <ProFormColItem :span="8"> |
| | | <ProFormItemV2 |
| | | label="所在地区:" |
| | | prop="areaList" |
| | | :check-rules="[ |
| | | { |
| | | type: 'array', |
| | | message: '请选择所在地区', |
| | | }, |
| | | ]" |
| | | > |
| | | <ProFormItemV2 label="所在地区:" prop="areaList"> |
| | | <ProFromAddressSelectV2 |
| | | v-model:areaList="form.areaList" |
| | | areaListPlaceholder="请选择所在地区" |
| | |
| | | </ProFormItemV2> |
| | | </ProFormColItem> |
| | | </ProFormCol> |
| | | <ProFormCol> |
| | | <ProFormColItem :span="8"> |
| | | <ProFormItemV2 label="服务费收取方式:" prop="serviceFeeCollectType"> |
| | | <ProFormSelect |
| | | v-model="form.serviceFeeCollectType" |
| | | :valueEnum="EnumEnterpriseCooperationServiceFeeCollectTypeText" |
| | | placeholder="请选择服务费收取方式" |
| | | > |
| | | </ProFormSelect> |
| | | </ProFormItemV2> |
| | | </ProFormColItem> |
| | | <ProFormColItem :span="8"> |
| | | <ProFormItemV2 |
| | | label="服务费:" |
| | | prop="serviceFeeRate" |
| | | :check-rules=" |
| | | form.serviceFeeCollectType ? [{ message: '请输入服务费' }] : undefined |
| | | " |
| | | :required="!!form.serviceFeeCollectType" |
| | | > |
| | | <ProFormInputNumber |
| | | v-model="form.serviceFeeRate" |
| | | :controls="false" |
| | | :min="0" |
| | | :precision="2" |
| | | placeholder="请输入" |
| | | :unit="serviceFeeCollectTypeUnit" |
| | | :showReadContent="!!form.serviceFeeRate" |
| | | /> |
| | | </ProFormItemV2> |
| | | </ProFormColItem> |
| | | </ProFormCol> |
| | | <ProFormCol> |
| | | <ProFormColItem :span="8"> |
| | | <ProFormItemV2 label="发票税点:" prop="invoiceTaxPointRate"> |
| | | <ProFormInputNumber |
| | | v-model="form.invoiceTaxPointRate" |
| | | :controls="false" |
| | | :min="0" |
| | | :precision="2" |
| | | placeholder="请输入" |
| | | unit="%" |
| | | :showReadContent="!!form.invoiceTaxPointRate" |
| | | /> |
| | | </ProFormItemV2> |
| | | </ProFormColItem> |
| | | </ProFormCol> |
| | | </ProForm> |
| | | </ChunkCell> |
| | | <ChunkCell title="账号信息"> |
| | |
| | | prop="operatorPassword" |
| | | :check-rules="[ |
| | | { |
| | | required: false, |
| | | message: '请输入6位数字', |
| | | pattern: /\b\d{6}\b/, |
| | | }, |
| | |
| | | ProFormRadio, |
| | | UploadUserFile, |
| | | useFormDialog, |
| | | ProFormSelect, |
| | | ProFormInputNumber, |
| | | } from '@bole-core/components'; |
| | | import { FormInstance } from 'element-plus'; |
| | | import * as enterpriseServices from '@/services/api/enterprise'; |
| | |
| | | import { |
| | | EnumEnterpriseCooperationStatusText, |
| | | EnumEnterpriseCooperationSignStatusText, |
| | | EnumEnterpriseCooperationServiceFeeCollectTypeText, |
| | | EnumEnterpriseCooperationServiceFeeCollectType, |
| | | } from '@/constants'; |
| | | import { |
| | | validateFormList, |
| | |
| | | operatorPassword: '', |
| | | |
| | | userId: '', |
| | | |
| | | serviceFeeCollectType: '' as any as EnumEnterpriseCooperationServiceFeeCollectType, |
| | | serviceFeeRate: null as any as number, |
| | | invoiceTaxPointRate: null as any as number, |
| | | }); |
| | | |
| | | const { isLoading, refetch } = useQuery({ |
| | |
| | | form.userName = data.userName; |
| | | |
| | | form.userId = data.userId; |
| | | form.serviceFeeCollectType = data.serviceFeeCollectType; |
| | | form.serviceFeeRate = data.serviceFeeRate; |
| | | form.invoiceTaxPointRate = data.invoiceTaxPointRate; |
| | | }, |
| | | enabled: computed(() => !!id), |
| | | }); |
| | | |
| | | const serviceFeeCollectTypeUnit = computed(() => { |
| | | if (!form.serviceFeeCollectType) { |
| | | return ''; |
| | | } else { |
| | | return form.serviceFeeCollectType === EnumEnterpriseCooperationServiceFeeCollectType.Rate |
| | | ? '%' |
| | | : '元/人'; |
| | | } |
| | | }); |
| | | |
| | | const { |
| | |
| | | userName: form.userName, |
| | | password: form.password, |
| | | operatorPassword: form.operatorPassword, |
| | | serviceFeeCollectType: form.serviceFeeCollectType, |
| | | invoiceTaxPointRate: form.invoiceTaxPointRate, |
| | | }; |
| | | if (form.serviceFeeCollectType === EnumEnterpriseCooperationServiceFeeCollectType.Rate) { |
| | | params.serviceFeeRate = form.serviceFeeRate; |
| | | } |
| | | if (isEdit) { |
| | | params.id = id; |
| | | } |