---
id: change/bcapps/10036
type: change
title: "#10036 [SOA]: Bugbash for releases 28.x - Contact unable to find due to Qasim map to Megan, different names"
summary: Fixes Sales Order Agent contact lookup and reply routing when a sender's email is mapped to a different contact. Lookup, filtering and recipient resolution now consider E-Mail 2 and the task contact override, and replies go to the mapped contact's primary email in the same thread.
tier: official
language: en
tags:
  - fix
  - main
  - bc30
  - codeunit soa contact search impl
  - page soa email message
  - codeunit soa reply retry mgt.
  - codeunit soa send reply
  - codeunit soa task message
  - pageextension soa contact list ext
system: copilot
review:
  state: reviewed
  by: opus
  at: "2026-10-08T02:09:03.746Z"
  flags: []
generated:
  at: "2026-10-08T01:26:53.141Z"
  pipeline: 0.2.0
  prompts:
    extract-change: 1
  input_hash: c7e23ac8fb2ed3e176849e792f25af00b374bebd
evidence:
  - kind: code
    url: https://github.com/microsoft/BCApps/pull/10036
    title: "microsoft/BCApps#10036: [SOA]: Bugbash for releases 28.x - Contact unable to find due to Qasim map to Megan, different names"
    date: "2026-08-13"
    commit: c7e23ac8fb2ed3e176849e792f25af00b374bebd
    t: null
    quote: null
links:
  learn: []
  objects:
    - object/codeunit/4411
    - object/page/4404
    - object/codeunit/4418
    - object/codeunit/4419
    - object/codeunit/4398
    - object/pageextension/4411
    - object/permissionset/4406
    - object/pagecustomization/soa-contact-list
    - object/table/4325
    - object/codeunit/4305
    - object/codeunit/4304
    - object/table/5050
    - object/page/5052
  features: []
  topics: []
  localizations: []
  videos: []
  posts: []
  guidelines: []
  changes: []
number: 10036
repo: microsoft/BCApps
source_id: bcapps-prs
url: https://github.com/microsoft/BCApps/pull/10036
kind: pr
base_branch: main
major: "30"
merged_at: "2026-08-13T12:52:00Z"
author: tomasevicst
author_type: User
community_contribution: false
labels:
  - "AL: Apps (W1)"
  - "Team: SCM"
change_class: code
change_kind: fix
behavior_change: true
breaking: false
files:
  count: 19
  additions: 542
  deletions: 56
  al: 18
apps:
  - Base Application
  - SalesOrderAgent
objects_touched:
  - key: codeunit/4411
    page: codeunit/4411
    type: codeunit
    id: 4411
    name: SOA Contact Search Impl
    app: SalesOrderAgent
    status: added
  - key: page/4404
    page: page/4404
    type: page
    id: 4404
    name: SOA Email Message
    app: SalesOrderAgent
    status: modified
  - key: codeunit/4418
    page: codeunit/4418
    type: codeunit
    id: 4418
    name: SOA Reply Retry Mgt.
    app: SalesOrderAgent
    status: modified
  - key: codeunit/4419
    page: codeunit/4419
    type: codeunit
    id: 4419
    name: SOA Send Reply
    app: SalesOrderAgent
    status: modified
  - key: codeunit/4398
    page: codeunit/4398
    type: codeunit
    id: 4398
    name: SOA Task Message
    app: SalesOrderAgent
    status: modified
  - key: pageextension/4411
    page: pageextension/4411
    type: pageextension
    id: 4411
    name: SOA Contact List Ext
    app: SalesOrderAgent
    status: added
  - key: permissionset/4406
    page: permissionset/4406
    type: permissionset
    id: 4406
    name: SOA - Objects
    app: SalesOrderAgent
    status: modified
  - key: pagecustomization/soa contact list
    page: pagecustomization/soa-contact-list
    type: pagecustomization
    id: null
    name: SOA Contact List
    app: SalesOrderAgent
    status: modified
  - key: table/4325
    page: table/4325
    type: table
    id: 4325
    name: SOA Setup
    app: SalesOrderAgent
    status: modified
  - key: codeunit/4305
    page: codeunit/4305
    type: codeunit
    id: 4305
    name: SOA Filters Impl.
    app: SalesOrderAgent
    status: modified
  - key: codeunit/4304
    page: codeunit/4304
    type: codeunit
    id: 4304
    name: SOA Session Events
    app: SalesOrderAgent
    status: modified
  - key: table/5050
    page: table/5050
    type: table
    id: 5050
    name: Contact
    app: Base Application
    status: modified
  - key: page/5052
    page: page/5052
    type: page
    id: 5052
    name: Contact List
    app: Base Application
    status: modified
objects_unjoined:
  - path: src/Layers/APAC/BaseApp/CRM/Contact/ContactList.Page.al
    status: modified
    reason: not-in-snapshot
obsoletions: []
backports: []
fixes_issues: []
work_items:
  - 640657
systems:
  - copilot
  - crm
quote: null
joined_against:
  major: "30"
  commit: f18567dc08e2bd162bf192e1da4d714b57eb099f
---

# #10036 [SOA]: Bugbash for releases 28.x - Contact unable to find due to Qasim map to Megan, different names

> Fixes Sales Order Agent contact lookup and reply routing when a sender's email is mapped to a different contact. Lookup, filtering and recipient resolution now consider E-Mail 2 and the task contact override, and replies go to the mapped contact's primary email in the same thread.

[Pull request](https://github.com/microsoft/BCApps/pull/10036) · merged into `main` (BC30) on 2026-08-13 by tomasevicst · 19 files (+542 -56), 18 AL · fix · tier official · reviewed (checked by Opus)

## What changed

- Contact lookup resolves the contact stored in SOA Task Contact Override for the active input message
- Lookup, security filtering and known-sender checks consider both E-Mail and E-Mail 2
- Replies stay in the original thread but are addressed to the mapped contact, keeping CC and BCC
- New Contact List OnBeforeFindRecord event, with the subscriber bound only during SOA sessions
- Agent instructions treat the mapped contact as authoritative instead of asking for help over the mismatch
- Behaviour changes for users or extensions.

## AL objects touched

- [Codeunit 4411 "SOA Contact Search Impl"](../../objects/codeunit/4411.md), SalesOrderAgent: added
- [Page 4404 "SOA Email Message"](../../objects/page/4404.md), SalesOrderAgent: modified
- [Codeunit 4418 "SOA Reply Retry Mgt."](../../objects/codeunit/4418.md), SalesOrderAgent: modified
- [Codeunit 4419 "SOA Send Reply"](../../objects/codeunit/4419.md), SalesOrderAgent: modified
- [Codeunit 4398 "SOA Task Message"](../../objects/codeunit/4398.md), SalesOrderAgent: modified
- [Page extension 4411 "SOA Contact List Ext"](../../objects/pageextension/4411.md), SalesOrderAgent: added
- [Permission set 4406 "SOA - Objects"](../../objects/permissionset/4406.md), SalesOrderAgent: modified
- [pagecustomization "SOA Contact List"](../../objects/pagecustomization/soa-contact-list.md), SalesOrderAgent: modified
- [Table 4325 "SOA Setup"](../../objects/table/4325.md), SalesOrderAgent: modified
- [Codeunit 4305 "SOA Filters Impl."](../../objects/codeunit/4305.md), SalesOrderAgent: modified
- [Codeunit 4304 "SOA Session Events"](../../objects/codeunit/4304.md), SalesOrderAgent: modified
- [Table 5050 "Contact"](../../objects/table/5050.md), Base Application: modified
- [Page 5052 "Contact List"](../../objects/page/5052.md), Base Application: modified
- `src/Layers/APAC/BaseApp/CRM/Contact/ContactList.Page.al`: modified, not in the BC30 snapshot

## Context

- Work items: AB#640657
- Labels: AL: Apps (W1), Team: SCM
- Systems: copilot, crm

Source: metadata of a merged pull request in microsoft/BCApps (bcapps): title, labels, changed paths and counts, with a summary in our words. No source text and no description beyond one short quote (D10, D61).
