fix: better handling of default page
This commit is contained in:
parent
75c15633f7
commit
9c5f4d5dff
1 changed files with 7 additions and 3 deletions
|
|
@ -140,9 +140,13 @@ export default class Desktop {
|
|||
}
|
||||
|
||||
get_page_to_show() {
|
||||
const default_page = this.sidebar_configuration
|
||||
? this.sidebar_configuration["Modules"][0].name
|
||||
: frappe.boot.allowed_workspaces[0].name;
|
||||
let default_page;
|
||||
|
||||
if (this.sidebar_configuration && this.sidebar_configuration["Modules"]) {
|
||||
default_page = this.sidebar_configuration["Modules"][0].name;
|
||||
} else {
|
||||
default_page = frappe.boot.allowed_workspaces[0].name;
|
||||
}
|
||||
|
||||
let page =
|
||||
frappe.get_route()[1] ||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue