- Wails v2.16.0 + React 19 + TypeScript + Vite 7 - 插件系统(build tag 控制编译,plugin.json 运行时配置) - 支付插件(授权、账号、订单、退款、账单) - 高并发基础设施(任务池、批量处理器、限流器、环形缓冲、管道) - Windows 系统托盘(Win32 API) - CodeGraph 索引 + .memory 记忆包 - 默认图标 assets/icon.png
40 lines
904 B
TypeScript
40 lines
904 B
TypeScript
export namespace main {
|
|
|
|
export class Response {
|
|
code: number;
|
|
message: string;
|
|
data?: any;
|
|
|
|
static createFrom(source: any = {}) {
|
|
return new Response(source);
|
|
}
|
|
|
|
constructor(source: any = {}) {
|
|
if ('string' === typeof source) source = JSON.parse(source);
|
|
this.code = source["code"];
|
|
this.message = source["message"];
|
|
this.data = source["data"];
|
|
}
|
|
}
|
|
export class User {
|
|
id: number;
|
|
name: string;
|
|
email: string;
|
|
created_at: string;
|
|
|
|
static createFrom(source: any = {}) {
|
|
return new User(source);
|
|
}
|
|
|
|
constructor(source: any = {}) {
|
|
if ('string' === typeof source) source = JSON.parse(source);
|
|
this.id = source["id"];
|
|
this.name = source["name"];
|
|
this.email = source["email"];
|
|
this.created_at = source["created_at"];
|
|
}
|
|
}
|
|
|
|
}
|
|
|