diff --git a/setup/stock_inventory_justification/.eggs/README.txt b/setup/stock_inventory_justification/.eggs/README.txt new file mode 100644 index 000000000..5d0166882 --- /dev/null +++ b/setup/stock_inventory_justification/.eggs/README.txt @@ -0,0 +1,6 @@ +This directory contains eggs that were downloaded by setuptools to build, test, and run plug-ins. + +This directory caches those eggs to prevent repeated downloads. + +However, it is safe to delete this directory. + diff --git a/setup/stock_inventory_justification/odoo/addons/stock_inventory_justification b/setup/stock_inventory_justification/odoo/addons/stock_inventory_justification new file mode 120000 index 000000000..86563f133 --- /dev/null +++ b/setup/stock_inventory_justification/odoo/addons/stock_inventory_justification @@ -0,0 +1 @@ +../../../../stock_inventory_justification \ No newline at end of file diff --git a/setup/stock_inventory_justification/setup.py b/setup/stock_inventory_justification/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/stock_inventory_justification/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/stock_inventory_justification/README.rst b/stock_inventory_justification/README.rst new file mode 100644 index 000000000..12bd8e0a1 --- /dev/null +++ b/stock_inventory_justification/README.rst @@ -0,0 +1,80 @@ +============================= +Stock Inventory Justification +============================= + +.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + !! This file is generated by oca-gen-addon-readme !! + !! changes will be overwritten. !! + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + +.. |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--warehouse-lightgray.png?logo=github + :target: https://github.com/OCA/stock-logistics-warehouse/tree/13.0/stock_inventory_justification + :alt: OCA/stock-logistics-warehouse +.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png + :target: https://translation.odoo-community.org/projects/stock-logistics-warehouse-13-0/stock-logistics-warehouse-13-0-stock_inventory_justification + :alt: Translate me on Weblate +.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png + :target: https://runbot.odoo-community.org/runbot/153/13.0 + :alt: Try me on Runbot + +|badge1| |badge2| |badge3| |badge4| |badge5| + +This module allows to set justification on inventories + +**Table of contents** + +.. contents:: + :local: + +Usage +===== + +* Create a Stock Adjustement +* Fill in justification + +Bug Tracker +=========== + +Bugs are tracked on `GitHub Issues `_. +In case of trouble, please check there if your issue has already been reported. +If you spotted it first, help us smashing it by providing a detailed and welcomed +`feedback `_. + +Do not contact contributors directly about support or help with technical issues. + +Credits +======= + +Authors +~~~~~~~ + +* ACSONE SA/NV + +Contributors +~~~~~~~~~~~~ + +* Thomas Binsfeld +* Denis Roussel + +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-warehouse `_ project on GitHub. + +You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/stock_inventory_justification/__init__.py b/stock_inventory_justification/__init__.py new file mode 100644 index 000000000..0650744f6 --- /dev/null +++ b/stock_inventory_justification/__init__.py @@ -0,0 +1 @@ +from . import models diff --git a/stock_inventory_justification/__manifest__.py b/stock_inventory_justification/__manifest__.py new file mode 100644 index 000000000..267dba230 --- /dev/null +++ b/stock_inventory_justification/__manifest__.py @@ -0,0 +1,19 @@ +# Copyright 2020 ACSONE SA/NV +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +{ + "name": "Stock Inventory Justification", + "summary": """ + This module allows to set justification on inventories""", + "version": "13.0.1.0.0", + "license": "AGPL-3", + "author": "ACSONE SA/NV,Odoo Community Association (OCA)", + "website": "https://github.com/OCA/stock-logistics-warehouse", + "maintainers": ["rousseldenis"], + "depends": ["stock"], + "data": [ + "security/security.xml", + "views/stock_inventory.xml", + "views/stock_inventory_justification.xml", + ], +} diff --git a/stock_inventory_justification/models/__init__.py b/stock_inventory_justification/models/__init__.py new file mode 100644 index 000000000..48b6b849c --- /dev/null +++ b/stock_inventory_justification/models/__init__.py @@ -0,0 +1,2 @@ +from . import stock_inventory_justification +from . import stock_inventory diff --git a/stock_inventory_justification/models/stock_inventory.py b/stock_inventory_justification/models/stock_inventory.py new file mode 100644 index 000000000..c96c776a7 --- /dev/null +++ b/stock_inventory_justification/models/stock_inventory.py @@ -0,0 +1,12 @@ +# Copyright 2019 ACSONE SA/NV +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from odoo import fields, models + + +class StockInventory(models.Model): + _inherit = "stock.inventory" + + justification_ids = fields.Many2many( + string="Justifications", comodel_name="stock.inventory.justification", + ) diff --git a/stock_inventory_justification/models/stock_inventory_justification.py b/stock_inventory_justification/models/stock_inventory_justification.py new file mode 100644 index 000000000..70db5ac01 --- /dev/null +++ b/stock_inventory_justification/models/stock_inventory_justification.py @@ -0,0 +1,20 @@ +# Copyright 2019 ACSONE SA/NV +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from odoo import fields, models + + +class StockInventoryJustification(models.Model): + _name = "stock.inventory.justification" + _description = "Inventory justification" + + _sql_constraints = [ + ( + "unique_name", + "EXCLUDE (name WITH =) WHERE (active = True)", + "This stock inventory justification already exists.", + ), + ] + + name = fields.Char(required=True) + active = fields.Boolean(default=True) diff --git a/stock_inventory_justification/readme/CONTRIBUTORS.rst b/stock_inventory_justification/readme/CONTRIBUTORS.rst new file mode 100644 index 000000000..d02b48998 --- /dev/null +++ b/stock_inventory_justification/readme/CONTRIBUTORS.rst @@ -0,0 +1,2 @@ +* Thomas Binsfeld +* Denis Roussel diff --git a/stock_inventory_justification/readme/DESCRIPTION.rst b/stock_inventory_justification/readme/DESCRIPTION.rst new file mode 100644 index 000000000..c772633c5 --- /dev/null +++ b/stock_inventory_justification/readme/DESCRIPTION.rst @@ -0,0 +1 @@ +This module allows to set justification on inventories diff --git a/stock_inventory_justification/readme/USAGE.rst b/stock_inventory_justification/readme/USAGE.rst new file mode 100644 index 000000000..684b65824 --- /dev/null +++ b/stock_inventory_justification/readme/USAGE.rst @@ -0,0 +1,2 @@ +* Create a Stock Adjustement +* Fill in justification diff --git a/stock_inventory_justification/security/security.xml b/stock_inventory_justification/security/security.xml new file mode 100644 index 000000000..479e49310 --- /dev/null +++ b/stock_inventory_justification/security/security.xml @@ -0,0 +1,28 @@ + + + + + + stock.inventory.justification reader access + + + + + + + + + + stock.inventory.justification manager access + + + + + + + + diff --git a/stock_inventory_justification/static/description/icon.png b/stock_inventory_justification/static/description/icon.png new file mode 100644 index 000000000..3a0328b51 Binary files /dev/null and b/stock_inventory_justification/static/description/icon.png differ diff --git a/stock_inventory_justification/static/description/index.html b/stock_inventory_justification/static/description/index.html new file mode 100644 index 000000000..cb0d3b23d --- /dev/null +++ b/stock_inventory_justification/static/description/index.html @@ -0,0 +1,428 @@ + + + + + + +Stock Inventory Justification + + + +
+

