CST-6685 changes for import batch

This commit is contained in:
Nikunj Sharma
2022-09-13 16:18:32 +05:30
parent e7dc5f8d14
commit c1498424f3
13 changed files with 508 additions and 19 deletions

View File

@@ -448,20 +448,7 @@ export class MenuResolver implements Resolve<boolean> {
* the import scripts exist and the current user is allowed to execute them
*/
createImportMenuSections() {
const menuList = [
// TODO: enable this menu item once the feature has been implemented
// {
// id: 'import_batch',
// parentID: 'import',
// active: false,
// visible: true,
// model: {
// type: MenuItemType.LINK,
// text: 'menu.section.import_batch',
// link: ''
// } as LinkMenuItemModel,
// }
];
const menuList = [];
menuList.forEach((menuSection) => this.menuService.addSection(MenuID.ADMIN, menuSection));
observableCombineLatest([
@@ -498,6 +485,18 @@ export class MenuResolver implements Resolve<boolean> {
} as LinkMenuItemModel,
shouldPersistOnRouteChange: true
});
this.menuService.addSection(MenuID.ADMIN, {
id: 'import_batch',
parentID: 'import',
active: false,
visible: true,
model: {
type: MenuItemType.LINK,
text: 'menu.section.import_batch',
link: '/admin/batch-import'
} as LinkMenuItemModel,
shouldPersistOnRouteChange: true
});
});
}