| | |
| | | :isFocus="isFocus" |
| | | :showAliPay="!isInWeChat" |
| | | :showWeixinPay="isInWeChat" |
| | | @missName="handleMissName" |
| | | /> |
| | | </ContentScrollView> |
| | | </template> |
| | |
| | | import { isInAlipay, isInWeChat, isH5, isWeb } from '@/utils/env'; |
| | | import { useUser, useFocus, useEnsureOpenId } from '@/hooks'; |
| | | import { WXPayAppId } from '@/constants'; |
| | | import { Message } from '@/utils'; |
| | | |
| | | defineOptions({ |
| | | name: 'InnerPage', |
| | |
| | | url: `${RouterPath.rechargeResult}?orderNo=${orderNo}&lifePayOrderType=${BlLifeRecharge.constants.LifePayOrderTypeEnum.电费订单}`, |
| | | }); |
| | | } |
| | | |
| | | async function handleMissName(userAccountId: string) { |
| | | try { |
| | | await Message.confirm({ message: '请先完善手机号所属机主姓名' }); |
| | | RouteHelper.navigateTo({ |
| | | url: `${RouterPath.editElectricUserAccount}?id=${userAccountId}`, |
| | | }); |
| | | } catch (error) {} |
| | | } |
| | | </script> |
| | |
| | | :isFocus="isFocus" |
| | | :showAliPay="!isInWeChat" |
| | | :showWeixinPay="isInWeChat" |
| | | @missName="handleMissName" |
| | | /> |
| | | </ContentScrollView> |
| | | </template> |
| | |
| | | import { isInAlipay, isInWeChat, isH5, isWeb } from '@/utils/env'; |
| | | import { useUser, useFocus, useEnsureOpenId } from '@/hooks'; |
| | | import { WXPayAppId } from '@/constants'; |
| | | import { Message } from '@/utils'; |
| | | |
| | | defineOptions({ |
| | | name: 'InnerPage', |
| | |
| | | url: `${RouterPath.rechargeResult}?orderNo=${orderNo}&lifePayOrderType=${BlLifeRecharge.constants.LifePayOrderTypeEnum.燃气订单}`, |
| | | }); |
| | | } |
| | | |
| | | async function handleMissName(userAccountId: string) { |
| | | try { |
| | | await Message.confirm({ message: '请先完善手机号所属机主姓名' }); |
| | | RouteHelper.navigateTo({ |
| | | url: `${RouterPath.editGasUserAccount}?id=${userAccountId}`, |
| | | }); |
| | | } catch (error) {} |
| | | } |
| | | </script> |
| | |
| | | v-bind="props" |
| | | @go-pay="emit('goPay', $event)" |
| | | @paySuccess="emit('paySuccess', $event)" |
| | | @missName="emit('missName', $event)" |
| | | /> |
| | | </template> |
| | | |
| | |
| | | const emit = defineEmits<{ |
| | | (e: 'goPay', orderNo: string): void; |
| | | (e: 'paySuccess', orderNo: string): void; |
| | | (e: 'missName', userAccountId: string): void; |
| | | }>(); |
| | | |
| | | const preSetForm = reactive({ |
| | |
| | | gasAccount: '', |
| | | remark: '', |
| | | areaList: [] as string[], |
| | | name: '', |
| | | }); |
| | | |
| | | provide(GasBillRechargeContextKey, { |
| | |
| | | const emit = defineEmits<{ |
| | | (e: 'goPay', orderNo: string): void; |
| | | (e: 'paySuccess', orderNo: string): void; |
| | | (e: 'missName', userAccountId: string): void; |
| | | }>(); |
| | | |
| | | const { goTo } = useGasBillRechargeContext(); |
| | |
| | | const formRef = ref<any>(null); |
| | | |
| | | function handleSubmit() { |
| | | if (!form.name) { |
| | | state.show = true; |
| | | state.msg = '请先完善所属户主姓名'; |
| | | return; |
| | | } |
| | | if (!formRef.value) return; |
| | | formRef.value.validate().then(({ valid, errors }: any) => { |
| | | if (valid) { |
| | | if (!form.name) { |
| | | emit('missName', form.currentUserAccountId); |
| | | return; |
| | | } |
| | | recharge(); |
| | | } |
| | | }); |
| | |
| | | const emit = defineEmits<{ |
| | | (e: 'goPay', orderNo: string): void; |
| | | (e: 'paySuccess', orderNo: string): void; |
| | | (e: 'missName', userAccountId: string): void; |
| | | }>(); |
| | | |
| | | const { goTo } = useElectricBillRechargeContext(); |
| | |
| | | const formRef = ref<any>(null); |
| | | |
| | | function handleSubmit() { |
| | | if (!form.name) { |
| | | state.show = true; |
| | | state.msg = '请先完善所属户主姓名'; |
| | | return; |
| | | } |
| | | if (!formRef.value) return; |
| | | formRef.value.validate().then(({ valid, errors }: any) => { |
| | | if (valid) { |
| | | if (!form.name) { |
| | | emit('missName', form.currentUserAccountId); |
| | | return; |
| | | } |
| | | recharge(); |
| | | } |
| | | }); |
| | |
| | | v-bind="props" |
| | | @go-pay="emit('goPay', $event)" |
| | | @paySuccess="emit('paySuccess', $event)" |
| | | @missName="emit('missName', $event)" |
| | | /> |
| | | </template> |
| | | |
| | |
| | | const emit = defineEmits<{ |
| | | (e: 'goPay', orderNo: string): void; |
| | | (e: 'paySuccess', orderNo: string): void; |
| | | (e: 'missName', userAccountId: string): void; |
| | | }>(); |
| | | |
| | | const stepperInfo = useStepper(['step1', 'step2'], 'step2'); |