| | |
| | | <template> |
| | | <ProDialog title="配置" v-model="innerVisible" @close="onDialogClose" destroy-on-close draggable> |
| | | <ProForm :model="innerForm" ref="dialogForm" label-width="100px"> |
| | | <ProDialog title="配置" v-model="visible" @close="onDialogClose" destroy-on-close draggable> |
| | | <ProForm :model="form" ref="dialogForm" label-width="100px"> |
| | | <ProFormItemV2 label="" prop="enterpriseConfigureType" label-width="0"> |
| | | <ProFormRadio |
| | | v-model="innerForm.enterpriseConfigureType" |
| | | v-model="form.enterpriseConfigureType" |
| | | :value-enum="EnterpriseConfigureTypeText" |
| | | buttonStyle |
| | | /> |
| | | </ProFormItemV2> |
| | | <template v-if="innerForm.enterpriseConfigureType === EnterpriseConfigureType.Bank"> |
| | | <!-- <template v-if="form.enterpriseConfigureType === EnterpriseConfigureType.Bank"> |
| | | <ProFormItemV2 label="开户总行:" prop="openBank"> |
| | | <ProFormText |
| | | v-model.trim="innerForm.openBank" |
| | | v-model.trim="form.openBank" |
| | | placeholder="请输入开户总行" |
| | | :maxlength="40" |
| | | /> |
| | | </ProFormItemV2> |
| | | <ProFormItemV2 label="开户支行:" prop="openBranchBank"> |
| | | <ProFormText |
| | | v-model.trim="innerForm.openBranchBank" |
| | | v-model.trim="form.openBranchBank" |
| | | placeholder="请输入开户支行" |
| | | :maxlength="40" |
| | | /> |
| | |
| | | { message: '银行账户仅支持数字', pattern: BoleRegExp.RegNumber }, |
| | | ]" |
| | | > |
| | | <ProFormText v-model.trim="innerForm.bankAccount" placeholder="请输入银行账户" /> |
| | | <ProFormText v-model.trim="form.bankAccount" placeholder="请输入银行账户" /> |
| | | </ProFormItemV2> |
| | | <ProFormItemV2 label="银行账户:" prop="verifyStatus"> |
| | | {{ VerifyStatusText[innerForm.verifyStatus] }} |
| | | {{ VerifyStatusText[form.verifyStatus] }} |
| | | <el-button style="margin-left: 40px" type="primary" link @click="handleCheckBankAccount" |
| | | >校验</el-button |
| | | > |
| | | </ProFormItemV2> |
| | | </template> |
| | | <template v-if="innerForm.enterpriseConfigureType === EnterpriseConfigureType.Electronic"> |
| | | </template> --> |
| | | <template v-if="form.enterpriseConfigureType === EnterpriseConfigureType.Electronic"> |
| | | <div class="configure-dialog-form-title">通道配置</div> |
| | | <ProFormItemV2 |
| | | label="名称:" |
| | | prop="signChannel" |
| | | prop="realAccess" |
| | | :checkRules="[{ message: '请选择电子签通道' }]" |
| | | > |
| | | <ProFormSelect |
| | | v-model="form.signChannel" |
| | | :valueEnum="SignChannelEnumText" |
| | | v-model="form.realAccess" |
| | | :valueEnum="EnumRealAccessText" |
| | | placeholder="请选择电子签通道" |
| | | > |
| | | </ProFormSelect> |
| | |
| | | > |
| | | <ProFormRadio |
| | | :button-style="false" |
| | | v-model="innerForm.chargeType" |
| | | v-model="form.chargeType" |
| | | :value-enum="ChargeTypeEnumText" |
| | | /> |
| | | </ProFormItemV2> |
| | | <template v-if="innerForm.chargeType === ChargeTypeEnum.Group"> |
| | | <template v-if="form.chargeType === ChargeTypeEnum.Group"> |
| | | <ProFormItemV2 label="实名费用:" prop="realVerifyCost"> |
| | | <ProFormInputNumber |
| | | :controls="false" |
| | | v-model="innerForm.realVerifyCost" |
| | | v-model="form.realVerifyCost" |
| | | placeholder="请输入" |
| | | unit="元/条" |
| | | /> |
| | |
| | | <ProFormItemV2 label="签约费用:" prop="signCost"> |
| | | <ProFormInputNumber |
| | | :controls="false" |
| | | v-model="innerForm.signCost" |
| | | v-model="form.signCost" |
| | | placeholder="请输入" |
| | | unit="元/份" |
| | | /> |
| | | </ProFormItemV2> |
| | | </template> |
| | | <template v-if="innerForm.chargeType === ChargeTypeEnum.Merge"> |
| | | <template v-if="form.chargeType === ChargeTypeEnum.Merge"> |
| | | <ProFormItemV2 label="统一电子签:" prop="mergeSignCost"> |
| | | <ProFormInputNumber |
| | | :controls="false" |
| | | v-model="innerForm.mergeSignCost" |
| | | v-model="form.mergeSignCost" |
| | | placeholder="请输入" |
| | | unit="元/份" |
| | | /> |
| | | </ProFormItemV2> |
| | | </template> |
| | | </template> |
| | | <template v-if="innerForm.enterpriseConfigureType === EnterpriseConfigureType.ShortMessage"> |
| | | <div class="configure-dialog-form-title">通道配置</div> |
| | | <template v-if="form.enterpriseConfigureType === EnterpriseConfigureType.ShortMessage"> |
| | | <!-- <div class="configure-dialog-form-title">通道配置</div> |
| | | <ProFormItemV2 |
| | | label="名称:" |
| | | prop="messageChannel" |
| | |
| | | > |
| | | <ProFormSelect |
| | | v-model="form.messageChannel" |
| | | :valueEnum="MessageChannelEnumText" |
| | | :valueEnum="EnumSmsAccessText" |
| | | placeholder="请选择短信通道" |
| | | > |
| | | </ProFormSelect> |
| | | </ProFormItemV2> |
| | | </ProFormItemV2> --> |
| | | <div class="configure-dialog-form-title">费用配置</div> |
| | | <ProFormItemV2 label="短信费用:" prop="messageCost"> |
| | | <ProFormItemV2 label="短信费用:" prop="smsCost"> |
| | | <ProFormInputNumber |
| | | :controls="false" |
| | | v-model="innerForm.messageCost" |
| | | v-model="form.smsCost" |
| | | placeholder="请输入" |
| | | unit="元/条" |
| | | /> |
| | |
| | | EnterpriseConfigureTypeText, |
| | | ChargeTypeEnum, |
| | | ChargeTypeEnumText, |
| | | SignChannelEnum, |
| | | SignChannelEnumText, |
| | | EnumRealAccessText, |
| | | VerifyStatusText, |
| | | VerifyStatus, |
| | | MessageChannelEnum, |
| | | MessageChannelEnumText, |
| | | EnumSmsAccessText, |
| | | EnumRealAccess, |
| | | } from '@/constants'; |
| | | |
| | | defineOptions({ |
| | | name: 'ConfigureDialog', |
| | | }); |
| | | |
| | | type Props = { |
| | | modelValue: boolean; |
| | | form?: { |
| | | enterpriseConfigureType: EnterpriseConfigureType; |
| | | openBank: string; |
| | | openBranchBank: string; |
| | | bankAccount: string; |
| | | verifyStatus: VerifyStatus; |
| | | signChannel: SignChannelEnum; |
| | | chargeType: ChargeTypeEnum; |
| | | realVerifyCost: number; |
| | | signCost: number; |
| | | mergeSignCost: number; |
| | | messageCost: number; |
| | | messageChannel: MessageChannelEnum; |
| | | }; |
| | | type Form = { |
| | | enterpriseConfigureType: EnterpriseConfigureType; |
| | | // openBank: string; |
| | | // openBranchBank: string; |
| | | // bankAccount: string; |
| | | // verifyStatus: VerifyStatus; |
| | | chargeType: ChargeTypeEnum; |
| | | realAccess: EnumRealAccess; |
| | | realVerifyCost: number; |
| | | signCost: number; |
| | | mergeSignCost: number; |
| | | smsAccess: EnumSmsAccess; |
| | | smsCost: number; |
| | | }; |
| | | |
| | | const props = withDefaults(defineProps<Props>(), { |
| | | modelValue: false, |
| | | }); |
| | | const form = defineModel<Form>('form'); |
| | | const visible = defineModel({ type: Boolean }); |
| | | |
| | | const emit = defineEmits<{ |
| | | (e: 'update:modelValue', value: boolean): void; |
| | | (e: 'update:form', value: Props['form']): void; |
| | | (e: 'onConfirm'): void; |
| | | (e: 'onCancel'): void; |
| | | }>(); |
| | | |
| | | const dialogForm = ref<FormInstance>(); |
| | | |
| | | const innerVisible = computed({ |
| | | get() { |
| | | return props.modelValue; |
| | | }, |
| | | set(val) { |
| | | emit('update:modelValue', val); |
| | | }, |
| | | }); |
| | | |
| | | const innerForm = computed({ |
| | | get() { |
| | | return props.form; |
| | | }, |
| | | set(val) { |
| | | emit('update:form', val); |
| | | }, |
| | | }); |
| | | |
| | | function handleCheckBankAccount() {} |
| | | |