mirror of
https://github.com/alireza0/x-ui.git
synced 2026-03-14 05:23:09 +00:00
[sub] support client-side group name
This commit is contained in:
@@ -704,7 +704,7 @@ func (s *SubService) genRemark(inbound *model.Inbound, email string, extra strin
|
|||||||
// Get remained days
|
// Get remained days
|
||||||
if statsExist {
|
if statsExist {
|
||||||
if !stats.Enable {
|
if !stats.Enable {
|
||||||
return "N/A"
|
return fmt.Sprintf("⛔️N/A-%s", strings.Join(remark, "-"))
|
||||||
}
|
}
|
||||||
if vol := stats.Total - (stats.Up + stats.Down); vol > 0 {
|
if vol := stats.Total - (stats.Up + stats.Down); vol > 0 {
|
||||||
remark = append(remark, fmt.Sprintf("%s%s", common.FormatTraffic(vol), "📊"))
|
remark = append(remark, fmt.Sprintf("%s%s", common.FormatTraffic(vol), "📊"))
|
||||||
|
|||||||
@@ -84,7 +84,7 @@
|
|||||||
},
|
},
|
||||||
genSubLink(subID) {
|
genSubLink(subID) {
|
||||||
const { domain: host, port, tls: isTLS, path: base } = app.subSettings;
|
const { domain: host, port, tls: isTLS, path: base } = app.subSettings;
|
||||||
return buildURL({ host, port, isTLS, base, path: subID });
|
return buildURL({ host, port, isTLS, base, path: subID+'?name='+subID });
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
updated() {
|
updated() {
|
||||||
|
|||||||
@@ -291,7 +291,7 @@
|
|||||||
},
|
},
|
||||||
genSubLink(subID) {
|
genSubLink(subID) {
|
||||||
const { domain: host, port, tls: isTLS, path: base } = app.subSettings;
|
const { domain: host, port, tls: isTLS, path: base } = app.subSettings;
|
||||||
return buildURL({ host, port, isTLS, base, path: subID });
|
return buildURL({ host, port, isTLS, base, path: subID+'?name='+subID });
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user