add tenant and user endpoints, services, models and guards

This commit is contained in:
Gagan7900
2026-07-18 16:38:41 +05:30
parent be86ab3564
commit 7c4e34e478
50 changed files with 3064 additions and 451 deletions
@@ -0,0 +1,32 @@
import { buildApiUrl } from '../../config/api-url.util';
export const TENANT_CURRENCIES_ENDPOINTS = {
dataTable: buildApiUrl(
'masterAdmin',
'/v1/tenant-currencies/datatable'
),
create: buildApiUrl(
'masterAdmin',
'/v1/tenant-currencies'
),
getById: (id: string) =>
buildApiUrl(
'masterAdmin',
`/v1/tenant-currencies/${encodeURIComponent(id)}`
),
autocomplete: buildApiUrl(
'masterAdmin',
'/v1/tenant-currencies/autocomplete'
),
update: (id: string) =>
buildApiUrl(
'masterAdmin',
`/v1/tenant-currencies/${encodeURIComponent(id)}`
)
} as const;
@@ -0,0 +1,32 @@
import { buildApiUrl } from '../../config/api-url.util';
export const TENANT_ENDPOINTS = {
dataTable: buildApiUrl(
'masterAdmin',
'/v1/tenants/datatable'
),
create: buildApiUrl(
'masterAdmin',
'/v1/tenants'
),
getById: (id: string) =>
buildApiUrl(
'masterAdmin',
`/v1/tenants/${encodeURIComponent(id)}`
),
autocomplete: buildApiUrl(
'masterAdmin',
'/v1/tenants/autocomplete'
),
update: (id: string) =>
buildApiUrl(
'masterAdmin',
`/v1/tenants/${encodeURIComponent(id)}`
)
} as const;
@@ -0,0 +1,10 @@
import { buildApiUrl } from '../../config/api-url.util';
export const USER_ENDPOINTS = {
dataTable: buildApiUrl('identity', '/v1/users/datatable'),
create: buildApiUrl('identity', '/v1/users'),
getById: (id: string) => buildApiUrl('identity', `/v1/users/${encodeURIComponent(id)}`),
update: (id: string) => buildApiUrl('identity', `/v1/users/${encodeURIComponent(id)}`),
autocomplete: buildApiUrl('identity', '/v1/users/autocomplete')
} as const;