fix: redirect to default app is not working
This commit is contained in:
parent
0d6ecfbd22
commit
14b9800baf
1 changed files with 3 additions and 4 deletions
|
|
@ -33,10 +33,9 @@ def get_apps():
|
|||
|
||||
|
||||
def get_route(app_name):
|
||||
hooks = frappe.get_hooks(app_name=app_name)
|
||||
if hooks.get("app_icon_route"):
|
||||
return hooks.get("app_icon_route")[0]
|
||||
return "/apps"
|
||||
links = frappe.get_hooks("add_to_apps_screen", app_name=app_name)
|
||||
app = next((link for link in links if link.get("name") == app_name), None)
|
||||
return app.get("route") if app and app.get("route") else "/apps"
|
||||
|
||||
|
||||
def is_desk_apps(apps):
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue