mirror of
https://github.com/Pax1601/DCSOlympus.git
synced 2025-10-29 16:56:34 +00:00
Readded dashboard to manager
This commit is contained in:
@@ -12,16 +12,6 @@ class WizardPage extends ManagerPage {
|
||||
render(str) {
|
||||
super.render(str);
|
||||
|
||||
/* Connect the back, next and cancel buttons */
|
||||
if (this.element.querySelector(".back"))
|
||||
this.element.querySelector(".back").addEventListener("click", (e) => this.onBackClicked(e));
|
||||
|
||||
if (this.element.querySelector(".next"))
|
||||
this.element.querySelector(".next").addEventListener("click", (e) => this.onNextClicked(e));
|
||||
|
||||
if (this.element.querySelector(".cancel"))
|
||||
this.element.querySelector(".cancel").addEventListener("click", (e) => this.onCancelClicked(e));
|
||||
|
||||
ejs.renderFile(this.contentEjsFile, {...this.options, ...this.manager.options}, {}, (err, str) => {
|
||||
if (!err) {
|
||||
this.element.querySelector(".content").innerHTML = str;
|
||||
@@ -31,23 +21,6 @@ class WizardPage extends ManagerPage {
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
onBackClicked() {
|
||||
console.log(this.previousPage)
|
||||
this.hide();
|
||||
this.previousPage.show()
|
||||
}
|
||||
|
||||
onCancelClicked() {
|
||||
this.hide();
|
||||
if (this.manager.options.mode === "basic") {
|
||||
/* In basic mode no dashboard is shown */
|
||||
this.manager.menuPage.show();
|
||||
} else {
|
||||
/* In Expert mode we go directly to the dashboard */
|
||||
this.manager.instancesPage.show();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = WizardPage;
|
||||
Reference in New Issue
Block a user