MOBILE-3320 glossary: Fix link clicks in tablet

main
Dani Palou 2021-06-09 13:38:02 +02:00
parent ed00cefbae
commit 287496c8ec
3 changed files with 18 additions and 2 deletions

View File

@ -48,6 +48,14 @@ export const ADDON_MOD_GLOSSARY_SERVICES: Type<unknown>[] = [
];
const mainMenuRoutes: Routes = [
{
path: `${AddonModGlossaryModuleHandlerService.PAGE_NAME}/entry/:entryId`,
loadChildren: () => import('./pages/entry/entry.module').then(m => m.AddonModGlossaryEntryPageModule),
},
{
path: `${AddonModGlossaryModuleHandlerService.PAGE_NAME}/edit/:timecreated`,
loadChildren: () => import('./pages/edit/edit.module').then(m => m.AddonModGlossaryEditPageModule),
},
{
path: AddonModGlossaryModuleHandlerService.PAGE_NAME,
loadChildren: () => import('./glossary-lazy.module').then(m => m.AddonModGlossaryLazyModule),

View File

@ -47,8 +47,12 @@ export class AddonModGlossaryEditLinkHandlerService extends CoreContentLinksHand
const module = await CoreCourse.getModuleBasicInfo(cmId, siteId);
await CoreNavigator.navigateToSitePath(
AddonModGlossaryModuleHandlerService.PAGE_NAME + `/${module.course}/${module.id}/edit/0`,
AddonModGlossaryModuleHandlerService.PAGE_NAME + '/edit/0',
{
params: {
courseId: module.course,
cmId: module.id,
},
siteId,
},
);

View File

@ -52,8 +52,12 @@ export class AddonModGlossaryEntryLinkHandlerService extends CoreContentLinksHan
);
await CoreNavigator.navigateToSitePath(
AddonModGlossaryModuleHandlerService.PAGE_NAME + `/${module.course}/${module.id}/entry/${entryId}`,
AddonModGlossaryModuleHandlerService.PAGE_NAME + `/entry/${entryId}`,
{
params: {
courseId: module.course,
cmId: module.id,
},
siteId,
},
);