@esfaenza/core 19.2.157 → 19.2.158
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.
- package/domain/models/jace/JaceIdentity.d.ts +1 -1
- package/fesm2022/esfaenza-core-domain.mjs.map +1 -1
- package/fesm2022/esfaenza-core-services.mjs +38 -13
- package/fesm2022/esfaenza-core-services.mjs.map +1 -1
- package/fesm2022/esfaenza-core.mjs +2 -2
- package/fesm2022/esfaenza-core.mjs.map +1 -1
- package/package.json +6 -6
- package/services/classes/app.session.d.ts +1 -1
- package/services/classes/preferences/app.preference.persistor.d.ts +5 -5
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"esfaenza-core-domain.mjs","sources":["../../../projects/core/domain/src/models/core/ApplicationMenu.ts","../../../projects/core/domain/src/models/core/ApplicationJob.ts","../../../projects/core/domain/src/models/core/EnvOptions.ts","../../../projects/core/domain/src/models/core/KeyValue.ts","../../../projects/core/domain/src/models/core/GenericItem.ts","../../../projects/core/domain/src/models/core/ApplicationRoutes.ts","../../../projects/core/domain/src/models/jace/CategoriesWithModules.ts","../../../projects/core/domain/src/models/jace/AccountScope.ts","../../../projects/core/domain/src/models/jace/ActiveModuleView.ts","../../../projects/core/domain/src/models/jace/JaceAccount.ts","../../../projects/core/domain/src/models/jace/JaceIdentity.ts","../../../projects/core/domain/src/models/jace/JaceModule.ts","../../../projects/core/domain/src/models/jace/JacePermission.ts","../../../projects/core/domain/src/models/jace/JaceRole.ts","../../../projects/core/domain/src/models/jace/JaceUser.ts","../../../projects/core/domain/src/models/global_search/SaerchResultContainer.ts","../../../projects/core/domain/src/models/global_search/SearchResult.ts","../../../projects/core/domain/src/models/user/UpdateAccountRecoverySettingsDto.ts","../../../projects/core/domain/src/models/user/UpdatePasswordDto.ts","../../../projects/core/domain/src/models/user/UpdateProfilePictureDto.ts","../../../projects/core/domain/src/models/user/UserAccount.ts","../../../projects/core/domain/src/models/feeds/Feed.ts","../../../projects/core/domain/src/models/feeds/CreateUpdateFeedDto.ts","../../../projects/core/domain/src/models/feeds/EntityFeedsWidgetConfiguration.ts","../../../projects/core/domain/src/tokens.ts","../../../projects/core/domain/src/esfaenza-core-domain.ts"],"sourcesContent":["export class ApplicationMenu {\r\n constructor(\r\n public title: string,\r\n public link?: string,\r\n public routerLink?: string,\r\n public icon?: string,\r\n public ac?: string,\r\n public wip?: boolean,\r\n public subMenu?: ApplicationMenu[],\r\n public queryParams?: {}) { }\r\n\r\n static Group(title: string, icon: string, ac: string, wip: boolean, subMenu: ApplicationMenu[], queryParams?: any): ApplicationMenu {\r\n return new ApplicationMenu(title, null, null, icon, ac, wip, subMenu, queryParams);\r\n }\r\n\r\n static TopItem(title: string, icon: string, routerLink?: string, ac?: string, queryParams?: any, wip?: boolean): ApplicationMenu {\r\n return new ApplicationMenu(title, null, routerLink, icon, ac, wip, null, queryParams);\r\n }\r\n\r\n static Item(title: string, routerLink?: string, ac?: string, queryParams?: any, wip?: boolean): ApplicationMenu {\r\n return new ApplicationMenu(title, null, routerLink, null, ac, !routerLink && !ac && !queryParams ? true : wip, null, queryParams);\r\n }\r\n\r\n static Link(title: string, link?: string) {\r\n return new ApplicationMenu(title, link);\r\n }\r\n\r\n static ignoreStorage: any = { ignoreStorage: true };\r\n}\r\n","import { ReportParam } from \"@esfaenza/es-table\";\r\n\r\nexport class ApplicationJob {\r\n id: string;\r\n description: string;\r\n smalldescription: string;\r\n percentage: number;\r\n completed: boolean;\r\n fileid: string;\r\n reportid: string;\r\n complexreportid: string;\r\n reportpars: ReportParam[];\r\n}","export class EnvOptions {\r\n constructor(moduleId: string, moduleDef: number, env: string, varsion: string, description: string) {\r\n this.AppData = {\r\n ModuleDefId: moduleDef,\r\n ModuleId: moduleId,\r\n ComponentEnvironment: env,\r\n ComponentVersion: varsion,\r\n ModuleDescription: description\r\n }\r\n }\r\n\r\n //Proprietà di configurazione\r\n AppData: { ModuleId: string, ModuleDefId: number, ComponentEnvironment: string, ComponentVersion: string, ModuleDescription: string };\r\n AuthUrl?: string;\r\n Client?: string;\r\n JaceDashboardUrl?: string;\r\n TransactionTimeoutSeconds: number;\r\n\r\n //Proprietà di sistema\r\n redirectInProgress?: boolean;\r\n};","import { Export } from \"@esfaenza/extensions\";\r\n\r\nexport class KeyValue {\r\n constructor(id: string, description: string) {\r\n this.id = id;\r\n this.description = description;\r\n }\r\n @Export(10, \"Cod.\") id: string;\r\n @Export(20, \"Descrizione\") description: string;\r\n}","/** Rappresentazione di un oggetto generico */\r\nexport class GenericItem {\r\n /**\r\n * Costruttore \r\n * \r\n * @param properties Dizionario Chiave - Valore delle proprietà di questo oggetto generico\r\n */\r\n constructor(public properties: Record<string, string>) { }\r\n}\r\n","export const EMBEDDED_ROUTE: string = \"pages_ext\";\r\nexport const ROUTE: string = \"pages\";","import { ActiveModuleView } from \"./ActiveModuleView\";\r\n\r\n\r\nexport class CategoriesWithModules {\r\n constructor(module: ActiveModuleView) {\r\n this.category = module?.category?.toUpperCase();\r\n this.module_rows = [[module]];\r\n }\r\n category: string;\r\n module_rows: ActiveModuleView[][];\r\n}\r\n","import { JaceModule } from \"./JaceModule\";\r\nimport { JacePermission } from \"./JacePermission\";\r\nimport { JaceRole } from \"./JaceRole\";\r\n\r\nexport class AccountScope {\r\n constructor(public modules: JaceModule[] = [], public roles: JaceRole[] = [], public permissions: JacePermission[] = []) { }\r\n}","export class ActiveModuleView {\r\n constructor(public name: string) { }\r\n idmodule: number;\r\n altname: string;\r\n category: string;\r\n tenant: string;\r\n uiurl: string;\r\n environment: string;\r\n href: string;\r\n}","export class JaceAccount {\r\n idaccount: number;\r\n iduser: number;\r\n idtenant: string;\r\n dsusername: string;\r\n dspassword: string;\r\n dtvalidfrom: Date;\r\n dtvalidto: Date;\r\n sydatains: Date;\r\n sydataupd: Date;\r\n dtlockdown: Date;\r\n syuserupd: string;\r\n syuserins: string;\r\n dsreasonlockdown: string;\r\n cnattempts: number;\r\n\r\n //Solo UI\r\n description: string;\r\n}","import { AccountScope } from \"./AccountScope\";\r\n\r\nexport class JaceIdentity {\r\n Expired: boolean;\r\n IdAccount: number;\r\n IdUser: number;\r\n DsUser: string;\r\n FullName: string;\r\n Idtenant: string;\r\n TenantName: string;\r\n IdActor: number;\r\n IdActorRole: number;\r\n ExpirationTime: Date;\r\n\r\n constructor(scope: AccountScope = null) {\r\n this.Roles = [];\r\n this.Modules = [];\r\n this.Permissions = [];\r\n if (scope) {\r\n // Doppio parametro per gestione del nuovo AUTH.\r\n // TODO: Rimuovere quando non serve\r\n this.Roles = scope.roles.map(x=> x.idrolealt || x.roleidalt);\r\n this.Permissions = scope.permissions.map(x=> x.idpermissionalt || x.permissionidalt);\r\n this.Modules = scope.modules.map(x=> x.idmodule || x.moduleid);\r\n }\r\n }\r\n Roles: string[];\r\n Modules: number[];\r\n Permissions: string[];\r\n}\r\n","export class JaceModule {\r\n constructor(\r\n public idmodule: number,\r\n public dsname?: string,\r\n public dscategory?: string,\r\n public idmodulealt?: string\r\n ) {\r\n this.moduleid = idmodule;\r\n }\r\n\r\n // Nouvo Auth\r\n moduleid?: number;\r\n}\r\n","export class JacePermission {\r\n idpermission: number;\r\n dspermission?: string;\r\n idpermissionalt?: string;\r\n sydatains?: Date;\r\n syuserins?: string;\r\n sydataupd?: Date;\r\n syuserupd?: string;\r\n\r\n // Nuovo Auth\r\n permissionidalt?: string;\r\n}\r\n","export class JaceRole\r\n{\r\n constructor(public idrole: number, public idrolealt: string, public dsrole: string) {\r\n this.roleidalt = idrolealt;\r\n }\r\n\r\n dsnote?: string;\r\n idparent?: number;\r\n sydatains?: Date;\r\n syuserins?: string;\r\n sydataupd?: Date;\r\n syuserupd?: string;\r\n\r\n // Nuovo AUTH\r\n roleidalt?: string;\r\n}","\r\nexport class JaceUser {\r\n iduser: number;\r\n dsnome: string;\r\n dscognome: string;\r\n sydatains: Date;\r\n syuserins: string;\r\n sydataupd: Date;\r\n syuserupd: string;\r\n}\r\n","import { SearchResult } from \"./SearchResult\";\r\n\r\nexport class SearchResultContainer {\r\n constructor(public results: SearchResult[]) { }\r\n}","import { GenericItem } from \"../core/GenericItem\";\r\nimport { KeyValue } from \"../core/KeyValue\";\r\nimport { EsTableColumnsDefinition } from \"@esfaenza/es-table\";\r\n\r\nexport class SearchResult {\r\n\r\n constructor(\r\n public description: string,\r\n public columns: KeyValue[],\r\n public items: GenericItem[]\r\n ) { }\r\n\r\n // Solo UI per la visualizzazione dei risultati\r\n est_cols: EsTableColumnsDefinition[];\r\n}\r\n","export class UpdateAccountRecoverySettingsDto {\r\n constructor(public accountid?: string, public email?: string) { }\r\n}","export class UpdatePasswordDto {\r\n constructor(\r\n public accountid?: string,\r\n public oldpwd?: string,\r\n public newpwd?: string,\r\n public confirmpwd?: string,\r\n public changeall: boolean = true,\r\n public changeforexternals: boolean = true) { }\r\n}","export class UpdateProfilePictureDto {\r\n constructor(public accountid?: string) { }\r\n}","export class UserAccount {\r\n id: string;\r\n tenantid: string;\r\n username: string;\r\n typeid: string;\r\n type: string;\r\n dtvalidfrom: Date;\r\n dtvalidto: Date;\r\n dtlock: Date;\r\n lockreason: string;\r\n userid: string;\r\n userdescription: string;\r\n uuid: string;\r\n firstname: string;\r\n lastname: string;\r\n recoveryemail: string;\r\n recoveryphone: string;\r\n dtottexpiration: Date;\r\n dtlastlogin: Date;\r\n lastloginattempts: number;\r\n islocked: boolean;\r\n isvalid: boolean;\r\n}","export class Feed {\r\n id: string;\r\n parentid: string;\r\n title: string;\r\n content: string;\r\n severityid: string;\r\n systemgen: boolean;\r\n reactions: { [user: string]: string };\r\n user: string;\r\n pinned: boolean;\r\n ispublic: boolean;\r\n dateins: Date;\r\n dateupd: Date;\r\n childfeeds: Feed[];\r\n filename: string;\r\n filesize: string;\r\n // Solo per chatrooms, solo lato ts\r\n fileb64: string;\r\n // Semplicita GUI\r\n liked: boolean;\r\n disliked: boolean;\r\n likes: string[];\r\n dislikes: string[];\r\n}","export class CreateUpdateFeedDto {\r\n idfeed: string;\r\n identity: string;\r\n identitytype: string;\r\n parentid: string;\r\n content: string;\r\n filecontent: number[];\r\n filename: string;\r\n ispublic: boolean;\r\n // Flag terribile per fare funzionare l'edit\r\n updatefiledata: boolean;\r\n}","export class EntityFeedsWidgetConfiguration {\r\n GetFeedsAPI?: string;\r\n AllowUserTags?: boolean;\r\n GetUserTagsAPI?: string;\r\n AllowReactions?: boolean;\r\n ReactToFeedAPI?: string;\r\n AllowAttachments?: boolean;\r\n GetFeedAttachmentAPI?: string;\r\n AllowComments?: boolean;\r\n AllowReplies?: boolean;\r\n CreateFeedAPI?: string;\r\n UpdateFeedAPI?: string;\r\n DeleteFeedAPI?: string;\r\n}","// Angular\r\nimport { InjectionToken, Type } from \"@angular/core\";\r\n\r\n// Configurazioni\r\nimport { LocalizationService } from \"@esfaenza/localizations\";\r\n\r\n// Applicazione\r\nimport { ApplicationMenu } from \"./models/core/ApplicationMenu\";\r\n\r\n/** Token che indica i default da assegnare agli Input */\r\nexport const REDIRECT_MAP: InjectionToken<{ [index: string]: { url: string, params: string[] } }> = new InjectionToken<{ [index: string]: { url: string, params: string[] } }>('REDIRECT_MAP');\r\n\r\n/** Token che indica il servizio di localizzazione utilizzato per i menù */\r\nexport const MENU_LOCALIZATION: InjectionToken<Type<LocalizationService>> = new InjectionToken<Type<LocalizationService>>('MENU_LOCALIZATION');\r\n\r\n/** Token che indica i menù dell'applicazione, da quello vegano fino a quello celiaco */\r\nexport const MENU: InjectionToken<ApplicationMenu[]> = new InjectionToken<ApplicationMenu[]>('MENU');\r\n\r\n/** Token che indica se il servizio di autenticazione deve utilizzare un token finto */\r\nexport const USE_FAKE_ACCESS_TOKEN: InjectionToken<boolean> = new InjectionToken<boolean>('USE_FAKE_ACCESS_TOKEN');\r\n\r\n/** Token che indica se il servizio di autenticazione deve funzionare in anonimo lato Frontend. Dev'essere utilizzato insieme al tag \"Auth\" in code behind */\r\nexport const ANONYMOUS_MODE: InjectionToken<boolean> = new InjectionToken<boolean>('USE_FAKE_ACCESS_TOKEN');\r\n\r\n/** Token che indica i componenti di estensione da aggiungere alla navbar. Verranno bootstrappati in maniera dinamica */\r\nexport const NAVBAR_EXTENSIONS: InjectionToken<Type<any>[]> = new InjectionToken<Type<any>[]>('NAVBAR_EXTENSIONS');\r\n\r\n/** Token che identifica se utilizzare la versione vecchia dell'url di auth (${myconfig.AUTH_URL}/login/form?client=${myconfig.CLIENT_NAME}) invece che la nuova (${myconfig.AUTH_URL}/login;client=${myconfig.CLIENT_NAME}) */\r\nexport const LOGIN_URL_LEGACY: InjectionToken<boolean> = new InjectionToken<boolean>('LOGIN_URL_LEGACY');","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;MAAa,eAAe,CAAA;AACxB,IAAA,WAAA,CACW,KAAa,EACb,IAAa,EACb,UAAmB,EACnB,IAAa,EACb,EAAW,EACX,GAAa,EACb,OAA2B,EAC3B,WAAgB,EAAA;QAPhB,IAAK,CAAA,KAAA,GAAL,KAAK;QACL,IAAI,CAAA,IAAA,GAAJ,IAAI;QACJ,IAAU,CAAA,UAAA,GAAV,UAAU;QACV,IAAI,CAAA,IAAA,GAAJ,IAAI;QACJ,IAAE,CAAA,EAAA,GAAF,EAAE;QACF,IAAG,CAAA,GAAA,GAAH,GAAG;QACH,IAAO,CAAA,OAAA,GAAP,OAAO;QACP,IAAW,CAAA,WAAA,GAAX,WAAW;;AAEtB,IAAA,OAAO,KAAK,CAAC,KAAa,EAAE,IAAY,EAAE,EAAU,EAAE,GAAY,EAAE,OAA0B,EAAE,WAAiB,EAAA;AAC7G,QAAA,OAAO,IAAI,eAAe,CAAC,KAAK,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,EAAE,EAAE,GAAG,EAAE,OAAO,EAAE,WAAW,CAAC;;AAGtF,IAAA,OAAO,OAAO,CAAC,KAAa,EAAE,IAAY,EAAE,UAAmB,EAAE,EAAW,EAAE,WAAiB,EAAE,GAAa,EAAA;AAC1G,QAAA,OAAO,IAAI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,IAAK,CAAA,KAAA,GAAL,KAAK;;AACtD;;MCFY,iBAAiB,CAAA;AAC1B,IAAA,WAAA,CACW,SAAkB,EAClB,MAAe,EACf,MAAe,EACf,UAAmB,EACnB,SAAqB,GAAA,IAAI,EACzB,kBAAA,GAA8B,IAAI,EAAA;QALlC,IAAS,CAAA,SAAA,GAAT,SAAS;QACT,IAAM,CAAA,MAAA,GAAN,MAAM;QACN,IAAM,CAAA,MAAA,GAAN,MAAM;QACN,IAAU,CAAA,UAAA,GAAV,UAAU;QACV,IAAS,CAAA,SAAA,GAAT,SAAS;QACT,IAAkB,CAAA,kBAAA,GAAlB,kBAAkB;;AAChC;;MCRY,uBAAuB,CAAA;AAChC,IAAA,WAAA,CAAmB,SAAkB,EAAA;QAAlB,IAAS,CAAA,SAAA,GAAT,SAAS;;AAC/B;;MCFY,WAAW,CAAA;AAsBvB;;MCtBY,IAAI,CAAA;AAuBhB;;MCvBY,mBAAmB,CAAA;AAW/B;;MCXY,8BAA8B,CAAA;AAa1C;;ACbD;AASA;MACa,YAAY,GAA2E,IAAI,cAAc,CAAyD,cAAc;AAE7L;MACa,iBAAiB,GAA8C,IAAI,cAAc,CAA4B,mBAAmB;AAE7I;MACa,IAAI,GAAsC,IAAI,cAAc,CAAoB,MAAM;AAEnG;MACa,qBAAqB,GAA4B,IAAI,cAAc,CAAU,uBAAuB;AAEjH;MACa,cAAc,GAA4B,IAAI,cAAc,CAAU,uBAAuB;AAE1G;MACa,iBAAiB,GAAgC,IAAI,cAAc,CAAc,mBAAmB;AAEjH;MACa,gBAAgB,GAA4B,IAAI,cAAc,CAAU,kBAAkB;;AC5BvG;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"esfaenza-core-domain.mjs","sources":["../../../projects/core/domain/src/models/core/ApplicationMenu.ts","../../../projects/core/domain/src/models/core/ApplicationJob.ts","../../../projects/core/domain/src/models/core/EnvOptions.ts","../../../projects/core/domain/src/models/core/KeyValue.ts","../../../projects/core/domain/src/models/core/GenericItem.ts","../../../projects/core/domain/src/models/core/ApplicationRoutes.ts","../../../projects/core/domain/src/models/jace/CategoriesWithModules.ts","../../../projects/core/domain/src/models/jace/AccountScope.ts","../../../projects/core/domain/src/models/jace/ActiveModuleView.ts","../../../projects/core/domain/src/models/jace/JaceAccount.ts","../../../projects/core/domain/src/models/jace/JaceIdentity.ts","../../../projects/core/domain/src/models/jace/JaceModule.ts","../../../projects/core/domain/src/models/jace/JacePermission.ts","../../../projects/core/domain/src/models/jace/JaceRole.ts","../../../projects/core/domain/src/models/jace/JaceUser.ts","../../../projects/core/domain/src/models/global_search/SaerchResultContainer.ts","../../../projects/core/domain/src/models/global_search/SearchResult.ts","../../../projects/core/domain/src/models/user/UpdateAccountRecoverySettingsDto.ts","../../../projects/core/domain/src/models/user/UpdatePasswordDto.ts","../../../projects/core/domain/src/models/user/UpdateProfilePictureDto.ts","../../../projects/core/domain/src/models/user/UserAccount.ts","../../../projects/core/domain/src/models/feeds/Feed.ts","../../../projects/core/domain/src/models/feeds/CreateUpdateFeedDto.ts","../../../projects/core/domain/src/models/feeds/EntityFeedsWidgetConfiguration.ts","../../../projects/core/domain/src/tokens.ts","../../../projects/core/domain/src/esfaenza-core-domain.ts"],"sourcesContent":["export class ApplicationMenu {\r\n constructor(\r\n public title: string,\r\n public link?: string,\r\n public routerLink?: string,\r\n public icon?: string,\r\n public ac?: string,\r\n public wip?: boolean,\r\n public subMenu?: ApplicationMenu[],\r\n public queryParams?: {}) { }\r\n\r\n static Group(title: string, icon: string, ac: string, wip: boolean, subMenu: ApplicationMenu[], queryParams?: any): ApplicationMenu {\r\n return new ApplicationMenu(title, null, null, icon, ac, wip, subMenu, queryParams);\r\n }\r\n\r\n static TopItem(title: string, icon: string, routerLink?: string, ac?: string, queryParams?: any, wip?: boolean): ApplicationMenu {\r\n return new ApplicationMenu(title, null, routerLink, icon, ac, wip, null, queryParams);\r\n }\r\n\r\n static Item(title: string, routerLink?: string, ac?: string, queryParams?: any, wip?: boolean): ApplicationMenu {\r\n return new ApplicationMenu(title, null, routerLink, null, ac, !routerLink && !ac && !queryParams ? true : wip, null, queryParams);\r\n }\r\n\r\n static Link(title: string, link?: string) {\r\n return new ApplicationMenu(title, link);\r\n }\r\n\r\n static ignoreStorage: any = { ignoreStorage: true };\r\n}\r\n","import { ReportParam } from \"@esfaenza/es-table\";\r\n\r\nexport class ApplicationJob {\r\n id: string;\r\n description: string;\r\n smalldescription: string;\r\n percentage: number;\r\n completed: boolean;\r\n fileid: string;\r\n reportid: string;\r\n complexreportid: string;\r\n reportpars: ReportParam[];\r\n}","export class EnvOptions {\r\n constructor(moduleId: string, moduleDef: number, env: string, varsion: string, description: string) {\r\n this.AppData = {\r\n ModuleDefId: moduleDef,\r\n ModuleId: moduleId,\r\n ComponentEnvironment: env,\r\n ComponentVersion: varsion,\r\n ModuleDescription: description\r\n }\r\n }\r\n\r\n //Proprietà di configurazione\r\n AppData: { ModuleId: string, ModuleDefId: number, ComponentEnvironment: string, ComponentVersion: string, ModuleDescription: string };\r\n AuthUrl?: string;\r\n Client?: string;\r\n JaceDashboardUrl?: string;\r\n TransactionTimeoutSeconds: number;\r\n\r\n //Proprietà di sistema\r\n redirectInProgress?: boolean;\r\n};","import { Export } from \"@esfaenza/extensions\";\r\n\r\nexport class KeyValue {\r\n constructor(id: string, description: string) {\r\n this.id = id;\r\n this.description = description;\r\n }\r\n @Export(10, \"Cod.\") id: string;\r\n @Export(20, \"Descrizione\") description: string;\r\n}","/** Rappresentazione di un oggetto generico */\r\nexport class GenericItem {\r\n /**\r\n * Costruttore \r\n * \r\n * @param properties Dizionario Chiave - Valore delle proprietà di questo oggetto generico\r\n */\r\n constructor(public properties: Record<string, string>) { }\r\n}\r\n","export const EMBEDDED_ROUTE: string = \"pages_ext\";\r\nexport const ROUTE: string = \"pages\";","import { ActiveModuleView } from \"./ActiveModuleView\";\r\n\r\n\r\nexport class CategoriesWithModules {\r\n constructor(module: ActiveModuleView) {\r\n this.category = module?.category?.toUpperCase();\r\n this.module_rows = [[module]];\r\n }\r\n category: string;\r\n module_rows: ActiveModuleView[][];\r\n}\r\n","import { JaceModule } from \"./JaceModule\";\r\nimport { JacePermission } from \"./JacePermission\";\r\nimport { JaceRole } from \"./JaceRole\";\r\n\r\nexport class AccountScope {\r\n constructor(public modules: JaceModule[] = [], public roles: JaceRole[] = [], public permissions: JacePermission[] = []) { }\r\n}","export class ActiveModuleView {\r\n constructor(public name: string) { }\r\n idmodule: number;\r\n altname: string;\r\n category: string;\r\n tenant: string;\r\n uiurl: string;\r\n environment: string;\r\n href: string;\r\n}","export class JaceAccount {\r\n idaccount: number;\r\n iduser: number;\r\n idtenant: string;\r\n dsusername: string;\r\n dspassword: string;\r\n dtvalidfrom: Date;\r\n dtvalidto: Date;\r\n sydatains: Date;\r\n sydataupd: Date;\r\n dtlockdown: Date;\r\n syuserupd: string;\r\n syuserins: string;\r\n dsreasonlockdown: string;\r\n cnattempts: number;\r\n\r\n //Solo UI\r\n description: string;\r\n}","import { AccountScope } from \"./AccountScope\";\r\n\r\nexport class JaceIdentity {\r\n Expired: boolean;\r\n IdAccount: number;\r\n IdUser: number;\r\n DsUser: string;\r\n FullName: string;\r\n Idtenant: string;\r\n TenantName: string;\r\n IdActor: number;\r\n IdActorRole: string;\r\n ExpirationTime: Date;\r\n\r\n constructor(scope: AccountScope = null) {\r\n this.Roles = [];\r\n this.Modules = [];\r\n this.Permissions = [];\r\n if (scope) {\r\n // Doppio parametro per gestione del nuovo AUTH.\r\n // TODO: Rimuovere quando non serve\r\n this.Roles = scope.roles.map(x=> x.idrolealt || x.roleidalt);\r\n this.Permissions = scope.permissions.map(x=> x.idpermissionalt || x.permissionidalt);\r\n this.Modules = scope.modules.map(x=> x.idmodule || x.moduleid);\r\n }\r\n }\r\n Roles: string[];\r\n Modules: number[];\r\n Permissions: string[];\r\n}\r\n","export class JaceModule {\r\n constructor(\r\n public idmodule: number,\r\n public dsname?: string,\r\n public dscategory?: string,\r\n public idmodulealt?: string\r\n ) {\r\n this.moduleid = idmodule;\r\n }\r\n\r\n // Nouvo Auth\r\n moduleid?: number;\r\n}\r\n","export class JacePermission {\r\n idpermission: number;\r\n dspermission?: string;\r\n idpermissionalt?: string;\r\n sydatains?: Date;\r\n syuserins?: string;\r\n sydataupd?: Date;\r\n syuserupd?: string;\r\n\r\n // Nuovo Auth\r\n permissionidalt?: string;\r\n}\r\n","export class JaceRole\r\n{\r\n constructor(public idrole: number, public idrolealt: string, public dsrole: string) {\r\n this.roleidalt = idrolealt;\r\n }\r\n\r\n dsnote?: string;\r\n idparent?: number;\r\n sydatains?: Date;\r\n syuserins?: string;\r\n sydataupd?: Date;\r\n syuserupd?: string;\r\n\r\n // Nuovo AUTH\r\n roleidalt?: string;\r\n}","\r\nexport class JaceUser {\r\n iduser: number;\r\n dsnome: string;\r\n dscognome: string;\r\n sydatains: Date;\r\n syuserins: string;\r\n sydataupd: Date;\r\n syuserupd: string;\r\n}\r\n","import { SearchResult } from \"./SearchResult\";\r\n\r\nexport class SearchResultContainer {\r\n constructor(public results: SearchResult[]) { }\r\n}","import { GenericItem } from \"../core/GenericItem\";\r\nimport { KeyValue } from \"../core/KeyValue\";\r\nimport { EsTableColumnsDefinition } from \"@esfaenza/es-table\";\r\n\r\nexport class SearchResult {\r\n\r\n constructor(\r\n public description: string,\r\n public columns: KeyValue[],\r\n public items: GenericItem[]\r\n ) { }\r\n\r\n // Solo UI per la visualizzazione dei risultati\r\n est_cols: EsTableColumnsDefinition[];\r\n}\r\n","export class UpdateAccountRecoverySettingsDto {\r\n constructor(public accountid?: string, public email?: string) { }\r\n}","export class UpdatePasswordDto {\r\n constructor(\r\n public accountid?: string,\r\n public oldpwd?: string,\r\n public newpwd?: string,\r\n public confirmpwd?: string,\r\n public changeall: boolean = true,\r\n public changeforexternals: boolean = true) { }\r\n}","export class UpdateProfilePictureDto {\r\n constructor(public accountid?: string) { }\r\n}","export class UserAccount {\r\n id: string;\r\n tenantid: string;\r\n username: string;\r\n typeid: string;\r\n type: string;\r\n dtvalidfrom: Date;\r\n dtvalidto: Date;\r\n dtlock: Date;\r\n lockreason: string;\r\n userid: string;\r\n userdescription: string;\r\n uuid: string;\r\n firstname: string;\r\n lastname: string;\r\n recoveryemail: string;\r\n recoveryphone: string;\r\n dtottexpiration: Date;\r\n dtlastlogin: Date;\r\n lastloginattempts: number;\r\n islocked: boolean;\r\n isvalid: boolean;\r\n}","export class Feed {\r\n id: string;\r\n parentid: string;\r\n title: string;\r\n content: string;\r\n severityid: string;\r\n systemgen: boolean;\r\n reactions: { [user: string]: string };\r\n user: string;\r\n pinned: boolean;\r\n ispublic: boolean;\r\n dateins: Date;\r\n dateupd: Date;\r\n childfeeds: Feed[];\r\n filename: string;\r\n filesize: string;\r\n // Solo per chatrooms, solo lato ts\r\n fileb64: string;\r\n // Semplicita GUI\r\n liked: boolean;\r\n disliked: boolean;\r\n likes: string[];\r\n dislikes: string[];\r\n}","export class CreateUpdateFeedDto {\r\n idfeed: string;\r\n identity: string;\r\n identitytype: string;\r\n parentid: string;\r\n content: string;\r\n filecontent: number[];\r\n filename: string;\r\n ispublic: boolean;\r\n // Flag terribile per fare funzionare l'edit\r\n updatefiledata: boolean;\r\n}","export class EntityFeedsWidgetConfiguration {\r\n GetFeedsAPI?: string;\r\n AllowUserTags?: boolean;\r\n GetUserTagsAPI?: string;\r\n AllowReactions?: boolean;\r\n ReactToFeedAPI?: string;\r\n AllowAttachments?: boolean;\r\n GetFeedAttachmentAPI?: string;\r\n AllowComments?: boolean;\r\n AllowReplies?: boolean;\r\n CreateFeedAPI?: string;\r\n UpdateFeedAPI?: string;\r\n DeleteFeedAPI?: string;\r\n}","// Angular\r\nimport { InjectionToken, Type } from \"@angular/core\";\r\n\r\n// Configurazioni\r\nimport { LocalizationService } from \"@esfaenza/localizations\";\r\n\r\n// Applicazione\r\nimport { ApplicationMenu } from \"./models/core/ApplicationMenu\";\r\n\r\n/** Token che indica i default da assegnare agli Input */\r\nexport const REDIRECT_MAP: InjectionToken<{ [index: string]: { url: string, params: string[] } }> = new InjectionToken<{ [index: string]: { url: string, params: string[] } }>('REDIRECT_MAP');\r\n\r\n/** Token che indica il servizio di localizzazione utilizzato per i menù */\r\nexport const MENU_LOCALIZATION: InjectionToken<Type<LocalizationService>> = new InjectionToken<Type<LocalizationService>>('MENU_LOCALIZATION');\r\n\r\n/** Token che indica i menù dell'applicazione, da quello vegano fino a quello celiaco */\r\nexport const MENU: InjectionToken<ApplicationMenu[]> = new InjectionToken<ApplicationMenu[]>('MENU');\r\n\r\n/** Token che indica se il servizio di autenticazione deve utilizzare un token finto */\r\nexport const USE_FAKE_ACCESS_TOKEN: InjectionToken<boolean> = new InjectionToken<boolean>('USE_FAKE_ACCESS_TOKEN');\r\n\r\n/** Token che indica se il servizio di autenticazione deve funzionare in anonimo lato Frontend. Dev'essere utilizzato insieme al tag \"Auth\" in code behind */\r\nexport const ANONYMOUS_MODE: InjectionToken<boolean> = new InjectionToken<boolean>('USE_FAKE_ACCESS_TOKEN');\r\n\r\n/** Token che indica i componenti di estensione da aggiungere alla navbar. Verranno bootstrappati in maniera dinamica */\r\nexport const NAVBAR_EXTENSIONS: InjectionToken<Type<any>[]> = new InjectionToken<Type<any>[]>('NAVBAR_EXTENSIONS');\r\n\r\n/** Token che identifica se utilizzare la versione vecchia dell'url di auth (${myconfig.AUTH_URL}/login/form?client=${myconfig.CLIENT_NAME}) invece che la nuova (${myconfig.AUTH_URL}/login;client=${myconfig.CLIENT_NAME}) */\r\nexport const LOGIN_URL_LEGACY: InjectionToken<boolean> = new InjectionToken<boolean>('LOGIN_URL_LEGACY');","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;MAAa,eAAe,CAAA;AACxB,IAAA,WAAA,CACW,KAAa,EACb,IAAa,EACb,UAAmB,EACnB,IAAa,EACb,EAAW,EACX,GAAa,EACb,OAA2B,EAC3B,WAAgB,EAAA;QAPhB,IAAK,CAAA,KAAA,GAAL,KAAK;QACL,IA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AA;AAa1C;;ACbD;AASA;MACa,YAAY,GAA2E,IAAI,cAAc,CAAyD,cAAc;AAE7L;MACa,iBAAiB,GAA8C,IAAI,cAAc,CAA4B,mBAAmB;AAE7I;MACa,IAAI,GAAsC,IAAI,cAAc,CAAoB,MAAM;AAEnG;MACa,qBAAqB,GAA4B,IAAI,cAAc,CAAU,uBAAuB;AAEjH;MACa,cAAc,GAA4B,IAAI,cAAc,CAAU,uBAAuB;AAE1G;MACa,iBAAiB,GAAgC,IAAI,cAAc,CAAc,mBAAmB;AAEjH;MACa,gBAAgB,GAA4B,IAAI,cAAc,CAAU,kBAAkB;;AC5BvG;;AAEG;;;;"}
|
|
@@ -2,7 +2,7 @@ import * as i0 from '@angular/core';
|
|
|
2
2
|
import { Optional, Inject, Injectable, signal } from '@angular/core';
|
|
3
3
|
import { JaceIdentity, USE_FAKE_ACCESS_TOKEN, ANONYMOUS_MODE, ActiveModuleView, UpdateProfilePictureDto, UpdateAccountRecoverySettingsDto, UpdatePasswordDto } from '@esfaenza/core/domain';
|
|
4
4
|
import * as i1 from 'ngx-cookie-service';
|
|
5
|
-
import { of, Subject, firstValueFrom, filter } from 'rxjs';
|
|
5
|
+
import { of, Subject, firstValueFrom, filter, forkJoin } from 'rxjs';
|
|
6
6
|
import * as i2 from '@angular/common/http';
|
|
7
7
|
import { HttpErrorResponse, HttpHeaders, HttpParams } from '@angular/common/http';
|
|
8
8
|
import * as i1$1 from '@angular/router';
|
|
@@ -17,7 +17,7 @@ import { CachePersistor, PreferencesPersistor } from '@esfaenza/preferences';
|
|
|
17
17
|
import * as i4$1 from '@esfaenza/signalr-notifications';
|
|
18
18
|
import * as i5$1 from '@esfaenza/access-control';
|
|
19
19
|
import { AccessControlRouteGuard } from '@esfaenza/access-control';
|
|
20
|
-
import { catchError, map } from 'rxjs/operators';
|
|
20
|
+
import { catchError, map, mergeMap } from 'rxjs/operators';
|
|
21
21
|
import { DomSanitizer } from '@angular/platform-browser';
|
|
22
22
|
|
|
23
23
|
// Angular
|
|
@@ -1521,7 +1521,7 @@ class SessionRetriever {
|
|
|
1521
1521
|
this.anonymousMode = anonymousMode;
|
|
1522
1522
|
}
|
|
1523
1523
|
/** Tenant§Account§User§ModuleId */
|
|
1524
|
-
getSessionKey() {
|
|
1524
|
+
getSessionKey(global) {
|
|
1525
1525
|
if (this.SessionIdentity)
|
|
1526
1526
|
return this.SessionIdentity;
|
|
1527
1527
|
// Se non ho un id mi manca il login, quindi via di qua
|
|
@@ -1533,7 +1533,7 @@ class SessionRetriever {
|
|
|
1533
1533
|
this.router.navigate(["login"]);
|
|
1534
1534
|
return "";
|
|
1535
1535
|
}
|
|
1536
|
-
this.SessionIdentity = "" + id.Idtenant + "§" + id.IdAccount + "§" + id.IdUser + "§" + myconfig?.AppData?.ModuleId;
|
|
1536
|
+
this.SessionIdentity = "" + id.Idtenant + "§" + id.IdAccount + "§" + id.IdUser + "§" + (global ? "GLOBAL" : myconfig?.AppData?.ModuleId);
|
|
1537
1537
|
return this.SessionIdentity;
|
|
1538
1538
|
}
|
|
1539
1539
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: SessionRetriever, deps: [{ token: TokenService }, { token: i1$1.Router }, { token: ANONYMOUS_MODE }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
@@ -1641,14 +1641,14 @@ class ApplicationPreferencesPersistor extends PreferencesPersistor {
|
|
|
1641
1641
|
this.http = http;
|
|
1642
1642
|
this.tks = tks;
|
|
1643
1643
|
}
|
|
1644
|
-
persist(key, item) {
|
|
1645
|
-
let sk = this.session.getSessionKey();
|
|
1644
|
+
persist(key, item, global) {
|
|
1645
|
+
let sk = this.session.getSessionKey(global);
|
|
1646
1646
|
if (!sk)
|
|
1647
1647
|
return of(false);
|
|
1648
1648
|
return this.http.post(this.getItemUrl(sk, key), JSON.stringify(item), { headers: this.getHeaders() }).pipe(catchError(e => of(false)));
|
|
1649
1649
|
}
|
|
1650
|
-
recover(key) {
|
|
1651
|
-
let sk = this.session.getSessionKey();
|
|
1650
|
+
recover(key, global) {
|
|
1651
|
+
let sk = this.session.getSessionKey(global);
|
|
1652
1652
|
if (!sk)
|
|
1653
1653
|
return of(null);
|
|
1654
1654
|
return this.http.get(this.getItemUrl(sk, key), { headers: this.getHeaders() }).pipe(map((res) => {
|
|
@@ -1660,11 +1660,26 @@ class ApplicationPreferencesPersistor extends PreferencesPersistor {
|
|
|
1660
1660
|
return resProp;
|
|
1661
1661
|
}));
|
|
1662
1662
|
}
|
|
1663
|
-
|
|
1663
|
+
// Se globale recupero sia quelle lovali che globali. Comportamento di default
|
|
1664
|
+
recoverAll(global = true) {
|
|
1664
1665
|
let sk = this.session.getSessionKey();
|
|
1665
1666
|
if (!sk)
|
|
1666
1667
|
return of(null);
|
|
1667
|
-
|
|
1668
|
+
var call1 = this.http.get(this.getSessionUrl(sk), { headers: this.getHeaders() }).pipe(catchError(e => of(null)), map((res) => {
|
|
1669
|
+
for (var prop in res) {
|
|
1670
|
+
var resProp = null;
|
|
1671
|
+
try {
|
|
1672
|
+
resProp = JSON.parse(res[prop]);
|
|
1673
|
+
}
|
|
1674
|
+
catch { }
|
|
1675
|
+
res[prop] = resProp;
|
|
1676
|
+
}
|
|
1677
|
+
return res;
|
|
1678
|
+
}));
|
|
1679
|
+
if (!global)
|
|
1680
|
+
return call1;
|
|
1681
|
+
let skGlobal = this.session.getSessionKey();
|
|
1682
|
+
var call2 = this.http.get(this.getSessionUrl(skGlobal), { headers: this.getHeaders() }).pipe(catchError(e => of(null)), map((res) => {
|
|
1668
1683
|
for (var prop in res) {
|
|
1669
1684
|
var resProp = null;
|
|
1670
1685
|
try {
|
|
@@ -1675,14 +1690,24 @@ class ApplicationPreferencesPersistor extends PreferencesPersistor {
|
|
|
1675
1690
|
}
|
|
1676
1691
|
return res;
|
|
1677
1692
|
}));
|
|
1693
|
+
return forkJoin([call1, call2]).pipe(mergeMap((values) => {
|
|
1694
|
+
var dic1 = values[0];
|
|
1695
|
+
var dic2 = values[1];
|
|
1696
|
+
var finalDick = { ...dic1, ...dic2 };
|
|
1697
|
+
return of(finalDick);
|
|
1698
|
+
}));
|
|
1678
1699
|
}
|
|
1679
|
-
remove(key) {
|
|
1680
|
-
let sk = this.session.getSessionKey();
|
|
1700
|
+
remove(key, global) {
|
|
1701
|
+
let sk = this.session.getSessionKey(global);
|
|
1681
1702
|
if (!sk)
|
|
1682
1703
|
return of(false);
|
|
1683
1704
|
return this.http.delete(this.getItemUrl(sk, key), { headers: this.getHeaders() }).pipe(catchError(e => of(false)));
|
|
1684
1705
|
}
|
|
1685
|
-
clear() {
|
|
1706
|
+
clear(global) {
|
|
1707
|
+
if (global) {
|
|
1708
|
+
console.error("Impossibile pulire la cache globale da un applicativo singolo");
|
|
1709
|
+
return of(true);
|
|
1710
|
+
}
|
|
1686
1711
|
let sk = this.session.getSessionKey();
|
|
1687
1712
|
if (!sk)
|
|
1688
1713
|
return of(false);
|