Skip to content

feat(manager-log): Add manager links to log entries#16897

Open
Ibochkarev wants to merge 3 commits intomodxcms:3.xfrom
Ibochkarev:feat/13780-manager-log-links
Open

feat(manager-log): Add manager links to log entries#16897
Ibochkarev wants to merge 3 commits intomodxcms:3.xfrom
Ibochkarev:feat/13780-manager-log-links

Conversation

@Ibochkarev
Copy link
Collaborator

@Ibochkarev Ibochkarev commented Feb 25, 2026

What does it do?

Adds clickable manager URLs to Manager Log entries. When a log entry references a resource, template, chunk, or other element, the grid now shows a link that opens the corresponding edit page in the manager.

Backend (System/Log/GetList): New getManagerUrl(classKey, item, obj) builds the relative manager URL for resources, contexts, elements (template/chunk/snippet/plugin/category), user, menu, settings, access policy/template, resource group, media source, namespace, dashboard/widget, transport package, content type.

Frontend (modx.grid.manager.log): Object column uses a custom renderer that renders a link when managerUrl is present, opening in a new tab.

Why is it needed?

Improves workflow when reviewing manager logs—users can jump directly to the affected resource or element instead of searching manually.

How to test

  1. Open Manager → System → Manager Log.
  2. Trigger actions that log objects (e.g. edit a resource, chunk, user).
  3. Confirm the object column shows links where applicable.
  4. Click a link and confirm it opens the correct manager page in a new tab.

Related issue(s)/PR(s)

Resolves #13780

@Ibochkarev Ibochkarev force-pushed the feat/13780-manager-log-links branch from 37f4997 to 427dc57 Compare February 25, 2026 03:22
@Ibochkarev Ibochkarev marked this pull request as ready for review February 25, 2026 03:23
@Ibochkarev Ibochkarev changed the title feat(manager-log): Add manager links to log entries (#13780) feat: Manager log links (#13780) and childTemplate property (#13753) Feb 25, 2026
@Ibochkarev Ibochkarev changed the title feat: Manager log links (#13780) and childTemplate property (#13753) feat(manager-log): Add manager links to log entries (#13780) Feb 25, 2026
@Ibochkarev Ibochkarev changed the title feat(manager-log): Add manager links to log entries (#13780) feat(manager-log): Add manager links to log entries Feb 25, 2026
@Ibochkarev Ibochkarev force-pushed the feat/13780-manager-log-links branch from 851a6c3 to 427dc57 Compare February 25, 2026 03:28
@biz87
Copy link

biz87 commented Feb 25, 2026

Code Review

Summary

Adds clickable manager links to Manager Log entries. Backend builds URLs via getManagerUrl() (switch over 20+ class keys), frontend renders links in the grid. +163/-3.

Suggestions

  • GetList.php:242getManagerUrl() is declared public but only called from prepareLog(). Consider protected.
  • Verify that this.renderLink() exists in MODx.grid.Grid base class, otherwise JS will throw a runtime error.
  • htmlEncode is correctly applied to text portions; http_build_query with PHP_QUERY_RFC3986 on the backend is safe.

Assessment

Well-implemented feature covering all major object types. The switch-based mapping is justified since each type has distinct URL patterns and parameter keys.

Verdict

Approve — suggestions are optional.

@Ibochkarev Ibochkarev added the feature Request about implementing a brand new function or possibility. label Feb 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature Request about implementing a brand new function or possibility.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add Manager Links to MODX Manager Logs

2 participants