intelica-library-ui 0.1.199 → 0.1.201
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -48,8 +48,8 @@ import { AccordionModule } from 'primeng/accordion';
|
|
|
48
48
|
import * as XLSX from 'xlsx';
|
|
49
49
|
import { Workbook } from 'exceljs';
|
|
50
50
|
import { saveAs } from 'file-saver';
|
|
51
|
-
import JSEncrypt from 'jsencrypt';
|
|
52
51
|
import pako from 'pako';
|
|
52
|
+
import JSEncrypt from 'jsencrypt';
|
|
53
53
|
import Aura from '@primeng/themes/aura';
|
|
54
54
|
import { definePreset } from '@primeng/themes';
|
|
55
55
|
|
|
@@ -7481,62 +7481,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.1", ngImpor
|
|
|
7481
7481
|
}]
|
|
7482
7482
|
}] });
|
|
7483
7483
|
|
|
7484
|
-
class AuthenticationService {
|
|
7485
|
-
_http = inject(HttpClient);
|
|
7486
|
-
_configService = inject(ConfigService);
|
|
7487
|
-
GetPrivateValue() {
|
|
7488
|
-
return this._http.get(`${this._configService.environment?.authenticationPath}/Authenticate/GetPrivateValue`);
|
|
7489
|
-
}
|
|
7490
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.1", ngImport: i0, type: AuthenticationService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
7491
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.1", ngImport: i0, type: AuthenticationService, providedIn: "root" });
|
|
7492
|
-
}
|
|
7493
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.1", ngImport: i0, type: AuthenticationService, decorators: [{
|
|
7494
|
-
type: Injectable,
|
|
7495
|
-
args: [{
|
|
7496
|
-
providedIn: "root",
|
|
7497
|
-
}]
|
|
7498
|
-
}] });
|
|
7499
|
-
|
|
7500
|
-
function decryptData(encryptedData, privateKey) {
|
|
7501
|
-
const decryptor = new JSEncrypt();
|
|
7502
|
-
decryptor.setPrivateKey(privateKey);
|
|
7503
|
-
const decryptedText = decryptor.decrypt(encryptedData);
|
|
7504
|
-
if (!decryptedText) {
|
|
7505
|
-
console.error("Error al descifrar los datos con RSA");
|
|
7506
|
-
return null;
|
|
7507
|
-
}
|
|
7508
|
-
return decryptedText;
|
|
7509
|
-
}
|
|
7510
|
-
|
|
7511
|
-
class ProfileService {
|
|
7512
|
-
AuthenticationService = inject(AuthenticationService);
|
|
7513
|
-
Profile = null;
|
|
7514
|
-
PrivateKey = "";
|
|
7515
|
-
ProfileReady = signal(false);
|
|
7516
|
-
Initialize() {
|
|
7517
|
-
this.AuthenticationService.GetPrivateValue().subscribe(response => {
|
|
7518
|
-
this.PrivateKey = response;
|
|
7519
|
-
this.SetProfile();
|
|
7520
|
-
});
|
|
7521
|
-
}
|
|
7522
|
-
SetProfile() {
|
|
7523
|
-
const profileCookie = getCookie("profile");
|
|
7524
|
-
if (profileCookie) {
|
|
7525
|
-
const decrypted = decryptData(profileCookie, this.PrivateKey);
|
|
7526
|
-
this.Profile = decrypted ? JSON.parse(decrypted) : null;
|
|
7527
|
-
}
|
|
7528
|
-
else
|
|
7529
|
-
this.Profile = null;
|
|
7530
|
-
this.ProfileReady.set(true);
|
|
7531
|
-
}
|
|
7532
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.1", ngImport: i0, type: ProfileService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
7533
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.1", ngImport: i0, type: ProfileService, providedIn: "root" });
|
|
7534
|
-
}
|
|
7535
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.1", ngImport: i0, type: ProfileService, decorators: [{
|
|
7536
|
-
type: Injectable,
|
|
7537
|
-
args: [{ providedIn: "root" }]
|
|
7538
|
-
}] });
|
|
7539
|
-
|
|
7540
7484
|
class PageElementService {
|
|
7541
7485
|
_http = inject(HttpClient);
|
|
7542
7486
|
_configService = inject(ConfigService);
|
|
@@ -7669,6 +7613,17 @@ function EmailInputValidation(event) {
|
|
|
7669
7613
|
}
|
|
7670
7614
|
}
|
|
7671
7615
|
|
|
7616
|
+
function decryptData(encryptedData, privateKey) {
|
|
7617
|
+
const decryptor = new JSEncrypt();
|
|
7618
|
+
decryptor.setPrivateKey(privateKey);
|
|
7619
|
+
const decryptedText = decryptor.decrypt(encryptedData);
|
|
7620
|
+
if (!decryptedText) {
|
|
7621
|
+
console.error("Error al descifrar los datos con RSA");
|
|
7622
|
+
return null;
|
|
7623
|
+
}
|
|
7624
|
+
return decryptedText;
|
|
7625
|
+
}
|
|
7626
|
+
|
|
7672
7627
|
const IntelicaTheme = definePreset(Aura, {
|
|
7673
7628
|
primitive: {
|
|
7674
7629
|
blue: {
|
|
@@ -9976,5 +9931,5 @@ const IntelicaTheme = definePreset(Aura, {
|
|
|
9976
9931
|
* Generated bundle index. Do not edit.
|
|
9977
9932
|
*/
|
|
9978
9933
|
|
|
9979
|
-
export { ActionDirective, ActionsMenuComponent, ButtonSplitComponent, CheckboxFilterDirective, Color, ColumnComponent, ColumnGroupComponent, CompareByField, CompressService, ConfigService, CookieAttributesGeneral, DataDirective, DateFilterDirective, DateModeOptions, DynamicInputValidation, EchartComponent, EchartService, ElementService, EmailInputValidation, ErrorInterceptor, FeatureFlagService, FilterChipsComponent, FiltersComponent, FormatAmountPipe, GetCookieAttributes, GlobalFeatureFlagService, GlobalTermService, HtmlToExcelService, InitializeConfigService, InputValidation, IntelicaCellCheckboxDirective, IntelicaTheme, ItemSplitDirective, LanguageService, MatrixColumnComponent, MatrixColumnGroupComponent, MatrixTableComponent, ModalDialogComponent, MultiSelectComponent, OrderConstants, PaginatorComponent, Patterns, PopoverComponent,
|
|
9934
|
+
export { ActionDirective, ActionsMenuComponent, ButtonSplitComponent, CheckboxFilterDirective, Color, ColumnComponent, ColumnGroupComponent, CompareByField, CompressService, ConfigService, CookieAttributesGeneral, DataDirective, DateFilterDirective, DateModeOptions, DynamicInputValidation, EchartComponent, EchartService, ElementService, EmailInputValidation, ErrorInterceptor, FeatureFlagService, FilterChipsComponent, FiltersComponent, FormatAmountPipe, GetCookieAttributes, GlobalFeatureFlagService, GlobalTermService, HtmlToExcelService, InitializeConfigService, InputValidation, IntelicaCellCheckboxDirective, IntelicaTheme, ItemSplitDirective, LanguageService, MatrixColumnComponent, MatrixColumnGroupComponent, MatrixTableComponent, ModalDialogComponent, MultiSelectComponent, OrderConstants, PaginatorComponent, Patterns, PopoverComponent, RecordPerPageComponent, RefreshTokenInterceptor, RouteGuard, RowResumenComponent, RowResumenTreeComponent, SearchComponent, SelectDetailFilterDirective, SelectFilterDirective, SharedService, SkeletonChartComponent, SkeletonComponent, SkeletonService, SkeletonTableComponent, SortingComponent, SpinnerComponent, SpinnerService, SweetAlertService, TableComponent, TableFetchComponent, TableSortOrder, TemplateDirective, TemplateMenuComponent, TermGuard, TermPipe, TermService, TextAreaFilterDirective, TextFilterDirective, TextRangeFilterDirective, TitlesComponent, TreeColumnComponent, TreeColumnGroupComponent, TreeTableComponent, TruncatePipe, decryptData, encryptData, getColor };
|
|
9980
9935
|
//# sourceMappingURL=intelica-library-ui.mjs.map
|