Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Extensibility Request] Standarize the "Show Document" action on" Purchase Lines" and "Posted Purchase Invoice Lines" Pages #27914

Open
KacperGawinkowski opened this issue Jan 9, 2025 · 0 comments

Comments

@KacperGawinkowski
Copy link

Describe the request

Standarize how the "Show Document" action works in "Posted Purchase Invoice Lines" (529), and "Purchase Lines" (518) pages works, by either using "Page Management" (700) codeunit in both cases, or adding OnBeforeShowDocument() event.

Additional context

We would like to customize the functionality of the "Show Document" action in the "Purchase Lines" and "Posted Purchase Invoice Lines" pages to allow us to open our own page if the record meets certain conditions. However, it is not currently possible to do this in an elegant way because of inconsistencies in how the action is implemented.

In the case of "Purchase Lines", the action uses the Page Management codeunit, which provides integration events that can be used to extend its functionality:
Image
However, in the "Posted Purchase Invoice Lines" page, the action is implemented as a direct Page.Run(...) call, which does not allow for any extensibility:
Image

I would suggest either of the following approaches to standardize the functionality and make it extensible:

  1. Use the Page Management codeunit in both pages to standardize how the "Show Document" action works (since the codeunit already has integration events that can be used to extend functionality).
  2. Add an OnBeforeShowDocument(Rec, IsHandled) event (or similar) to allow developers to extend the functionality before the page is opened. This would enable us to stop the execution of the base app and open our own page if needed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant