mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[AAE-12501] Align JS API (#8344)
* [AAE-12501] Provide an AlfrescoApiService implementation that disable the AlfrescoApi oauth initialization when we use new oidc implementation * [AAE-12501] Replace oauth2Auth with authentication service, define get username as abstract * [AAE-12501] Replace sitesService with authentication service since sitesService get the username from oauth2Auth * [AAE-12501] Call implicitLogin by authentication service * [AAE-12501] Replace Oauth2Auth with AlfrescoApi and call the custom api without using authentication * [AAE-12501] Replace oauth2Auth with authentication service to get the token * [AAE-12501] Replace oauth2Auth with alfrescoApi * remove unneeded JS-API dep move auth in the right place * [AAE-10501] Rename alfresco-api.http-client to adf-http-client * [AAE-10501] Remove config from a CoreModule, a different service is provided in AuthModule to use angular http client instead of super agent * [AAE-10501] Disable AlfrescoApi oauth initialization while using new adf oidc authentication * [AAE-12501] Replace alfresco api client with AdfHttpClient * [AAE-12501] Restore get username methods * [AAE-12501] Get username with authentication service * [AAE-12501] removee unused method * [AAE-12501] Trigger on login when token is received * [AAE-12501] Fix content-services unit test * [AAE-12501] Fix import * [AAE-12501] Fix core unit tests * [AAE-12501] Fix process-services-cloud unit tests * [AAE-12501] Create a request options interface with the needed props, remove the import from js-api, return the body from request * [AAE-12501] Fix process-services-cloud unit tests without Expectation * [AAE-12501] Fix Core secondary entrypoints unit tests are not executed: move test.ts one level up in order to find all the spec files into the secondary entrypoints folders and update path * [AAE-12501] Fix Core unit tests that weren't executed because of the previous test.ts wrong location * [AAE-12501] Fix authentication token_issued subscription * add emitters * [AAE-12501] Replace Math.random() to fix hospot security issue, fix lint issues * [AAE-12501] Install event-emitter dependency * [AAE-12501] Comment temporary setCsrfToken because is not possible to import app config service from core due to circular dependencies * [AAE-12501] Get disableCsrf from app config serviice when app configuration is loaded * [AAE-12501] Fix license-header lint issue * [AAE-14221] Regenerate lock file * [AAE-14221] Fix sonarcloud issues * [AAE-12501] Remove wrong character * [AAE-12501] Regenerate lock file * [AAE-12501] Fix BC: update alfresco api response error --------- Co-authored-by: eromano <eugenioromano16@gmail.com>
This commit is contained in:
@@ -27,7 +27,6 @@ import { ObjectDataTableAdapter, AuthenticationService } from '@alfresco/adf-cor
|
||||
<li>Global i18n: {{ 'APP_LAYOUT.DATATABLE_LAZY' | translate }}</li>
|
||||
<li>Local i18n (work in progress): {{ 'LAZY.TEXT' | translate }}</li>
|
||||
<li>isLoggedIn: {{ isLoggedIn }}</li>
|
||||
<li>ECM username: {{ username }}
|
||||
</ul>
|
||||
`
|
||||
})
|
||||
@@ -39,10 +38,6 @@ export class LazyLoadingComponent {
|
||||
return this.auth.isLoggedIn();
|
||||
}
|
||||
|
||||
get username(): string {
|
||||
return this.auth.getEcmUsername();
|
||||
}
|
||||
|
||||
constructor(private auth: AuthenticationService) {
|
||||
this.data = new ObjectDataTableAdapter(
|
||||
// data
|
||||
|
@@ -56,8 +56,7 @@ export class AppNotificationsService {
|
||||
) {
|
||||
this.alfrescoApiService.alfrescoApiInitialized.subscribe(() => {
|
||||
if (this.isProcessServicesEnabled() && this.notificationsEnabled) {
|
||||
this.alfrescoApiService.getInstance().oauth2Auth.once('token_issued', () => {
|
||||
|
||||
this.authenticationService.once('token_received').subscribe(() => {
|
||||
const deployedApps = this.appConfigService.get('alfresco-deployed-apps', []);
|
||||
if (deployedApps?.length) {
|
||||
deployedApps.forEach((app) => {
|
||||
@@ -69,11 +68,8 @@ export class AppNotificationsService {
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user