mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2025-09-13 05:30:06 +00:00
feat(frontend): carry created_at/updated_at in client models and round-trip via JSON
This commit is contained in:
parent
4ea3e686c2
commit
5f52b02e43
1 changed files with 32 additions and 4 deletions
|
@ -1817,7 +1817,9 @@ Inbound.VmessSettings.VMESS = class extends XrayCommonClass {
|
||||||
tgId = '',
|
tgId = '',
|
||||||
subId = RandomUtil.randomLowerAndNum(16),
|
subId = RandomUtil.randomLowerAndNum(16),
|
||||||
comment = '',
|
comment = '',
|
||||||
reset = 0
|
reset = 0,
|
||||||
|
created_at = undefined,
|
||||||
|
updated_at = undefined
|
||||||
) {
|
) {
|
||||||
super();
|
super();
|
||||||
this.id = id;
|
this.id = id;
|
||||||
|
@ -1831,6 +1833,8 @@ Inbound.VmessSettings.VMESS = class extends XrayCommonClass {
|
||||||
this.subId = subId;
|
this.subId = subId;
|
||||||
this.comment = comment;
|
this.comment = comment;
|
||||||
this.reset = reset;
|
this.reset = reset;
|
||||||
|
this.created_at = created_at;
|
||||||
|
this.updated_at = updated_at;
|
||||||
}
|
}
|
||||||
|
|
||||||
static fromJson(json = {}) {
|
static fromJson(json = {}) {
|
||||||
|
@ -1846,6 +1850,8 @@ Inbound.VmessSettings.VMESS = class extends XrayCommonClass {
|
||||||
json.subId,
|
json.subId,
|
||||||
json.comment,
|
json.comment,
|
||||||
json.reset,
|
json.reset,
|
||||||
|
json.created_at,
|
||||||
|
json.updated_at,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
get _expiryTime() {
|
get _expiryTime() {
|
||||||
|
@ -1926,7 +1932,9 @@ Inbound.VLESSSettings.VLESS = class extends XrayCommonClass {
|
||||||
tgId = '',
|
tgId = '',
|
||||||
subId = RandomUtil.randomLowerAndNum(16),
|
subId = RandomUtil.randomLowerAndNum(16),
|
||||||
comment = '',
|
comment = '',
|
||||||
reset = 0
|
reset = 0,
|
||||||
|
created_at = undefined,
|
||||||
|
updated_at = undefined
|
||||||
) {
|
) {
|
||||||
super();
|
super();
|
||||||
this.id = id;
|
this.id = id;
|
||||||
|
@ -1940,6 +1948,8 @@ Inbound.VLESSSettings.VLESS = class extends XrayCommonClass {
|
||||||
this.subId = subId;
|
this.subId = subId;
|
||||||
this.comment = comment;
|
this.comment = comment;
|
||||||
this.reset = reset;
|
this.reset = reset;
|
||||||
|
this.created_at = created_at;
|
||||||
|
this.updated_at = updated_at;
|
||||||
}
|
}
|
||||||
|
|
||||||
static fromJson(json = {}) {
|
static fromJson(json = {}) {
|
||||||
|
@ -1955,6 +1965,8 @@ Inbound.VLESSSettings.VLESS = class extends XrayCommonClass {
|
||||||
json.subId,
|
json.subId,
|
||||||
json.comment,
|
json.comment,
|
||||||
json.reset,
|
json.reset,
|
||||||
|
json.created_at,
|
||||||
|
json.updated_at,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2065,7 +2077,9 @@ Inbound.TrojanSettings.Trojan = class extends XrayCommonClass {
|
||||||
tgId = '',
|
tgId = '',
|
||||||
subId = RandomUtil.randomLowerAndNum(16),
|
subId = RandomUtil.randomLowerAndNum(16),
|
||||||
comment = '',
|
comment = '',
|
||||||
reset = 0
|
reset = 0,
|
||||||
|
created_at = undefined,
|
||||||
|
updated_at = undefined
|
||||||
) {
|
) {
|
||||||
super();
|
super();
|
||||||
this.password = password;
|
this.password = password;
|
||||||
|
@ -2078,6 +2092,8 @@ Inbound.TrojanSettings.Trojan = class extends XrayCommonClass {
|
||||||
this.subId = subId;
|
this.subId = subId;
|
||||||
this.comment = comment;
|
this.comment = comment;
|
||||||
this.reset = reset;
|
this.reset = reset;
|
||||||
|
this.created_at = created_at;
|
||||||
|
this.updated_at = updated_at;
|
||||||
}
|
}
|
||||||
|
|
||||||
toJson() {
|
toJson() {
|
||||||
|
@ -2092,6 +2108,8 @@ Inbound.TrojanSettings.Trojan = class extends XrayCommonClass {
|
||||||
subId: this.subId,
|
subId: this.subId,
|
||||||
comment: this.comment,
|
comment: this.comment,
|
||||||
reset: this.reset,
|
reset: this.reset,
|
||||||
|
created_at: this.created_at,
|
||||||
|
updated_at: this.updated_at,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2107,6 +2125,8 @@ Inbound.TrojanSettings.Trojan = class extends XrayCommonClass {
|
||||||
json.subId,
|
json.subId,
|
||||||
json.comment,
|
json.comment,
|
||||||
json.reset,
|
json.reset,
|
||||||
|
json.created_at,
|
||||||
|
json.updated_at,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2226,7 +2246,9 @@ Inbound.ShadowsocksSettings.Shadowsocks = class extends XrayCommonClass {
|
||||||
tgId = '',
|
tgId = '',
|
||||||
subId = RandomUtil.randomLowerAndNum(16),
|
subId = RandomUtil.randomLowerAndNum(16),
|
||||||
comment = '',
|
comment = '',
|
||||||
reset = 0
|
reset = 0,
|
||||||
|
created_at = undefined,
|
||||||
|
updated_at = undefined
|
||||||
) {
|
) {
|
||||||
super();
|
super();
|
||||||
this.method = method;
|
this.method = method;
|
||||||
|
@ -2240,6 +2262,8 @@ Inbound.ShadowsocksSettings.Shadowsocks = class extends XrayCommonClass {
|
||||||
this.subId = subId;
|
this.subId = subId;
|
||||||
this.comment = comment;
|
this.comment = comment;
|
||||||
this.reset = reset;
|
this.reset = reset;
|
||||||
|
this.created_at = created_at;
|
||||||
|
this.updated_at = updated_at;
|
||||||
}
|
}
|
||||||
|
|
||||||
toJson() {
|
toJson() {
|
||||||
|
@ -2255,6 +2279,8 @@ Inbound.ShadowsocksSettings.Shadowsocks = class extends XrayCommonClass {
|
||||||
subId: this.subId,
|
subId: this.subId,
|
||||||
comment: this.comment,
|
comment: this.comment,
|
||||||
reset: this.reset,
|
reset: this.reset,
|
||||||
|
created_at: this.created_at,
|
||||||
|
updated_at: this.updated_at,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2271,6 +2297,8 @@ Inbound.ShadowsocksSettings.Shadowsocks = class extends XrayCommonClass {
|
||||||
json.subId,
|
json.subId,
|
||||||
json.comment,
|
json.comment,
|
||||||
json.reset,
|
json.reset,
|
||||||
|
json.created_at,
|
||||||
|
json.updated_at,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue