[Event Request] Extend item mapping logic after importing purchase documents in E-Document Core
Nobody has claimed this yet.
- Dominant language
- AL
- Stars
- 683
- Forks
- 459
- Avg merge
- 3d 26m
- Merged PRs (30d)
- 633
Description
BC Idea Link
https://github.com/microsoft/ALAppExtensions/issues/29259#issuecomment-3421542160
Description
All of our customers have requested the ability to map an item received in a purchase document (order or invoice) in E-Documents using additional fields beyond just Item Reference or GTIN Code.
For example, some have asked to map items based on the EAN Code, Description, Description 2, or even the Item Code. They would like us to implement a multi-layered mapping logic that finds the best possible match.
Although they will review the imported lines afterward, having these extra mapping steps would make the process much more efficient.
Currently, however, it is not possible to add additional logic to map the received item with an item in Business Central.
Describe the request
This is the standard code — codeunit 6140 "E-Doc. Import", local procedure CreatePurchaseDocumentFromImportedDocument(…):
Could you please add a publisher similar to the following:
Currently, we use a default G/L Account when the item cannot be found ΓÇö otherwise, the purchase document could not be created from the E-Document.
At the moment, if there is no Item Reference or GTIN Code, the default G/L Account is used.
However, we need to extend this logic to include additional mapping steps, so adding a publisher here would allow us to implement that extra logic.
Thank you, and have a great day!
I will provide the implementation for this BC Idea
- I will provide the implementation for this BC Idea
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Read codeunit 6140 "E-Doc. Import", especially the local procedure CreatePurchaseDocumentFromImportedDocument(...), to understand where item references and GTIN codes are evaluated. The requested outcome is an extension point at that mapping decision so additional item-matching logic can run before the default G/L Account fallback; verify the surrounding E-Document import behavior afterward.
Written by the indexing model from the issue text.
Assessment
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 55/100