Skip to content

Commit

Permalink
Merge PR #610 into 16.0
Browse files Browse the repository at this point in the history
Signed-off-by pedrobaeza
  • Loading branch information
OCA-git-bot committed Nov 19, 2024
2 parents 2d5de36 + 5bd648f commit 0558e6d
Show file tree
Hide file tree
Showing 64 changed files with 14,305 additions and 0 deletions.
1 change: 1 addition & 0 deletions setup/stock_barcodes/odoo/addons/stock_barcodes
6 changes: 6 additions & 0 deletions setup/stock_barcodes/setup.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import setuptools

setuptools.setup(
setup_requires=['setuptools-odoo'],
odoo_addon=True,
)
214 changes: 214 additions & 0 deletions stock_barcodes/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,214 @@
==============
Stock Barcodes
==============

..
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:f6453112d1afcb3f171e5f468a06e4927c98ed93493c10c8af4e4aef077de7fd
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
:target: https://odoo-community.org/page/development-status
:alt: Beta
.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fstock--logistics--barcode-lightgray.png?logo=github
:target: https://github.com/OCA/stock-logistics-barcode/tree/16.0/stock_barcodes
:alt: OCA/stock-logistics-barcode
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/stock-logistics-barcode-16-0/stock-logistics-barcode-16-0-stock_barcodes
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png
:target: https://runboat.odoo-community.org/builds?repo=OCA/stock-logistics-barcode&target_branch=16.0
:alt: Try me on Runboat

|badge1| |badge2| |badge3| |badge4| |badge5|

This module provides a barcode reader interface for stock module.

This module contains a base wizard read barcode that can be extended by
other modules.

This module also makes use of this wizard for providing barcode support for
doing inventories and picking operations.

**Table of contents**

.. contents::
:local:

Usage
=====

Barcode interface for inventory operations
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

To use the barcode interface on inventory:

#. Go to *Inventory > operations > Inventory Adjustments*.
#. Create new inventory with "Select products manually" option.
#. Start inventory.
#. Click to "Scan barcodes" smart button.
#. Start reading barcodes.

Barcode interface for picking operations
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
You can use the barcode interface in a picking or an operation type, the main
difference is that if you open the barcode interface from a picking, this
picking is locked and you read products for it.

To use the barcode interface on picking operations:

#. Go to *Inventory*.
#. Click on scanner button on any operation type.
#. Start reading barcodes.

To use the barcode interface on a picking:

#. Go to *Inventory > Transfers*.
#. Click to "Scan barcodes" smart button.
#. Start reading barcodes.

The barcode scanner interface has two operation modes. In both of them user
can scan:

#. Warehouse locations with barcode.
#. Product packaging with barcode.
#. Product with barcode.
#. Product Lots (The barcode is name field in this case).


Automatic operation mode
~~~~~~~~~~~~~~~~~~~~~~~~

This is the default mode, all screen controls are locked to avoid scan into
fields.

The user only has to scan barcode in physical warehouse locations with a
scanner hardward, the interface read the barcode and do operations in this
order:

#. Try search a product, if found, is assigned to product_id field and creates
or update inventory line with 1.0 unit. (If product has tracking by lots
the interface wait for a lot to be scanned).
#. Try search a product packaging, if found, the product_id related is set,
product quantities are updated and create or update inventory line with
product quantities defined in the product packaging.
#. Try search a lot (The product is mandatory in this case so you first scan a
product and then scann a lot), this lot field is not erased until that
product change, so for each product scann the interface add or update a
inventory line with this lot.
#. Try to search a location, if found the field location is set and next scan
action will be done with this warehouse location.

If barcode has not found, when message is displayed you can create this lot
scanning the product.

Manual entry mode
~~~~~~~~~~~~~~~~~

You can change to "manual entry" to allow to select data without scanner
hardware, but hardward scanner still active on, so a use case would be when
user wants set quantities manually instead increment 1.0 unit peer scan action.

Scan logs
~~~~~~~~~

All scanned barcodes are saved into model.
Barcode scanning interface display 10 last records linked to model, the goal of
this log is show to user other reads with the same product and location done
by other users.
User can remove the last read scan.

Known issues / Roadmap
======================

* Excute action_done() method outside onchange environment.
* Allow create product when a barcode has not been found.
* Allow to select picking reading its barcode.
* Allow to select multiple pickings to process scanned products.

Changelog
=========

11.0.1.1.0 (2019-09-24)
~~~~~~~~~~~~~~~~~~~~~~~

* [ADD] New feature.
User can uses barcode interface in picking operations.

13.0.1.1.1 (2021-02-06)
~~~~~~~~~~~~~~~~~~~~~~~

* [ADD] New feature.
Add option to get lots automatically based on removal strategy in inventory.

14.0.1.0.0 (2021-04-05)
~~~~~~~~~~~~~~~~~~~~~~~

* [ADD] New feature.
Add security for users.

Bug Tracker
===========

