[sub] support client-side group name

This commit is contained in:
Alireza Ahmadi
2023-08-25 23:34:15 +02:00
parent 7adc8755f8
commit da5253d98c
3 changed files with 3 additions and 3 deletions

View File

@@ -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), "📊"))

View File

@@ -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() {

View File

@@ -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 });
} }
}; };