This commit is contained in:
root
2026-06-28 23:48:13 +00:00
parent 4c2ce929d9
commit 9e215baa11
9538 changed files with 3146 additions and 239 deletions
+53
View File
@@ -200,3 +200,56 @@ export class TargetInfo {
return new TargetInfo($$parsedSource as Partial<TargetInfo>);
}
}
export class User {
"id": number;
"username": string;
"password": string;
"nickname": string;
"phone": string;
/**
* 'pending', 'approved', 'rejected'
*/
"status": string;
"apiKey": string;
"createdAt": string;
/** Creates a new User instance. */
constructor($$source: Partial<User> = {}) {
if (!("id" in $$source)) {
this["id"] = 0;
}
if (!("username" in $$source)) {
this["username"] = "";
}
if (!("password" in $$source)) {
this["password"] = "";
}
if (!("nickname" in $$source)) {
this["nickname"] = "";
}
if (!("phone" in $$source)) {
this["phone"] = "";
}
if (!("status" in $$source)) {
this["status"] = "";
}
if (!("apiKey" in $$source)) {
this["apiKey"] = "";
}
if (!("createdAt" in $$source)) {
this["createdAt"] = "";
}
Object.assign(this, $$source);
}
/**
* Creates a new User instance from a string or object.
*/
static createFrom($$source: any = {}): User {
let $$parsedSource = typeof $$source === 'string' ? JSON.parse($$source) : $$source;
return new User($$parsedSource as Partial<User>);
}
}