zhengyiming
2025-03-25 dca624a7e4c877dc4bfd8c496a6c2a6b29ad4b46
fix: 四期需求
9个文件已修改
46 ■■■■■ 已修改文件
packages/components/src/views/GasBillRecharge/GasBillRechargeBaseForm.vue 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
packages/components/src/views/GasBillRecharge/GasBillRechargeStep3.vue 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
packages/components/src/views/GasBillRecharge/context.ts 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
packages/components/src/views/RechargeGrid/RechargeGrid.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
packages/components/src/views/electricBillRecharge/ElectricBillRechargeBaseForm.vue 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
packages/components/src/views/electricBillRecharge/ElectricBillRechargeStep2.vue 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
packages/components/src/views/electricBillRecharge/context.ts 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
packages/components/src/views/userAccount/EditElectricUserAccount.vue 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
packages/components/src/views/userAccount/EditGasUserAccount.vue 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
packages/components/src/views/GasBillRecharge/GasBillRechargeBaseForm.vue
@@ -23,6 +23,14 @@
        max-length="13"
      />
    </NutFormItem>
    <NutFormItem label="户主姓名" class="bole-form-item" prop="name" required>
      <NutInput
        v-model.trim="form.name"
        class="bole-input-text"
        placeholder="请填写户主姓名"
        type="text"
      />
    </NutFormItem>
    <slot></slot>
  </NutForm>
</template>
@@ -46,6 +54,7 @@
  // city: string;
  gasAccount: string;
  areaList: string[];
  name: string;
}>('form');
const rules = reactive<FormRules>({
@@ -56,6 +65,7 @@
  areaList: [
    { required: true, message: '请选择所在城市', validator: FormValidator.validatorArray },
  ],
  name: [{ required: true, message: '请填写户主姓名' }],
});
const formRef = ref<any>(null);
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) {
@@ -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);
packages/components/src/views/GasBillRecharge/context.ts
@@ -26,4 +26,5 @@
  gasAccount: string;
  remark: string;
  areaList: string[];
  name: string;
};
packages/components/src/views/RechargeGrid/RechargeGrid.vue
@@ -9,10 +9,10 @@
        <img :src="IconFreeDian" class="recharge-grid-item-icon" />
        <div class="discountTag">{{ lifePayElectricRate }}折</div>
      </GridItem>
      <!-- <GridItem class="recharge-grid-item" text="燃气" @click="emit('gasBillRecharge')">
      <GridItem class="recharge-grid-item" text="燃气" @click="emit('gasBillRecharge')">
        <img :src="IconFreeGas" class="recharge-grid-item-icon" />
        <div class="discountTag">{{ lifePayGasRate }}折</div>
      </GridItem> -->
      </GridItem>
    </Grid>
  </MainCell>
</template>
packages/components/src/views/electricBillRecharge/ElectricBillRechargeBaseForm.vue
@@ -61,6 +61,14 @@
        max-length="6"
      />
    </NutFormItem>
    <NutFormItem label="户主姓名" class="bole-form-item" prop="name" required>
      <NutInput
        v-model.trim="form.name"
        class="bole-input-text"
        placeholder="请填写户主姓名"
        type="text"
      />
    </NutFormItem>
    <slot />
  </NutForm>
</template>
@@ -85,6 +93,7 @@
  province: string;
  city: string;
  sixID: string;
  name: string;
}>('form');
const { electricParValueList } = useGetElectricParValue();
@@ -118,6 +127,7 @@
      validator: FormValidator.validatorIDNumberSix,
    },
  ],
  name: [{ required: true, message: '请填写户主姓名' }],
});
const formRef = ref<any>(null);
packages/components/src/views/electricBillRecharge/ElectricBillRechargeStep2.vue
@@ -153,6 +153,7 @@
  currentUserAccountId: '',
  remark: '',
  lifePayType: initLifePayType(props.isInWeChat, props.isInAlipay),
  name: '',
});
const { userAccountAllList, handleUserAccountChange } = useSetUserAccountBySelect({
@@ -170,6 +171,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
    );
@@ -213,6 +215,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) {
@@ -249,6 +256,7 @@
        province: form.province,
        city: form.city,
        sixID: form.sixID,
        name: form.name,
      },
    };
    let res = await blLifeRecharge.services.createLifePayElectricOrder(params);
packages/components/src/views/electricBillRecharge/context.ts
@@ -34,4 +34,5 @@
  city: string;
  sixID: string;
  remark: string;
  name: string;
};
packages/components/src/views/userAccount/EditElectricUserAccount.vue
@@ -75,6 +75,7 @@
    form.electricType = currentUserAccountExtraProperties.electricType;
    form.electricAccountType = currentUserAccountExtraProperties.electricAccountType;
    form.sixID = currentUserAccountExtraProperties.sixID;
    form.name = currentUserAccountExtraProperties.name ?? '';
    form.remark = data.remark;
  },
  enabled: computed(() => !!props.id),
@@ -88,6 +89,7 @@
  city: '',
  sixID: '',
  remark: '',
  name: '',
});
const formRef = ref<any>(null);
packages/components/src/views/userAccount/EditGasUserAccount.vue
@@ -87,6 +87,7 @@
    form.gasOrgType = data.operators as any;
    form.remark = data.remark;
    form.name = currentUserAccountExtraProperties.name ?? '';
  },
  enabled: computed(() => !!props.id),
});
@@ -98,6 +99,7 @@
  gasAccount: '',
  remark: '',
  areaList: [] as string[],
  name: '',
});
const formRef = ref<any>(null);