mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-05-29 16:39:35 +00:00
fix(clients): log bulk attach/detach failures to console
The backend returns descriptive error strings (email/inbound + reason) but the UI only surfaced a count. Forward result.errors to console.error so the actual failure cause is recoverable from DevTools.
This commit is contained in:
@@ -50,6 +50,7 @@ export default function BulkAttachInboundsModal({
|
||||
const skipped = result.skipped?.length ?? 0;
|
||||
const errors = result.errors?.length ?? 0;
|
||||
if (errors > 0) {
|
||||
console.error('[BulkAttach] failures:', result.errors);
|
||||
messageApi.warning(
|
||||
t('pages.inbounds.attachClientsResultMixed', { attached, skipped, errors }),
|
||||
);
|
||||
|
||||
@@ -50,6 +50,7 @@ export default function BulkDetachInboundsModal({
|
||||
const skipped = result.skipped?.length ?? 0;
|
||||
const errors = result.errors?.length ?? 0;
|
||||
if (errors > 0) {
|
||||
console.error('[BulkDetach] failures:', result.errors);
|
||||
messageApi.warning(
|
||||
t('pages.clients.detachFromInboundsResultMixed', { detached, skipped, errors }),
|
||||
);
|
||||
|
||||
@@ -128,6 +128,7 @@ export default function AttachClientsModal({
|
||||
const skipped = result.skipped?.length ?? 0;
|
||||
const errors = result.errors?.length ?? 0;
|
||||
if (errors > 0) {
|
||||
console.error('[AttachClients] failures:', result.errors);
|
||||
messageApi.warning(t('pages.inbounds.attachClientsResultMixed', { attached, skipped, errors }));
|
||||
} else {
|
||||
messageApi.success(t('pages.inbounds.attachClientsResult', { attached, skipped }));
|
||||
|
||||
Reference in New Issue
Block a user