Spiegel von
https://github.com/paviliondev/discourse-custom-wizard.git
synchronisiert 2024-11-09 20:02:54 +01:00
tweak
Dieser Commit ist enthalten in:
Ursprung
80fccbf093
Commit
1425c1e783
1 geänderte Dateien mit 5 neuen und 2 gelöschten Zeilen
|
@ -2,8 +2,9 @@ export default {
|
||||||
name: 'custom-routes',
|
name: 'custom-routes',
|
||||||
|
|
||||||
initialize(app) {
|
initialize(app) {
|
||||||
console.log('running initializer', app.constructor.name, app.get('rootElement'))
|
console.log('running custom initializer')
|
||||||
if (app.constructor.name !== 'Class' || app.get('rootElement') !== '#custom-wizard-main') return;
|
if (app.constructor.name !== 'Class' || typeof app.get !== 'function' ||
|
||||||
|
app.get('rootElement') !== '#custom-wizard-main') return;
|
||||||
|
|
||||||
const Router = requirejs('wizard/router').default;
|
const Router = requirejs('wizard/router').default;
|
||||||
const ApplicationRoute = requirejs('wizard/routes/application').default;
|
const ApplicationRoute = requirejs('wizard/routes/application').default;
|
||||||
|
@ -24,6 +25,8 @@ export default {
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
console.log("added routes")
|
||||||
|
|
||||||
ApplicationRoute.reopen({
|
ApplicationRoute.reopen({
|
||||||
redirect() {
|
redirect() {
|
||||||
this.transitionTo('custom');
|
this.transitionTo('custom');
|
||||||
|
|
Laden …
In neuem Issue referenzieren