Content
B2B Company Accounts: Map Buyers, Locations and Approvers to ERP Customers
Time to read: 5 minutes
When a buyer moves branches or a branch changes billing accounts, update the buyer’s permissions and the ERP mapping separately. The buyer’s assignment determines where they can act and what they can do. The branch’s ERP mapping identifies which customer gets billed and which ship-to records are eligible. Check the order’s selected destination against that list. Neither change should rewrite an order that has already been accepted.
For a B2B ecommerce product owner, the test is whether the portal can handle both changes without giving a buyer access to the wrong records, billing an old customer account, or sending a request to the wrong approver.
Map the purchasing location, not just the delivery address
A company groups buying locations. A purchasing location is the context in which someone orders or approves; it may have several permitted delivery addresses. A buyer is a named user with a role at one or more locations. An approver has separate authority for a defined location and may not be allowed to buy there. An ERP customer record identifies the party the back office recognizes for billing; a separate ship-to record may identify the destination selected on the order. Check how your ERP represents these relationships rather than assuming each portal branch needs its own billing account.
Keep two records you can review independently:
- Membership: user, company, location, permitted actions, and effective dates. Spell out whether buyers can view their own orders, use saved addresses, submit drafts, or see invoices. Give approvers access to the information needed to decide, not automatic access to all orders or documents.
- ERP mapping: company and purchasing location, authorized ERP billing customer, permitted ship-to IDs, and effective dates. The customer-master owner approves this record. Validate the selected destination against the eligible ship-to IDs for that billing customer. If the billing mapping or destination cannot be validated, hold submission for review rather than picking a default account or address.
Worked example: a buyer transfer and a billing change on the same day
All names, IDs, policies, and expected results below are fictional. In this example, Harbor Fixture Supply keeps both branches under one portal company. On June 1, buyer Jules transfers from Reno to Boise, and finance gives Boise a separate billing account. Accepted orders retain their original ERP references. Only finance users assigned to the location can retrieve its invoices.
| Record | Through May 31 | From June 1 |
|---|---|---|
| Reno location | ERP billing C-410, ship-to S-14 | Unchanged |
| Boise location | ERP billing C-410, ship-to S-27 | ERP billing C-825, same ship-to S-27; ERP owner verifies the pairing |
| Jules’s buyer membership | Reno only | Boise only; no continuing Reno order access |
| Morgan’s approval membership | Boise only; cannot place orders | Unchanged; no authority over Reno requests |
| Accepted Boise order from May 29 | C-410 / S-27 | Keeps those IDs; authorized Boise finance staff can still retrieve its invoice |
On June 1, Jules opens a saved Reno draft. The portal tells Jules that the draft belongs to a location they can no longer use; it does not move the draft to Boise or send it to Morgan. For a new Boise request, the portal validates Jules’s selected destination against S-27. Morgan can approve the request but cannot place the order. The portal sends the order to ERP under C-825 / S-27 only after the required approval. If a Boise request was already approved under the previous billing account but not submitted, the policy in this example sends it back for review under the new mapping. Record who owns that decision in your own policy.
Counterexample: A team uses the ERP billing customer ID as its portal access key. Reno and Boise shared C-410 before June, so the model cannot distinguish their records by location. After the cutover, replacing C-410 with C-825 everywhere risks breaking access to old Boise invoices. Keep the portal location stable, date the mapping change, and check historical document access against the order’s recorded location and the viewer’s current authority.
Prove the cutover before changing live accounts
Use two locations under one company and a third location under a separate company in a test environment. Have customer purchasing confirm the role assignments, the ERP owner reconcile the billing and ship-to IDs, and security confirm which records each user can see.
- Before the change: place a permitted test order for each branch. Confirm separate location access even when both use the same billing customer. Verify that users cannot view records from the separate company and that an approver cannot decide outside their location.
- At the change: end the old membership and activate the new membership and ERP mapping at the agreed effective time. Check an already-open session and a saved document link: neither should retain access beyond policy. Route open drafts or approvals with changed authority or billing to their named owner; do not silently transfer them.
- After the change: reconcile a new Boise test order with the ERP and retrieve an older Boise invoice as an authorized finance user. Test a missing or ambiguous mapping as well: submission should stop, and support should know who resolves it.
Start with one customer’s sanitized location map and one upcoming change. Keep the platform’s native roles if they enforce the tested boundaries; scope integration work only for the mapping or lifecycle behavior you cannot represent. Dinarys’ SanMar ERP integration case describes a custom connector that translated a legacy ERP format for Magento. That is the data-exchange layer; the account cutover and permission rules above are what you test on top of it.
Lassen Sie Profis Ihre Herausforderung meistern
Unsere zertifizierten Spezialisten finden die optimale Lösung für Ihr Unternehmen.