#42964·frappe

侧边栏解析器会丢弃第三方应用程序的侧边栏,因为它通过前一个 DocType 的模块(版本 16)过滤候选项。

作者: paulxt创建于 2026年9月17日更新于 2026年9月18日

Frappe version: version-16 (reproduced on v16.32.0 and v16.34.0). Not reproducible on develop: the sidebar resolver was rewritten there between 2026-09-04 and 2026-09-08 (latest 4edd7f9 "fix: change dock based on doctype"); resolve_sidebar_for() reads a report's module from frappe.boot.entity_module and its comment says "Resolution never looks at which app the route belongs to". This report asks for a backport of that behaviour, or the minimal patch below, to version-16.

Affected code

  • frappe/public/js/frappe/ui/sidebar/sidebar.js: set_workspace_sidebar() (L665–L690), resolve_sidebar() (L709–L745), filter_sidebars_from_app() (L746–L756)
  • frappe/public/js/frappe/router.js: set_doctype_route() L206 (this.meta = meta)

Steps to reproduce

  1. Install any app besides erpnext that ships a Script Report and a Workspace Sidebar (or just a Module Def — Frappe auto-generates a sidebar per module via auto_generate_sidebar_from_module()). The report's module is the app's own module. Call the app myapp, the module My Module, the report My Report.
  2. Open any ERPNext page that belongs to a different app, e.g. /app/stock-entry (module Stock, app erpnext). The Stock sidebar is shown.
  3. Navigate in-app to the report — via the awesomebar (Ctrl+K → "My Report"), or by pasting /app/query-report/My Report in the URL bar.