zhengyiming
2025-03-25 b11477657850db16d375f4789439a61e4cfa1a4a
packages/components/src/views/GasBillRecharge/GasBillRechargeStep3.vue
@@ -155,6 +155,7 @@
  remark: '',
  areaList: [] as string[],
  lifePayType: initLifePayType(props.isInWeChat, props.isInAlipay),
  name: '',
});
const { userAccountAllList, handleUserAccountChange } = useSetUserAccountBySelect({
@@ -169,6 +170,7 @@
    form.gasOrgType = currentUserAccount.operators;
    form.remark = currentUserAccount.remark;
    form.name = currentUserAccountExtraProperties.name ?? '';
    const gasParValueItem = gasParValueList.value.find((x) => x.gasOrgCode === form.gasOrgType);
    if (gasParValueItem && gasParValueItem.parValue.every((x) => Number(x) !== form.parValue)) {
      form.parValue = 0;
@@ -205,6 +207,11 @@
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) {
@@ -220,7 +227,7 @@
}
const { state, invokeAliPay, invokeWeixinPay } = useSelectPayType({
  getOpenId: props.getOpenId,
  getOpenId: toRef(props, 'getOpenId'),
  isInWeChat: toRef(props, 'isInWeChat'),
  isH5: toRef(props, 'isH5'),
  appId: toRef(props, 'appId'),
@@ -239,6 +246,7 @@
        gasAccount: form.gasAccount,
        province: form.areaList?.[0] ?? '',
        city: form.areaList?.[1] ?? '',
        name: form.name,
      },
    };
    let res = await blLifeRecharge.services.createLifePayGasOrder(params);