Bugs are tracked on `GitHub Issues <https://github.com/OCA/stock-logistics-barcode/issues>`_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us to smash it by providing a detailed and welcomed
`feedback <https://github.com/OCA/stock-logistics-barcode/issues/new?body=module:%20stock_barcodes%0Aversion:%2016.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.

Do not contact contributors directly about support or help with technical issues.

Credits
=======

Authors
~~~~~~~

* Tecnativa

Contributors
~~~~~~~~~~~~


* `Tecnativa <https://www.tecnativa.com>`_:

* Sergio Teruel
* Carlos Dauden
* Pedro M. Baeza
* Alexandre D. Díaz

* `Onestein <https://www.onestein.eu>`_:

* Andrea Stirpe

* `InitOS <https://www.initos.com>`_:

* Foram Shah

* `ForgeFlow <https://www.forgeflow.com>`_:

* Lois Rilo

* Enric Tobella

Maintainers
~~~~~~~~~~~

This module is maintained by the OCA.

.. image:: https://odoo-community.org/logo.png
:alt: Odoo Community Association
:target: https://odoo-community.org

OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.

This module is part of the `OCA/stock-logistics-barcode <https://github.com/OCA/stock-logistics-barcode/tree/16.0/stock_barcodes>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
6 changes: 6 additions & 0 deletions stock_barcodes/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Copyright 2019 Sergio Teruel <sergio.teruel@tecnativa.com>
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).

from . import models
from . import wizard
from .hooks import pre_init_hook
42 changes: 42 additions & 0 deletions stock_barcodes/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# Copyright 2019 Sergio Teruel <sergio.teruel@tecnativa.com>
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
{
"name": "Stock Barcodes",
"summary": "It provides read barcode on stock operations.",
"version": "16.0.1.0.0",
"author": "Tecnativa, " "Odoo Community Association (OCA)",
"website": "https://github.com/OCA/stock-logistics-barcode",
"license": "AGPL-3",
"category": "Extra Tools",
"depends": ["barcodes", "stock", "web_widget_numeric_step"],
"data": [
"security/ir.model.access.csv",
"views/stock_barcodes_action_view.xml",
"views/stock_barcodes_option_view.xml",
"views/stock_location_views.xml",
"views/stock_picking_views.xml",
"wizard/stock_production_lot_views.xml",
"wizard/stock_barcodes_read_views.xml",
"wizard/stock_barcodes_read_picking_views.xml",
"wizard/stock_barcodes_read_todo_view.xml",
"wizard/stock_barcodes_read_inventory_views.xml",
# Keep order
"data/stock_barcodes_action.xml",
"data/stock_barcodes_option.xml",
"views/stock_barcodes_menu.xml",
],
"assets": {
"web.assets_backend": [
"/stock_barcodes/static/src/**/*.esm.js",
(
"after",
"/web_widget_numeric_step/static/src/numeric_step.xml",
"/stock_barcodes/static/src/widgets/numeric_step.xml",
),
"/stock_barcodes/static/src/widgets/view_button.xml",
"/stock_barcodes/static/src/css/stock.scss",
],
},
"installable": True,
"pre_init_hook": "pre_init_hook",
}
42 changes: 42 additions & 0 deletions stock_barcodes/data/stock_barcodes_action.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
<?xml version="1.0" encoding="utf-8" ?>
<odoo noupdate="1">

<record id="stock_barcodes_action_picking_in" model="stock.barcodes.action">
<field name="name">Picking IN</field>
<field name="sequence">10</field>
<field name="action_window_id" ref="stock.stock_picking_type_action" />
<field name="key_char_shortcut">1</field>
<field
name="context"
>{'search_default_code': 'incoming', 'search_default_barcode_options': 1}</field>
</record>
<record id="stock_barcodes_action_picking_int" model="stock.barcodes.action">
<field name="name">Picking INTERNAL</field>
<field name="sequence">30</field>
<field name="action_window_id" ref="stock.stock_picking_type_action" />
<field name="key_char_shortcut">3</field>
<field
name="context"
>{'search_default_code': 'internal', 'search_default_barcode_options': 1}</field>
</record>
<record id="stock_barcodes_action_picking_out" model="stock.barcodes.action">
<field name="name">Picking OUT</field>
<field name="sequence">20</field>
<field name="action_window_id" ref="stock.stock_picking_type_action" />
<field name="key_char_shortcut">2</field>
<field
name="context"
>{'search_default_code': 'outgoing', 'search_default_barcode_options': 1}</field>
</record>
<!-- Action for inventory based on quants -->
<record id="stock_barcodes_action_inventory" model="stock.barcodes.action">
<field name="name">Inventory</field>
<field name="sequence">40</field>
<field
name="action_window_id"
ref="stock_barcodes.action_stock_barcodes_read_inventory"
/>
<field name="key_char_shortcut">8</field>
<field name="context">{'inventory_mode': True}</field>
</record>
</odoo>
Loading

0 comments on commit 0558e6d

Please sign in to comment.