You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Due for payment 2026-11-02] [Vendor matching CC] App: enable/disable imported vendors and bulk actions #98355
This is the App workstream for imported-vendor enable/disable controls.
It consumes the agreed policyVendors_{policyID} collection and the SetPolicyVendorsEnabled command. It may begin after Phase 0 establishes that contract, but functional completion/release depends on the Phase 1 backend work and Phase 2 end-to-end integration.
The workspace Vendors page must show all currently imported vendors, including disabled vendors, so workspace admins can re-enable them.
For new expenses, disabled vendors must not be available in vendor search or selection. If an expense already has a vendor that later becomes disabled, retain and visibly mark that current historical value, but do not expose it as a general picker result. The user may select an enabled replacement.
Scope
Read policyVendors_{policyID}; do not read or mutate policy.connections.*.data directly.
Add an enabled/disabled toggle to each imported-vendor row.
Add row selection and bulk Enable/Disable actions, following the Workspace Categories table and bulk-action pattern.
Use one App action for both individual and bulk changes, calling:
@MelvinBot plan out the required changes for this issue. Also make an issue in Expensify/Expensify repo in order to plan out and implement the backend changes for this project, and assign me and Jenna there too.
Sees that issue with a prompt for MelvinBot to plan out the backend changes for all the features planned in this issue
Frontend plan — enable/disable toggle + bulk action for Vendors
Closest pattern to copy: the Workspaces > Categories page. It already uses the exact same @components/Table stack the Vendors page uses, plus the ImportedFromAccountingSoftware banner and the same ButtonWithDropdownMenu bulk-selection UX we want — so it's a near drop-in template.
Backend planning issue created: Expensify/Expensify#670690 (assigned to Beamanator and heyjennahay), with a prompt for me to plan the backend work. The frontend can't fully land until the backend design lands — see the ⚠️ blockers below.
Changes required
1. Data model — add an enabled field to vendors
The Vendor type (src/types/onyx/Policy.ts:410-422) is {id, name, currency, email} today — no enabled. Add enabled: boolean (plus pendingFields/pendingAction/errors for optimistic UI, mirroring categories).
⚠️Blocked on backend: vendors currently live inside policy.connections.<integration>.data, which accounting sync overwrites — so the enabled-state persistence location is a backend design decision (tracked in #670690, coordinated with the top-level-Onyx-key refactor Expensify/Expensify#650596). The frontend Onyx read shape depends on the outcome.
Add selectedVendorKeys state + canSelectMultiple, mirroring WorkspaceCategoriesPage.
Carry enabled through the vendorRows map (currently only {keyForList, name} at lines 46-53).
Add a getHeaderButtons() that renders ButtonWithDropdownMenu (variant SUCCESS, customText={translate('workspace.common.selected', {count})}) when 2+ rows are selected. Push a Disable option when any selected vendor is enabled and an Enable option when any selected is disabled — so a mixed selection shows both, exactly as the issue describes.
Pass selectionEnabled / selectedKeys / onRowSelectionChange to the shared Table (props already exist on it — used by categories).
Extend WorkspaceVendorTableRowData with enabled + onToggleEnabled, add an enabled column rendering a <Switch> and an actions caret column, and set rows interactive (currently interactive={false} at line 51).
4. New action + API command
Add src/libs/actions/Policy/Vendor.ts with setWorkspaceVendorEnabled mirroring setWorkspaceCategoryEnabled (optimistic pendingFields.enabled = UPDATE, success clears, failure restores + sets errors). One handler serves both the single toggle and the bulk action.
Register a new write command (working name SetPolicyVendorsEnabled) + params type. ⚠️Blocked on backend — this command doesn't exist yet; name/params/response come from #670690.
The picker builds its list from getMatchingVendors(policy). Filter out enabled === false here (or via a new enabled-aware helper). Do not filter the getMatchingVendors/findVendorByID lookups used by MoneyRequestView, ViolationsUtils, and ModifiedExpenseMessage — historical transactions must still show their (now-disabled) vendor name.
6. Copy — add translation strings for the enable/disable menu items, toggle labels, and the "X selected" button in src/languages/*.ts.
Why Categories is the right template (vs. Tags/Taxes/ReportFields)
Tags/Taxes/ReportFields use the older SelectionListWithModal; copying them would also mean swapping out the Vendors table component. Categories uses the same modern @components/Table that Vendors already renders, the same ImportedFromAccountingSoftware banner, and the same accounting-connection sourcing — so the diff is additive rather than a rewrite. The mixed-selection "show both Enable and Disable" logic already exists in WorkspaceCategoriesPage.getHeaderButtons() and the per-row <Switch> in WorkspaceCategoriesTableRow.
Next Steps for Contributor+ team: To accept:@MelvinBot implement [this](https://github.com/Expensify/App/issues/98355#issuecomment-5258533964) to create a draft PR (best done once the backend command/persistence shape from Expensify/Expensify#670690 is settled). To refine:@MelvinBot <your feedback> To reject: Explain why you are rejecting Melvin's plan.
On Tue, Aug 11, 2026 at 1:40 PM MelvinBot ***@***.***> wrote:
*MelvinBot* left a comment (Expensify/App#98355)
<#98355 (comment)>
Frontend plan — enable/disable toggle + bulk action for Vendors
*Closest pattern to copy:* the Workspaces > Categories page. It already
uses the exact same @components/Table stack the Vendors page uses, plus
the ImportedFromAccountingSoftware banner and the same
ButtonWithDropdownMenu bulk-selection UX we want — so it's a near drop-in
template.
*Backend planning issue created:* Expensify/Expensify#670690
<Expensify/Expensify#670690> (assigned to
Beamanator and heyjennahay), with a prompt for me to plan the backend
work. The frontend can't fully land until the backend design lands — see
the ⚠️ blockers below.
Changes required
*1. Data model — add an enabled field to vendors*
- The Vendor type (src/types/onyx/Policy.ts:410-422
<https://github.com/Expensify/App/blob/9e1c21f5a44b68d71bb95a0ff63920c56bc2b537/src/types/onyx/Policy.ts#L410-L422>)
is {id, name, currency, email} today — no enabled. Add enabled: boolean
(plus pendingFields/pendingAction/errors for optimistic UI, mirroring
categories).
- ⚠️ *Blocked on backend:* vendors currently live inside
policy.connections.<integration>.data, which accounting sync
overwrites — so the enabled-state persistence location is a backend design
decision (tracked in #670690, coordinated with the top-level-Onyx-key
refactor Expensify/Expensify#650596
<Expensify/Expensify#650596>). The frontend
Onyx read shape depends on the outcome.
*2. Page — add selection mode + bulk dropdown* (WorkspaceVendorsPage.tsx
<https://github.com/Expensify/App/blob/9e1c21f5a44b68d71bb95a0ff63920c56bc2b537/src/pages/workspace/vendors/WorkspaceVendorsPage.tsx>
)
- Add selectedVendorKeys state + canSelectMultiple, mirroring
WorkspaceCategoriesPage.
- Carry enabled through the vendorRows map (currently only {keyForList,
name} at lines 46-53).
- Add a getHeaderButtons() that renders ButtonWithDropdownMenu
(variant SUCCESS, customText={translate('workspace.common.selected',
{count})}) when 2+ rows are selected. Push a *Disable* option when any
selected vendor is enabled and an *Enable* option when any selected is
disabled — so a mixed selection shows both, exactly as the issue describes.
*3. Table — enable per-row selection + toggle* (
WorkspaceVendorsTable/index.tsx
<https://github.com/Expensify/App/blob/9e1c21f5a44b68d71bb95a0ff63920c56bc2b537/src/components/Tables/WorkspaceVendorsTable/index.tsx>
)
- Pass selectionEnabled / selectedKeys / onRowSelectionChange to the
shared Table (props already exist on it — used by categories).
- Extend WorkspaceVendorTableRowData with enabled + onToggleEnabled,
add an enabled column rendering a <Switch> and an actions caret
column, and set rows interactive (currently interactive={false} at
line 51).
*4. New action + API command*
- Add src/libs/actions/Policy/Vendor.ts with setWorkspaceVendorEnabled
mirroring setWorkspaceCategoryEnabled
<https://github.com/Expensify/App/blob/9e1c21f5a44b68d71bb95a0ff63920c56bc2b537/src/libs/actions/Policy/Category.ts#L310-L422>
(optimistic pendingFields.enabled = UPDATE, success clears, failure
restores + sets errors). One handler serves both the single toggle and
the bulk action.
- Register a new write command (working name SetPolicyVendorsEnabled)
+ params type. ⚠️ *Blocked on backend* — this command doesn't exist
yet; name/params/response come from #670690.
*5. Filter disabled vendors out of the coding picker* (
IOURequestStepVendor.tsx:74
<https://github.com/Expensify/App/blob/9e1c21f5a44b68d71bb95a0ff63920c56bc2b537/src/pages/iou/request/step/IOURequestStepVendor.tsx#L74>
)
- The picker builds its list from getMatchingVendors(policy). Filter
out enabled === false here (or via a new enabled-aware helper). *Do
not* filter the getMatchingVendors/findVendorByID lookups used by
MoneyRequestView, ViolationsUtils, and ModifiedExpenseMessage —
historical transactions must still show their (now-disabled) vendor name.
*6. Copy* — add translation strings for the enable/disable menu items,
toggle labels, and the "X selected" button in src/languages/*.ts.
Why Categories is the right template (vs. Tags/Taxes/ReportFields)
Tags/Taxes/ReportFields use the older SelectionListWithModal; copying
them would also mean swapping out the Vendors table component. Categories
uses the same modern @components/Table that Vendors already renders, the
same ImportedFromAccountingSoftware banner, and the same
accounting-connection sourcing — so the diff is additive rather than a
rewrite. The mixed-selection "show both Enable and Disable" logic already
exists in WorkspaceCategoriesPage.getHeaderButtons() and the per-row
<Switch> in WorkspaceCategoriesTableRow.
------------------------------
*Next Steps for Contributor+ team:*
*To accept:* @MelvinBot implement [this](
#98355 (comment)) to
create a draft PR (best done once the backend command/persistence shape
from Expensify/Expensify#670690
<Expensify/Expensify#670690> is settled).
*To refine:* @MelvinBot <your feedback>
*To reject:* Explain why you are rejecting Melvin's plan.
—
Reply to this email directly, view it on GitHub
<#98355?email_source=notifications&email_token=AA5UTP2DRFPVUCIOK2XLDVL5JOACTA5CNFSNUABFM5UWIORPF5TWS5BNNB2WEL2JONZXKZKDN5WW2ZLOOQXTKMRVHA2TSNZTGE42M4TFMFZW63VGMFZXG2LHN2SWK5TFNZ2KYZTPN52GK4S7MNWGSY3L#issuecomment-5258597319>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AA5UTP7KT74CTB742EYPBPL5JOACTAVCNFSNUABFKJSXA33TNF2G64TZHMZDQNJZGAZDMOBZHNEXG43VMU5TKMJSGM4TIMJWGEYKC5QC>
.
You are receiving this because you were assigned.Message ID:
***@***.***>
Holding off on the draft PR — the data model is genuinely blocked, not just the API command
Beamanator I dug into the code to start implementing, and the blocker is deeper than "the write command doesn't exist yet." The persistence shape the whole feature hangs on is undecided, so anything I build now would be a throwaway that fails QA. Here's the concrete problem:
There is nowhere to store enabled that an optimistic toggle can safely write to. Categories work because they live in a top-level POLICY_CATEGORIES Onyx collection keyed by name — setWorkspaceCategoryEnabled just MERGEs into ${POLICY_CATEGORIES}${policyID}. Vendors have no such key (grep POLICY_VENDORS src/ONYXKEYS.ts → nothing). They're read straight out of the connection blob by getActiveVendorMatchingVendors, and that surface is a positional array with three different per-integration shapes:
QBO → connections.quickbooksOnline.data.vendors (array of {id, name, currency, email})
Sage Intacct → connections.intacct.data.vendors (array using a value field)
Xero → connections.xero.data.contacts (an object, not an array)
To toggle enabled optimistically today I'd have to MERGE into one of those positional arrays inside policy.connections.<integration>.data — which (a) is overwritten by the next accounting sync, i.e. the exact "toggle must survive re-sync" bug this issue exists to prevent, and (b) needs three different code paths. That's what Expensify/Expensify#650596 ("pull vendor lists into top-level Onyx keys") is meant to fix first — and it's still open.
Status of the two things I'd need:
Persistence location for enabled → undecided (that's the crux of Expensify/Expensify#670690, which is still open with no backend plan yet), depends on #650596 landing.
Everything else in the plan (selection mode, the header dropdown, the per-row <Switch>, the picker filter, copy) is cheap and additive once those two are nailed down — but they're all cosmetic without a real place to read/write enabled.
How do you want to proceed?
Wait for the backend shape (recommended in the original plan) — once #670690 settles the Onyx key + command, I can land the whole frontend in one clean PR mirroring Categories.
Unblock me with a working assumption — if you're happy to commit to a target shape now, reply with it and I'll build the optimistic UI against it as a draft (flagged for reconciliation). The two decisions I need are:
Onyx key: e.g. a new top-level policyVendors_<policyID> collection keyed by vendor ID (per #650596), vs. keeping it inside connections.*.data.
Command contract: e.g. SetPolicyVendorsEnabled with {policyID, vendorIDs: string[], enabled: boolean}.
I'd rather not open a PR that toggles a field the backend never persists and calls a command that 500s — say the word on option 2 with the shape you want, or point me at the settled #670690 and I'll implement immediately.
Log in as an admin of a workspace connected to QuickBooks Online, Sage Intacct, Xero, Certinia, DualEntry, Rillet, or Campfire with imported vendors.
Make sure the Vendor Matching beta is active, then open Workspace Settings > Vendors.
Verify that all imported vendors load and display an Enabled switch column.
Find the default vendor (for example, the default credit card vendor in QBO or charge vendor in Intacct) and verify the switch is locked with a lock icon and cannot be turned off.
Turn off a non-default vendor and verify the switch updates immediately and stays disabled after page refresh or network sync.
Select multiple disabled vendors (on mobile, long-press a vendor row to enter selection mode) and use the bulk action menu to enable them.
Select multiple enabled vendors (including the default vendor) and apply bulk Disable. Verify all selected vendors except the default vendor are disabled.
Select both enabled and disabled vendors and verify both "Enable" and "Disable" options appear in the dropdown menu.
Open an expense on the workspace and edit its vendor. Verify disabled vendors do not appear in the list or search results.
On an expense assigned to a vendor that was later disabled, open the vendor picker. Verify the disabled vendor appears as selected with a "Disabled" subtitle in the unsearched list, does not appear in search results, and can be replaced with an enabled vendor or cleared with "None".
Activity
Beamanator commentedon Aug 11, 2026
@MelvinBot plan out the required changes for this issue. Also make an issue in Expensify/Expensify repo in order to plan out and implement the backend changes for this project, and assign me and Jenna there too.
Sees that issue with a prompt for MelvinBot to plan out the backend changes for all the features planned in this issue
MelvinBot commentedon Aug 11, 2026
Frontend plan — enable/disable toggle + bulk action for Vendors
Closest pattern to copy: the
Workspaces > Categoriespage. It already uses the exact same@components/Tablestack the Vendors page uses, plus theImportedFromAccountingSoftwarebanner and the sameButtonWithDropdownMenubulk-selection UX we want — so it's a near drop-in template.Backend planning issue created: Expensify/Expensify#670690 (assigned to⚠️ blockers below.
Beamanatorandheyjennahay), with a prompt for me to plan the backend work. The frontend can't fully land until the backend design lands — see theChanges required
1. Data model — add an
enabledfield to vendorsVendortype (src/types/onyx/Policy.ts:410-422) is{id, name, currency, email}today — noenabled. Addenabled: boolean(pluspendingFields/pendingAction/errorsfor optimistic UI, mirroring categories).policy.connections.<integration>.data, which accounting sync overwrites — so the enabled-state persistence location is a backend design decision (tracked in #670690, coordinated with the top-level-Onyx-key refactor Expensify/Expensify#650596). The frontend Onyx read shape depends on the outcome.2. Page — add selection mode + bulk dropdown (
WorkspaceVendorsPage.tsx)selectedVendorKeysstate +canSelectMultiple, mirroringWorkspaceCategoriesPage.enabledthrough thevendorRowsmap (currently only{keyForList, name}at lines 46-53).getHeaderButtons()that rendersButtonWithDropdownMenu(variantSUCCESS,customText={translate('workspace.common.selected', {count})}) when 2+ rows are selected. Push a Disable option when any selected vendor is enabled and an Enable option when any selected is disabled — so a mixed selection shows both, exactly as the issue describes.3. Table — enable per-row selection + toggle (
WorkspaceVendorsTable/index.tsx)selectionEnabled/selectedKeys/onRowSelectionChangeto the sharedTable(props already exist on it — used by categories).WorkspaceVendorTableRowDatawithenabled+onToggleEnabled, add anenabledcolumn rendering a<Switch>and anactionscaret column, and set rowsinteractive(currentlyinteractive={false}at line 51).4. New action + API command
src/libs/actions/Policy/Vendor.tswithsetWorkspaceVendorEnabledmirroringsetWorkspaceCategoryEnabled(optimisticpendingFields.enabled = UPDATE, success clears, failure restores + setserrors). One handler serves both the single toggle and the bulk action.SetPolicyVendorsEnabled) + params type.5. Filter disabled vendors out of the coding picker (
IOURequestStepVendor.tsx:74)getMatchingVendors(policy). Filter outenabled === falsehere (or via a new enabled-aware helper). Do not filter thegetMatchingVendors/findVendorByIDlookups used byMoneyRequestView,ViolationsUtils, andModifiedExpenseMessage— historical transactions must still show their (now-disabled) vendor name.6. Copy — add translation strings for the enable/disable menu items, toggle labels, and the "X selected" button in
src/languages/*.ts.Why Categories is the right template (vs. Tags/Taxes/ReportFields)
Tags/Taxes/ReportFields use the older
SelectionListWithModal; copying them would also mean swapping out the Vendors table component. Categories uses the same modern@components/Tablethat Vendors already renders, the sameImportedFromAccountingSoftwarebanner, and the same accounting-connection sourcing — so the diff is additive rather than a rewrite. The mixed-selection "show both Enable and Disable" logic already exists inWorkspaceCategoriesPage.getHeaderButtons()and the per-row<Switch>inWorkspaceCategoriesTableRow.Next Steps for Contributor+ team:
To accept:
@MelvinBot implement [this](https://github.com/Expensify/App/issues/98355#issuecomment-5258533964)to create a draft PR (best done once the backend command/persistence shape from Expensify/Expensify#670690 is settled).To refine:
@MelvinBot <your feedback>To reject: Explain why you are rejecting Melvin's plan.
Beamanator commentedon Aug 12, 2026
MelvinBot commentedon Aug 12, 2026
Holding off on the draft PR — the data model is genuinely blocked, not just the API command
BeamanatorI dug into the code to start implementing, and the blocker is deeper than "the write command doesn't exist yet." The persistence shape the whole feature hangs on is undecided, so anything I build now would be a throwaway that fails QA. Here's the concrete problem:There is nowhere to store
enabledthat an optimistic toggle can safely write to. Categories work because they live in a top-levelPOLICY_CATEGORIESOnyx collection keyed by name —setWorkspaceCategoryEnabledjustMERGEs into${POLICY_CATEGORIES}${policyID}. Vendors have no such key (grep POLICY_VENDORS src/ONYXKEYS.ts→ nothing). They're read straight out of the connection blob bygetActiveVendorMatchingVendors, and that surface is a positional array with three different per-integration shapes:connections.quickbooksOnline.data.vendors(array of{id, name, currency, email})connections.intacct.data.vendors(array using avaluefield)connections.xero.data.contacts(an object, not an array)To toggle
enabledoptimistically today I'd have toMERGEinto one of those positional arrays insidepolicy.connections.<integration>.data— which (a) is overwritten by the next accounting sync, i.e. the exact "toggle must survive re-sync" bug this issue exists to prevent, and (b) needs three different code paths. That's what Expensify/Expensify#650596 ("pull vendor lists into top-level Onyx keys") is meant to fix first — and it's still open.Status of the two things I'd need:
enabled→ undecided (that's the crux of Expensify/Expensify#670690, which is still open with no backend plan yet), depends on #650596 landing.SetPolicyVendorsEnabledcommand (name/params/response) → doesn't exist; only per-integration default-vendor commands exist today.Everything else in the plan (selection mode, the header dropdown, the per-row
<Switch>, the picker filter, copy) is cheap and additive once those two are nailed down — but they're all cosmetic without a real place to read/writeenabled.How do you want to proceed?
policyVendors_<policyID>collection keyed by vendor ID (per #650596), vs. keeping it insideconnections.*.data.SetPolicyVendorsEnabledwith{policyID, vendorIDs: string[], enabled: boolean}.I'd rather not open a PR that toggles a field the backend never persists and calls a command that 500s — say the word on option 2 with the shape you want, or point me at the settled #670690 and I'll implement immediately.
Beamanator commentedon Aug 24, 2026
Let's get back to this this week!
[-][CC Vendor matching] Add enable/disable toggle to Vendor list + bulk action[/-][+][Vendor matching CC] App: enable/disable imported vendors and bulk actions[/+]83 remaining items
melvin-bot commentedon Nov 3, 2026
Triggered auto assignment to @mallenexpensify (
Awaiting Payment)Pujan92 commentedon Nov 7, 2026
Reopening as payment is pending
melvin-bot commentedon Nov 7, 2026
Payment Summary
Resolving PRs:
[No QA] Add policy vendors Onyx collection type #100240
Add imported vendor enable and disable controls #102756
Add imported vendor enable and disable controls #103549
Reviewer: @Pujan92 owed $175 via NewDot
Contributor: @ShridharGoel does not require payment (Contractor)
BugZero Checklist (@mallenexpensify)
Pujan92 commentedon Nov 9, 2026
@mallenexpensify plz consider this for the amount in payment summary
mallenexpensify commentedon Nov 9, 2026
Payment Summary
Contributor+: @Pujan92 due $250 via NewDot
@Pujan92 plz complete the Contributor+ checklist and tag me in a post once you have. Thx
Pujan92 commentedon Nov 10, 2026
No Checklist Needed
It was a new feature.
Regression Test
Pujan92 commentedon Nov 10, 2026
@mallenexpensify done
twisterdotcom commentedon Nov 11, 2026
$250 approved for @Pujan92 in Report ID: R00TTKEKxUMX.
Zapier Logs
Run ID: 00040eee-2534-ac85-9ed7-d7e686358ac4SO: https://stackoverflowteams.com/c/expensify/questions/7582