Add admin configs endpoint and related UI components
CI / Backend (build + test) (push) Successful in 1m17s
CI / Frontend (lint + typecheck + build) (push) Successful in 32s

- Introduced a new endpoint to list all admin configs, enhancing the admin interface for better management.
- Updated API documentation to include the new `/configs` endpoint with pagination and search capabilities.
- Added routing and UI elements for the configs section in the admin panel, improving navigation and accessibility.
- Enhanced localization for the configs feature in both Russian and English, ensuring a user-friendly experience.
This commit is contained in:
Leonid Pershin
2026-07-13 16:08:50 +03:00
parent 7fce5ef181
commit 39a8b30b03
12 changed files with 442 additions and 0 deletions
+17
View File
@@ -59,6 +59,23 @@ export type VpnConfigDto = {
createdAt: string
}
/** Строка админского списка «Все конфиги» — в отличие от VpnConfigDto содержит владельца и ноду. */
export type AdminVpnConfigDto = {
id: string
userId: string
userName: string
label: string | null
clientEmail: string
protocol: VpnProtocol
location: string
nodeName: string
usedUpBytes: number
usedDownBytes: number
expiresAt: string | null
status: ConfigStatus
createdAt: string
}
export type AvailableInboundDto = {
inboundId: string
displayName: string
+28
View File
@@ -154,6 +154,7 @@ const resources = {
overview: 'Обзор',
activation: 'Запросы на активацию',
users: 'Пользователи',
configs: 'Все конфиги',
roles: 'Роли',
nodes: 'Ноды',
apps: 'Приложения',
@@ -187,6 +188,19 @@ const resources = {
confirmDelete: 'Удалить пользователя? Все его конфиги будут отозваны в 3x-ui, действие необратимо.',
deleted: 'Пользователь удалён.',
},
configs: {
searchPlaceholder: 'Поиск по email в панели или метке',
owner: 'Владелец',
node: 'Нода',
location: 'Локация',
protocol: 'Протокол',
traffic: 'Трафик',
statusLabel: 'Статус',
allStatuses: 'Все статусы',
created: 'Создан',
empty: 'Конфиги не найдены.',
total: 'Всего: {{count}}',
},
activation: {
empty: 'Нет ожидающих запросов на активацию.',
approved: 'Пользователь активирован.',
@@ -447,6 +461,7 @@ const resources = {
overview: 'Overview',
activation: 'Activation requests',
users: 'Users',
configs: 'All configs',
roles: 'Roles',
nodes: 'Nodes',
apps: 'Apps',
@@ -480,6 +495,19 @@ const resources = {
confirmDelete: 'Delete this user? All their configs will be revoked in 3x-ui — this cannot be undone.',
deleted: 'User deleted.',
},
configs: {
searchPlaceholder: 'Search by panel email or label',
owner: 'Owner',
node: 'Node',
location: 'Location',
protocol: 'Protocol',
traffic: 'Traffic',
statusLabel: 'Status',
allStatuses: 'All statuses',
created: 'Created',
empty: 'No configs found.',
total: 'Total: {{count}}',
},
activation: {
empty: 'No pending activation requests.',
approved: 'User activated.',