Skip to content

Warehouses

Backlog fieldValue
Story IDINV-DASH-009
EpicInventory
Story typeDashboard
Review statusDraft - business analyst and business owner review required
Source evidenceInventory MFE route/form, Inventory.Apis controller, application command/query handlers, validators, domain entities, and posting services
Last source review2026-07-10

Purpose

Define stock-holding locations and their operational/accounting configuration.

User stories

  • As an administrator, I want to add and edit warehouses so that stock is held in controlled locations.
  • As an inventory user, I want to view a warehouse and its item balances so that I can understand what it contains.
  • As an accountant, I want warehouse-related accounts configured so that movements post correctly.
  • As a manager, I want to export the warehouse list or warehouse items for analysis.

Acceptance criteria

  1. A warehouse has a unique business identity and the required company/branch association.
  2. Add, edit, view, delete, list, and export actions are permission-controlled.
  3. Warehouse details expose configured accounts and assigned/stocked items to authorized users.
  4. Stock checking reports the current available quantity for the selected item/warehouse context.
  5. A warehouse referenced by stock or transactions cannot be deleted in a way that breaks history.
  6. Quick add returns the new warehouse to the initiating workflow when the user has add permission.
  7. Exports reflect the current filters and localization.

Required, optional, and conditional data

  • Required: English name, Arabic name, and warehouse type on full edit.
  • Branch assignments are optional in the command but determine where the warehouse is selectable.
  • Address is optional; when email is supplied it must be valid, and when phone/country code are supplied the mobile format must be valid.
  • Warehouse accounts are optional while editing master data but the Warehouse GL account becomes mandatory before any posting that affects this warehouse.
  • Quick Add requires localized names; it may include branches and type, then returns the new ID to the calling page.

Accounts and downstream effects

  • Warehouse GL is the inventory control account debited by Stock In and credited by Stock Out.
  • Purchase, Goods in Transit, and Adjustment account fields may support other flows, but each transaction uses its explicit resolver; no undocumented fallback should be assumed.
  • Changing an account affects future journals only and must not rewrite journals already linked to posted movements.

Delete/deactivate rules

Deletion must be blocked when the warehouse is referenced by stock headers, opening balances, movements, counts, reorder rules, branch setup, or source documents. Deactivation is the safe option: the warehouse disappears from new-transaction lookups while remaining on history and reports.

Internal Documentation — Microtec