feat(recharge): add recharge package selection flow

- add new getRechargeOptions API endpoint in AigcApi
- replace CustomAmountCard with RechargePackageList component
- implement fetching and selection logic for recharge packages
- update UI to use correct recharge data fields
- add validation for selected recharge option
This commit is contained in:
duanshuwen
2026-07-13 10:27:03 +08:00
parent cadddb5c3f
commit 29bf6afe55
3 changed files with 58 additions and 15 deletions

View File

@@ -20,6 +20,10 @@ function getCurrentCredit() {
return request.get("/hotelBiz/credit/current", {});
}
function getRechargeOptions() {
return request.get("/hotelBiz/credit/recharge/options", {});
}
function rechargeCredit(args) {
return request.post("/hotelBiz/credit/recharge", args);
}
@@ -30,5 +34,6 @@ export {
getAigcGeneratorTaskList,
createAigcGeneratorTask,
getCurrentCredit,
getRechargeOptions,
rechargeCredit,
};