mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-08-30 15:07:14 +00:00
feat(clients,routing): label inbounds by remark with tag fallback
Inbound pickers and chips across the Users area, the inbounds attach-clients modals, and the routing rule inbound-tags selector showed the auto-generated tag (in-443-tcp). Show the inbound remark when set, falling back to the tag. Only display labels change; option values keep using the inbound id (or tag for routing rules, which match inbounds by tag), so filtering, attaching, and saved rules are unaffected. Routing reads remarks via a shared useInboundOptions hook that reuses the existing options query cache.
This commit is contained in:
@@ -69,7 +69,7 @@ export default function AttachClientsModal({
|
||||
if (!source) return [];
|
||||
return (dbInbounds || [])
|
||||
.filter((ib) => ib.id !== source.id && isInboundMultiUser(ib))
|
||||
.map((ib) => ({ value: ib.id, label: ib.tag ?? '' }));
|
||||
.map((ib) => ({ value: ib.id, label: ib.remark?.trim() || ib.tag || '' }));
|
||||
}, [dbInbounds, source]);
|
||||
|
||||
const filteredRows = useMemo(() => {
|
||||
@@ -150,7 +150,7 @@ export default function AttachClientsModal({
|
||||
}}
|
||||
okText={t('pages.inbounds.attachClients')}
|
||||
cancelText={t('cancel')}
|
||||
title={t('pages.inbounds.attachClientsTitle', { remark: source?.tag ?? '' })}
|
||||
title={t('pages.inbounds.attachClientsTitle', { remark: source?.remark?.trim() || source?.tag || '' })}
|
||||
width={680}
|
||||
>
|
||||
{messageContextHolder}
|
||||
|
||||
@@ -170,7 +170,7 @@ export default function AttachExistingClientsModal({
|
||||
okButtonProps={{ disabled: selectedEmails.length === 0, loading: saving }}
|
||||
okText={t('pages.inbounds.attachClients')}
|
||||
cancelText={t('cancel')}
|
||||
title={t('pages.inbounds.attachExistingTitle', { remark: target?.tag ?? '' })}
|
||||
title={t('pages.inbounds.attachExistingTitle', { remark: target?.remark?.trim() || target?.tag || '' })}
|
||||
width={680}
|
||||
>
|
||||
{messageContextHolder}
|
||||
|
||||
Reference in New Issue
Block a user