wupengfei
2 天以前 ddddcf83e7deb9d0a674d2bbead300089530d87e
packages/components/src/views/electricBillRecharge/ElectricBillRechargeStep2.vue
@@ -57,7 +57,9 @@
                {{ blLifeRecharge.getRechargeParValue(item, lifePayElectricRate) }}元
              </div>
            </div>
            <div class="discountTag">{{ lifePayElectricRate }}折</div>
            <div class="discountTag" v-if="lifePayElectricRate > 0">
              {{ lifePayElectricRate }}折
            </div>
          </div>
        </NutRadio>
      </NutRadioGroup>
@@ -138,6 +140,7 @@
const emit = defineEmits<{
  (e: 'goPay', orderNo: string): void;
  (e: 'paySuccess', orderNo: string): void;
  (e: 'missName', userAccountId: string): void;
}>();
const { goTo } = useElectricBillRechargeContext();
@@ -153,6 +156,7 @@
  currentUserAccountId: '',
  remark: '',
  lifePayType: initLifePayType(props.isInWeChat, props.isInAlipay),
  name: '',
});
const { userAccountAllList, handleUserAccountChange } = useSetUserAccountBySelect({
@@ -170,6 +174,7 @@
    form.electricAccountType = currentUserAccountExtraProperties.electricAccountType;
    form.sixID = currentUserAccountExtraProperties.sixID;
    form.remark = currentUserAccount.remark;
    form.name = currentUserAccountExtraProperties.name ?? '';
    const electricParValueItem = electricParValueList.value.find(
      (x) => x.cityName === form.province
    );
@@ -216,6 +221,10 @@
  if (!formRef.value) return;
  formRef.value.validate().then(({ valid, errors }: any) => {
    if (valid) {
      if (!form.name) {
        emit('missName', form.currentUserAccountId);
        return;
      }
      recharge();
    }
  });
@@ -228,10 +237,10 @@
}
const { state, invokeAliPay, invokeWeixinPay } = useSelectPayType({
  openId: toRef(props, 'openId'),
  isInWeChat: toRef(props, 'isInWeChat'),
  isH5: toRef(props, 'isH5'),
  appId: toRef(props, 'appId'),
  getOpenId: toRef(props, 'getOpenId'),
});
const currentOrderNo = ref('');
@@ -242,13 +251,14 @@
      userId: blLifeRecharge.accountModel.userId,
      channelId: blLifeRecharge.accountModel.channlesNum,
      productData: {
        parValue: props.isDev ? 0.1 : form.parValue,
        parValue: form.parValue,
        electricType: form.electricType,
        electricAccountType: form.electricAccountType,
        electricAccount: form.electricAccount,
        province: form.province,
        city: form.city,
        sixID: form.sixID,
        // name: form.name,
      },
    };
    let res = await blLifeRecharge.services.createLifePayElectricOrder(params);