[ACS-9859] revert wrong code deletion

This commit is contained in:
g-jaskowski
2025-08-06 11:13:33 +02:00
parent d912c3c23b
commit 38a6cc76bf
4 changed files with 58 additions and 1 deletions

View File

@@ -0,0 +1,25 @@
/*!
* Copyright © 2005-2025 Hyland Software, Inc. and its affiliates. All rights reserved.
*
* Alfresco Example Content Application
*
* This file is part of the Alfresco Example Content Application.
* If the software was purchased under a paid Alfresco license, the terms of
* the paid license agreement will prevail. Otherwise, the software is
* provided under the following open source license terms:
*
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
*/
export { INITIAL_APP_STATE } from '@alfresco/aca-shared/store';

View File

@@ -38,10 +38,11 @@ import {
SetInfoDrawerPreviewStateAction,
AppActionTypes,
ShowLoaderAction,
INITIAL_APP_STATE,
SetSearchItemsTotalCountAction
} from '@alfresco/aca-shared/store';
export function appReducer(state: AppState, action: Action): AppState {
export function appReducer(state: AppState = INITIAL_APP_STATE, action: Action): AppState {
let newState: AppState;
switch (action.type) {

View File

@@ -28,6 +28,7 @@
export * from './lib/aca-content.module';
export * from './lib/aca-content.routes';
export * from './lib/store/initial-state';
export * from './lib/services/content-url.service';
export * from './lib/services/content-management.service';
export * from './lib/components/info-drawer/comments-tab/external-node-permission-comments-tab.service';

View File

@@ -25,6 +25,36 @@
import { SelectionState, ProfileState, NavigationState } from '@alfresco/adf-extensions';
import { RepositoryInfo, VersionEntry } from '@alfresco/js-api';
export const INITIAL_APP_STATE: AppState = {
user: {
isAdmin: null,
id: null,
firstName: '',
lastName: ''
},
selection: {
nodes: [],
libraries: [],
isEmpty: true,
count: 0
},
navigation: {
currentFolder: null
},
currentNodeVersion: null,
infoDrawerOpened: false,
infoDrawerPreview: false,
infoDrawerMetadataAspect: '',
fileUploadingDialog: true,
showLoader: false,
repository: {
status: {
isQuickShareEnabled: true
}
} as any,
searchItemsTotalCount: null
};
export interface AppState {
currentNodeVersion: VersionEntry;
selection: SelectionState;