Stock Inventory Justification

+ + +

Beta License: AGPL-3 OCA/stock-logistics-warehouse Translate me on Weblate Try me on Runbot

+

This module allows to set justification on inventories

+

Table of contents

+ +
+

Usage

+
    +
  • Create a Stock Adjustement
  • +
  • Fill in justification
  • +
+
+
+

Bug Tracker

+

Bugs are tracked on GitHub Issues. +In case of trouble, please check there if your issue has already been reported. +If you spotted it first, help us smashing it by providing a detailed and welcomed +feedback.

+

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

+
+
+

Credits

+
+

Authors

+
    +
  • ACSONE SA/NV
  • +
+
+
+

Contributors

+ +
+
+

Maintainers

+

This module is maintained by the OCA.

+Odoo Community Association +

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-warehouse project on GitHub.

+

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

+
+
+
+ + diff --git a/stock_inventory_justification/views/stock_inventory.xml b/stock_inventory_justification/views/stock_inventory.xml new file mode 100644 index 000000000..efde97588 --- /dev/null +++ b/stock_inventory_justification/views/stock_inventory.xml @@ -0,0 +1,31 @@ + + + + + + stock.inventory.form (in stock_inventory_justification) + stock.inventory + + + + + + + + + + stock.inventory.search (in stock_inventory_justification) + stock.inventory + + + + + + + + diff --git a/stock_inventory_justification/views/stock_inventory_justification.xml b/stock_inventory_justification/views/stock_inventory_justification.xml new file mode 100644 index 000000000..f290883db --- /dev/null +++ b/stock_inventory_justification/views/stock_inventory_justification.xml @@ -0,0 +1,65 @@ + + + + + + stock.inventory.justification.form (in stock_inventory_justification) + stock.inventory.justification + +
+
+ + + + + +
+ + + + + + stock.inventory.justification.tree (in stock_inventory_justification) + stock.inventory.justification + + + + + + + + + stock.inventory.justification.search (in stock_inventory_justification) + stock.inventory.justification + + + + + + + + + Inventory justifications + stock.inventory.justification + tree,form + [] + {} + + + + Inventory justifications + + + + +