feat: add stock keeping units list component and related services

feat: implement checkbox component with label and hint support

feat: create sale invoice full response model for invoice details

feat: add single view component for displaying sale invoice details

feat: define various list configurations for account, business activity, and consumer management

feat: establish list configurations for managing devices, goods, and licenses

feat: create list configurations for managing partners and their accounts

feat: implement user management list configuration
This commit is contained in:
2026-05-12 19:58:53 +03:30
parent fecdf4a06b
commit 561aca32d3
104 changed files with 1611 additions and 678 deletions
+13 -2
View File
@@ -1,6 +1,6 @@
import { HttpClient } from '@angular/common/http';
import { Injectable } from '@angular/core';
import { Observable } from 'rxjs';
import { Observable, shareReplay } from 'rxjs';
import { ENUMS_API_ROUTES } from './constants/apiRoutes';
import { TEnumApi } from './models';
import { IApiEnumResponse } from './models/io';
@@ -10,8 +10,19 @@ export class EnumsService {
constructor(private http: HttpClient) {}
private apiRoutes = ENUMS_API_ROUTES;
private readonly cache = new Map<TEnumApi, Observable<IApiEnumResponse[]>>();
getAll(type: TEnumApi): Observable<IApiEnumResponse[]> {
return this.http.get<IApiEnumResponse[]>(this.apiRoutes[type]);
const cached = this.cache.get(type);
if (cached) {
return cached;
}
const request$ = this.http
.get<IApiEnumResponse[]>(this.apiRoutes[type])
.pipe(shareReplay({ bufferSize: 1, refCount: true }));
this.cache.set(type, request$);
return request$;
}
}