<< Back to Blog
·7 min read

Barcode Scanning for Inbound and Outbound in Flash Warehouse: A Complete Tutorial

A step-by-step guide to barcode scanning workflows in Flash Warehouse WMS, covering goods setup with barcodes, mobile app scanning for inbound and outbound, the PC POS retail checkout flow, and AI-driven barcode lookups via the MCP tool server.

Barcode Scanning for Inbound and Outbound in Flash Warehouse: A Complete Tutorial

Why Barcode Scanning Matters for Warehouse Management

Manual data entry is one of the most error-prone steps in warehouse operations. A 13-digit EAN barcode typed by hand has an average error rate of roughly 1 in 300, while barcode scanning reduces that rate to less than one in a million. Flash Warehouse WMS supports barcode scanning across all three interfaces -- PC, mobile, and the CLI/MCP tool server -- threading scan capability through every inbound, outbound, retail, and stocktake workflow.

This tutorial walks through the entire process, from setting up goods with barcodes to completing scan-driven inbound and outbound operations.

Step 1: Set Up Goods with Barcode Numbers

In Flash Warehouse, the goods ID is the barcode. There is no separate barcode column in the database. For retail products, use the EAN-13 or EAN-8 barcode printed on the product packaging as the goods ID when creating the product record.

PC path: Login > Sidebar > Warehouse Management > Inventory > click Add Goods

  1. Enter the barcode number (e.g., 6901234567890) in the Goods ID field
  2. Fill in the goods name, unit price, stock quantity, and other fields
  3. Click Save

Mobile path: Home > Warehouse Management > Inventory > tap the "+" button in the top-right corner, then fill in the barcode as the goods ID.

Key principle: Goods ID = barcode number. As long as the goods ID matches the physical barcode, all subsequent scanning operations will match automatically.

Step 2: Generate and Print Barcode Labels

After goods are created, you can generate CODE128 barcode images on both PC and mobile.

PC barcode printing:

  1. Navigate to Warehouse Management > Inventory
  2. Click the Barcode button in the actions column for any goods item
  3. A barcode preview dialog appears; click Print to send it to your printer
  4. For batch printing: select multiple goods with checkboxes, then click Batch Print Barcodes above the table. Choose between barcode and QR code formats

Mobile barcode saving:

  1. Open a goods detail view in Inventory, then select Generate Barcode
  2. The app navigates to the barcode page, which renders the goods ID as a CODE128 barcode
  3. Tap Save to Album to save the image, then print via a Bluetooth label printer

Step 3: Scan-to-Add During Inbound Bill Creation

When creating a purchase receipt or other inbound bill on mobile, you can use the camera to scan barcodes and add goods instantly.

Mobile path: Home > Purchase Management > New Purchase Receipt

  1. Fill in basic info: select warehouse and handler
  2. In the goods section, tap the Scan to Add chip (with the scan icon)
  3. The device camera activates, supporting both barCode and qrCode scan types
  4. On successful scan, the system calls /goods/query with the scanned value as goods_id
  5. If the goods exist, the name, price, and other fields auto-populate in the goods editing popup
  6. Confirm the quantity and the item is added to the bill
  7. Continue scanning additional items, or tap Submit Bill to finalize

QR code bonus: If you scan a Flash Warehouse QR code (which contains JSON with goodsId, goodsName, amount, and price fields), the system parses all fields automatically with no manual entry required.

Step 4: Scan-to-Ship Outbound on Mobile

The Inventory page includes a dedicated Scan to Ship feature for rapid outbound processing.

Mobile path: Home > Warehouse Management > Inventory > tap the Scan to Ship button

  1. In the popup panel, select the outbound warehouse first
  2. Tap the camera button to scan, or type a goods code into the input field
  3. The system calls /goods/find/goodsInfo/{userId}/{goodsId} to look up the product
  4. On success, the item is added to the outbound list with quantity 1
  5. Scanning the same barcode again increments the quantity by 1 (capped at available stock)
  6. Adjust quantities with the +/- buttons, or remove items from the list
  7. Tap Confirm Shipment to generate an "other output" bill automatically

The system generates the bill ID in the format SM + timestamp (e.g., SM20260604143025) and posts to /bill_of_document/create/other_output with the full goods list.

Step 5: POS Retail Checkout on PC

The PC interface includes a dedicated retail POS page designed for scan-gun or manual-entry checkout.

PC path: Sidebar > Retail Checkout (ShopPage)

Layout: The left panel shows the shopping cart (scanned items). The right panel displays the goods catalog for browsing. The top bar shows today's revenue and order count.

Checkout flow:

  1. Select a staff handler from the dropdown
  2. Focus the barcode input field (with the scan icon prefix)
  3. Scan a product barcode with a USB barcode scanner, or type the goods ID and press Enter
  4. The system calls GetGoodsInfoByGoodsIdAndBindingUserId to fetch the product
  5. The item appears in the cart with quantity 1
  6. Scanning the same barcode again increments the quantity automatically
  7. Edit quantities or remove items as needed
  8. Click Checkout to finalize

Settlement logic: The system groups cart items by warehouse and generates a separate "other output" bill for each warehouse. Bill IDs follow the format XD + timestamp + sequence number. The remark is auto-set to "Generated from retail scan."

Step 6: AI-Driven Barcode Operations via MCP Tools

The Flash Warehouse CLI tool fwh exposes an MCP (Model Context Protocol) server that can be called by AI editors like Claude Code and Cursor. Two MCP tools are directly relevant to barcode workflows:

goods_search_barcode -- Barcode lookup tool

Purpose: Search for a product by its retail barcode
Parameter: barcode (the full retail barcode string)
Returns: Complete goods record, or not_found error

Internally, this tool calls /goods/query with the barcode as goods_id. It differs from goods_get in intent: goods_search_barcode is a probe ("does this exist?") that returns not_found cleanly, while goods_get is a fetch-by-known-ID call.

pos_sell -- One-shot retail sale tool

Purpose: Complete a retail sale in one call (lookup + bill creation)
Parameters:
  warehouse_id: source warehouse
  transactor: cashier/staff name
  items: [{barcode: "6901234567890", quantity: 2}, ...]

The tool executes this internal flow:

  1. For each cart item, calls GoodsGet to fetch the product name and unit price
  2. Assembles the bill goods list with IDs, names, quantities, and prices
  3. Auto-generates a bill ID in the format POS-YYYYMMDD-HHMMSS
  4. Posts to /bill_of_document/create/other_output to create the outbound bill

Example in practice: In Claude Code, you can say "scan barcode 6901234567890 and ship 3 units from the main warehouse," and the AI will automatically call goods_search_barcode to confirm the product exists, then call pos_sell to complete the outbound operation.

Data Flow Summary

Regardless of which interface you use, the core data flow for barcode-driven operations is consistent:

Barcode scan / manual input
    |
    v
goods_id lookup (/goods/query or /goods/find/goodsInfo)
    |
    v
Retrieve product info (name, price, stock)
    |
    v
Assemble bill goods list
    |
    v
Create inbound/outbound bill (/bill_of_document/create/...)
    |
    v
Stock automatically adjusted

This flow ensures full traceability from scan to stock change. Every scan-driven operation generates a corresponding bill record that can be queried, audited, or rejected in the bill management module.

Flash Warehouse's barcode scanning capabilities cover every warehouse scenario. From mobile camera scanning to PC barcode-gun checkout to AI-automated batch operations, the three-interface approach significantly improves both efficiency and accuracy in inbound and outbound workflows.