🔧 chore(merge): Add advertising module and device settings

This commit is contained in:
web@ppanel
2025-02-27 13:40:57 +07:00
parent c2b858e3fe
commit 0130e02ffd
86 changed files with 2286 additions and 38 deletions
+1 -1
View File
@@ -1,5 +1,5 @@
// @ts-ignore
// API 更新时间:
// API 唯一标识:
import * as auth from './auth';
+1
View File
@@ -32,6 +32,7 @@ export async function appleLoginCallback(
return request<API.Response & { data?: any }>('/v1/auth/oauth/callback/apple', {
method: 'POST',
data: formData,
requestType: 'form',
...(options || {}),
});
}
+128
View File
@@ -1,4 +1,18 @@
declare namespace API {
type Ads = {
id: number;
title: string;
type: string;
content: string;
description: string;
target_url: string;
start_time: number;
end_time: number;
status: number;
created_at: number;
updated_at: number;
};
type Announcement = {
id: number;
title: string;
@@ -76,6 +90,17 @@ declare namespace API {
enabled: boolean;
};
type CheckoutOrderRequest = {
orderNo: string;
returnUrl?: string;
};
type CheckoutOrderResponse = {
type: string;
checkout_url?: string;
stripe?: StripePayment;
};
type CheckUserParams = {
email: string;
};
@@ -92,6 +117,10 @@ declare namespace API {
telephone: string;
};
type CloseOrderRequest = {
orderNo: string;
};
type Coupon = {
id: number;
name: string;
@@ -145,6 +174,10 @@ declare namespace API {
applications: ApplicationResponseInfo[];
};
type GetAvailablePaymentMethodsResponse = {
list: PaymentConfig[];
};
type GetGlobalConfigResponse = {
site: SiteConfig;
verify: VeifyConfig;
@@ -309,6 +342,20 @@ declare namespace API {
enable: boolean;
};
type PreOrderResponse = {
price: number;
amount: number;
discount: number;
gift_amount: number;
coupon: string;
coupon_discount: number;
fee_amount: number;
};
type PreRenewalOrderResponse = {
orderNo: string;
};
type PrivacyPolicyConfig = {
privacy_policy: string;
};
@@ -324,6 +371,61 @@ declare namespace API {
verify_code_interval: number;
};
type PurchaseOrderRequest = {
subscribe_id: number;
quantity: number;
payment: string;
coupon?: string;
};
type PurchaseOrderResponse = {
order_no: string;
};
type QueryAnnouncementRequest = {
page: number;
size: number;
pinned: boolean;
popup: boolean;
};
type QueryAnnouncementResponse = {
total: number;
announcements: Announcement[];
};
type QueryDocumentDetailRequest = {
id: number;
};
type QueryDocumentListResponse = {
total: number;
list: Document[];
};
type QueryOrderDetailRequest = {
order_no: string;
};
type QueryOrderListRequest = {
page: number;
size: number;
};
type QueryOrderListResponse = {
total: number;
list: OrderDetail[];
};
type RechargeOrderRequest = {
amount: number;
payment: string;
};
type RechargeOrderResponse = {
order_no: string;
};
type RegisterConfig = {
stop_register: boolean;
enable_trial: boolean;
@@ -335,6 +437,17 @@ declare namespace API {
ip_register_limit_duration: number;
};
type RenewalOrderRequest = {
user_subscribe_id: number;
quantity: number;
payment: string;
coupon?: string;
};
type RenewalOrderResponse = {
order_no: string;
};
type ResetPasswordRequest = {
email: string;
password: string;
@@ -342,6 +455,15 @@ declare namespace API {
cf_token?: string;
};
type ResetTrafficOrderRequest = {
user_subscribe_id: number;
payment: string;
};
type ResetTrafficOrderResponse = {
order_no: string;
};
type Response = {
/** 状态码 */
code?: number;
@@ -444,6 +566,12 @@ declare namespace API {
sort: number;
};
type StripePayment = {
method: string;
client_secret: string;
publishable_key: string;
};
type Subscribe = {
id: number;
name: string;
+14
View File
@@ -1,4 +1,18 @@
declare namespace API {
type Ads = {
id: number;
title: string;
type: string;
content: string;
description: string;
target_url: string;
start_time: number;
end_time: number;
status: number;
created_at: number;
updated_at: number;
};
type Announcement = {
id: number;
title: string;