MOBILE-3320 siteplugins: Fix routes of some type of plugins

main
Dani Palou 2021-07-09 11:54:00 +02:00
parent 536d7cfa56
commit 5e48a314cd
5 changed files with 6 additions and 4 deletions

View File

@ -94,7 +94,7 @@ export class CoreSitePluginsCourseOptionHandler extends CoreSitePluginsBaseHandl
title: this.title,
class: this.handlerSchema.displaydata?.class,
icon: this.handlerSchema.displaydata?.icon || '',
page: `siteplugins/${this.plugin.component}/${this.handlerSchema.method}/${hash}`,
page: `siteplugins/content/${this.plugin.component}/${this.handlerSchema.method}/${hash}`,
pageParams: {
title: this.title,
args,

View File

@ -47,7 +47,7 @@ export class CoreSitePluginsMainMenuHandler extends CoreSitePluginsBaseHandler i
title: this.title,
icon: this.handlerSchema.displaydata?.icon || 'fas-question',
class: this.handlerSchema.displaydata?.class,
page: `siteplugins/${this.plugin.component}/${this.handlerSchema.method}/0`,
page: `siteplugins/content/${this.plugin.component}/${this.handlerSchema.method}/0`,
pageParams: {
title: this.title,
initResult: this.initResult,

View File

@ -44,7 +44,7 @@ export class CoreSitePluginsMessageOutputHandler extends CoreSitePluginsBaseHand
priority: this.handlerSchema.priority || 0,
label: this.title,
icon: this.handlerSchema.displaydata?.icon || 'fas-question',
page: `siteplugins/${this.plugin.component}/${this.handlerSchema.method}/0`,
page: `siteplugins/content/${this.plugin.component}/${this.handlerSchema.method}/0`,
pageParams: {
title: this.title,
initResult: this.initResult,

View File

@ -49,7 +49,7 @@ export class CoreSitePluginsSettingsHandler extends CoreSitePluginsBaseHandler i
title: this.title,
icon: this.handlerSchema.displaydata?.icon,
class: this.handlerSchema.displaydata?.class,
page: `siteplugins/${this.plugin.component}/${this.handlerSchema.method}/0`,
page: `siteplugins/content/${this.plugin.component}/${this.handlerSchema.method}/0`,
params: {
title: this.title,
initResult: this.initResult,

View File

@ -18,6 +18,7 @@ import { Routes } from '@angular/router';
import { CoreCourseIndexRoutingModule } from '@features/course/pages/index/index-routing.module';
import { CoreMainMenuTabRoutingModule } from '@features/mainmenu/mainmenu-tab-routing.module';
import { CoreMainMenuHomeRoutingModule } from '@features/mainmenu/pages/home/home-routing.module';
import { CoreSitePreferencesRoutingModule } from '@features/settings/pages/site/site-routing';
import { CoreSitePluginsComponentsModule } from './components/components.module';
import { CoreSitePluginsHelper } from './services/siteplugins-helper';
@ -55,6 +56,7 @@ const moduleRoutes: Routes = [
CoreMainMenuTabRoutingModule.forChild(moduleRoutes.concat(routes)),
CoreCourseIndexRoutingModule.forChild({ children: courseIndexRoutes }),
CoreMainMenuHomeRoutingModule.forChild({ children: homeRoutes }),
CoreSitePreferencesRoutingModule.forChild(routes),
CoreSitePluginsComponentsModule,
],
providers: [