feat: 接入微信小程序支付
This commit is contained in:
@@ -78,7 +78,12 @@ export type ProfileWalletLedgerResponse = {
|
||||
export type ProfileRechargeProductKind = 'points' | 'membership';
|
||||
export type ProfileMembershipStatus = 'normal' | 'active';
|
||||
export type ProfileMembershipTier = 'normal' | 'month' | 'season' | 'year';
|
||||
export type ProfileRechargeOrderStatus = 'paid';
|
||||
export type ProfileRechargeOrderStatus =
|
||||
| 'pending'
|
||||
| 'paid'
|
||||
| 'failed'
|
||||
| 'closed'
|
||||
| 'refunded';
|
||||
|
||||
export type ProfileRechargeProduct = {
|
||||
productId: string;
|
||||
@@ -117,7 +122,8 @@ export type ProfileRechargeOrder = {
|
||||
amountCents: number;
|
||||
status: ProfileRechargeOrderStatus;
|
||||
paymentChannel: string;
|
||||
paidAt: string;
|
||||
paidAt: string | null;
|
||||
providerTransactionId: string | null;
|
||||
createdAt: string;
|
||||
pointsDelta: number;
|
||||
membershipExpiresAt: string | null;
|
||||
@@ -133,6 +139,14 @@ export type ProfileRechargeCenterResponse = {
|
||||
hasPointsRecharged: boolean;
|
||||
};
|
||||
|
||||
export type WechatMiniProgramPayParams = {
|
||||
timeStamp: string;
|
||||
nonceStr: string;
|
||||
package: string;
|
||||
signType: 'RSA';
|
||||
paySign: string;
|
||||
};
|
||||
|
||||
export type CreateProfileRechargeOrderRequest = {
|
||||
productId: string;
|
||||
paymentChannel?: string;
|
||||
@@ -141,6 +155,7 @@ export type CreateProfileRechargeOrderRequest = {
|
||||
export type CreateProfileRechargeOrderResponse = {
|
||||
order: ProfileRechargeOrder;
|
||||
center: ProfileRechargeCenterResponse;
|
||||
wechatMiniProgramPayParams?: WechatMiniProgramPayParams | null;
|
||||
};
|
||||
|
||||
export type ProfileFeedbackStatus = 'open';
|
||||
|
||||
Reference in New Issue
Block a user