Enhance user management and billing integration
- Updated the `UserSummaryDto` to include `BillingEnabled` and `BillingPaidUntil` properties, allowing for better tracking of user billing status. - Refactored the `IdentityService` to populate the new billing fields when retrieving user summaries. - Modified the dashboard and admin user management components to display billing information, including a link to the billing page and a badge for billing status. - Added internationalization support for new billing-related labels in both English and Russian. - Ensured frontend components reflect the updated user data structure, enhancing user experience with billing visibility.
This commit is contained in:
@@ -165,6 +165,8 @@ export type UserSummaryDto = {
|
||||
isActivated: boolean
|
||||
isBlocked: boolean
|
||||
activatedAt: string | null
|
||||
billingEnabled: boolean
|
||||
billingPaidUntil: string | null
|
||||
}
|
||||
|
||||
export type RoleDto = {
|
||||
|
||||
@@ -107,7 +107,11 @@ const resources = {
|
||||
status: 'Статус оплаты',
|
||||
suspended: 'Приостановлено',
|
||||
paidUntil: 'Оплачено до {{date}}',
|
||||
paidUntilLabel: 'Оплата:',
|
||||
neverPaid: 'Оплата ещё не производилась.',
|
||||
neverPaidShort: 'Не оплачено',
|
||||
expiredShort: 'Истекло',
|
||||
daysRemaining: '{{count}} дн.',
|
||||
newRequest: 'Оформить оплату',
|
||||
period: 'Период',
|
||||
periods: {
|
||||
@@ -246,6 +250,7 @@ const resources = {
|
||||
userName: 'Имя пользователя',
|
||||
role: 'Роль',
|
||||
statusLabel: 'Статус',
|
||||
billingLabel: 'Оплачено до',
|
||||
manage: 'Управление',
|
||||
empty: 'Пользователи не найдены.',
|
||||
total: 'Всего: {{count}}',
|
||||
@@ -616,7 +621,11 @@ const resources = {
|
||||
status: 'Payment status',
|
||||
suspended: 'Suspended',
|
||||
paidUntil: 'Paid until {{date}}',
|
||||
paidUntilLabel: 'Payment:',
|
||||
neverPaid: 'No payment has been made yet.',
|
||||
neverPaidShort: 'Not paid',
|
||||
expiredShort: 'Expired',
|
||||
daysRemaining: '{{count}}d',
|
||||
newRequest: 'Set up payment',
|
||||
period: 'Period',
|
||||
periods: {
|
||||
@@ -755,6 +764,7 @@ const resources = {
|
||||
userName: 'Username',
|
||||
role: 'Role',
|
||||
statusLabel: 'Status',
|
||||
billingLabel: 'Paid until',
|
||||
manage: 'Manage',
|
||||
empty: 'No users found.',
|
||||
total: 'Total: {{count}}',
|
||||
|
||||
Reference in New Issue
Block a user