Skip to content
Health
60/100
fair
  • Security25/25
    No findings
  • Activity25/25
    Human commit this month
  • Required by5/25
    0 modules depend on it
  • Maturity5/25
    In 1 Odoo series since 18.0

Heuristic over the facts below, not an audit · How it's computed

Security findings
Grave / minor (static analysis)
Required by
0
Modules depending on it
External deps
0 pip · 0 bin
Python packages / system binaries
License
AGPL-3
No conflicts with its dependencies
Folder size
0.17 MB
Module directory on disk
Code analysis 0 migration notes 2 models 1 view 0 HTTP endpoints

Description

Create purchase orders directly from the Barcode scanner app.

The operator picks a vendor, a destination location and a buyer, then scans or adds the products to order (with a GS1 parser installed, a GS1 label also gives its lot/serial and piece count) and confirms. The module creates a purchase.order and, when asked, confirms it — which raises the incoming picking — so a purchase can be raised on the warehouse floor without opening the back office. The server does it all in one call: a failure leaves no half-made order behind.

This is a feature module on top of barcode_scanner: it registers its own screens and home-screen tile into the scanner core without patching it, so you install only what you need.

Dependencies

Odoo dependencies
Python dependencies
None
System dependencies
None
Required by
None

Code analysis

Extracted from the source by best-effort static analysis (no code is executed); details may be incomplete.

Views touched 1

XML IDNameModelTypeStatus
purchase_order_form purchase.order.form - barcode_purchase purchase.order form Inherits purchase.purchase_order_form

HTTP endpoints 0

No HTTP endpoints found for this module.

Models touched 2

New fields (0)

No new fields.

Public methods (2)
  • action_barcode_purchase(self, partner_id, lines, confirm=False, location_dest_id=False, user_id=False, partner_ref=False)
    @api.model
    Create the purchase order the scanner drafted, and confirm it when asked -- all in one transaction, so a failure leaves no half-made order. ``lines`` are ``{product_id, qty, price_unit, lot_name}``; a missing ``price_unit`` lets Odoo price the line from the vendor's prices. Both the destination and the lots are kept on the order, so they hold however the order is confirmed: from here, or approved later in the back office. ``location_dest_id`` picks the receipt operation of its warehouse and is each line's final location, which the stock moves follow (in a reception in several steps, through the steps). The lots read are kept on their lines and written on the receipt when it is created. A lot-tracked product without a lot does not hold the order back: a vendor's lot is usually unknown until the goods turn up, and it belongs on the receipt. Those products are returned in ``missing_lots``.
  • barcode_purchase_prices(self, partner_id, lines)
    @api.model
    The unit price each line would get on an order for the vendor, so the scanner can show it before the order exists: computed as the order computes it, from the vendor's prices, in the purchase unit and in the order's currency. ``lines`` are ``{product_id, qty}``; a line whose product is gone gets None.

New fields (1)
  • barcode_lot_name Char
    copy=False help='The lot or serial number read from the label when the order was raised from the Barcode app. It goes onto the receipt when the receipt is created.' string='Lot/Serial Read'
Public methods (0)

No public methods.