Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
48 commits
Select commit Hold shift + click to select a range
6ea26c0
[ADD][12.0] pos_meal_voucher
legalsylvain Jun 8, 2020
5701898
[UPD] Update pos_meal_voucher.pot
oca-travis Oct 30, 2020
7edc4dc
[UPD] README.rst
OCA-git-bot Oct 30, 2020
46e3a08
[ADD] icon.png
OCA-git-bot Oct 30, 2020
b1dce17
[ADD] setup.py
OCA-git-bot Oct 30, 2020
95efb55
pos_meal_voucher 12.0.1.0.2
OCA-git-bot Oct 30, 2020
9a8d8c8
[FIX] pos_meal_voucher: remove unoverloadable function.
legalsylvain Nov 16, 2020
3088823
[IMP] pos_meal_voucher : do not display meal voucher features, if the…
legalsylvain Nov 20, 2020
bd8bcab
[FIX] pos_meal_voucher: run onchange on product.product model.
legalsylvain May 12, 2021
516eda4
pos_meal_voucher 12.0.1.0.3
OCA-git-bot May 13, 2021
86c3bd5
[UPD] Update pos_meal_voucher.pot
oca-travis May 13, 2021
503cd9c
Update translation files
oca-transbot May 13, 2021
908f47c
[UPD] Update pos_meal_voucher.pot
oca-travis May 14, 2021
e87813b
pos_meal_voucher 12.0.1.0.4
OCA-git-bot May 14, 2021
492ab5d
Update translation files
oca-transbot May 14, 2021
dd06e94
[UPD] Update pos_meal_voucher.pot
oca-travis May 14, 2021
8718a1f
Update translation files
oca-transbot May 14, 2021
72502d2
[UPD] Update pos_meal_voucher.pot
oca-travis May 17, 2021
6685fab
pos_meal_voucher 12.0.1.0.5
OCA-git-bot May 17, 2021
7add45d
Update translation files
oca-transbot May 17, 2021
f10ef31
[REF] pos_meal_voucher : make module compatible with pos_margin. homo…
legalsylvain Jun 10, 2021
f30e31e
[UPD] Update pos_meal_voucher.pot
oca-travis Jun 15, 2021
1d26e2b
Update translation files
oca-transbot Jun 15, 2021
59032c5
[UPD] Update pos_meal_voucher.pot
oca-travis Jun 15, 2021
7a61b66
Update translation files
oca-transbot Jun 15, 2021
9d78cae
Added translation using Weblate (Italian)
eLBati Jun 30, 2021
776eba5
Translated using Weblate (Italian)
eLBati Jun 30, 2021
c69f262
[REF] adopt several modules
legalsylvain Aug 13, 2021
5095b64
[UPD] README.rst
OCA-git-bot Aug 13, 2021
7af5f76
pos_meal_voucher 12.0.1.0.6
OCA-git-bot Aug 13, 2021
2f00ba5
[IMP] pre-commit run -a
ivantodorovich Jul 12, 2022
ce22807
pos_meal_voucher 12.0.1.0.7
OCA-git-bot Aug 5, 2022
35ec519
Translated using Weblate (Italian)
mymage Mar 17, 2023
c36ac98
Translated using Weblate (Italian)
mymage Mar 22, 2023
afa1a6f
[IMP] pos_meal_voucher : add information on ticket
legalsylvain Jan 5, 2023
20da4f5
[UPD] Update pos_meal_voucher.pot
Apr 18, 2023
17e3ddc
[UPD] README.rst
OCA-git-bot Apr 18, 2023
c50a866
pos_meal_voucher 12.0.1.0.8
OCA-git-bot Apr 18, 2023
a62b18e
Update translation files
weblate Apr 18, 2023
ee810bb
Translated using Weblate (Italian)
mymage Apr 25, 2023
9a0c810
[UPD] README.rst
OCA-git-bot Sep 3, 2023
abc4ce0
Translated using Weblate (Italian)
mymage Oct 16, 2023
6e7cdfc
Translated using Weblate (Italian)
mymage Nov 21, 2023
b7499bc
[IMP] pos_meal_voucher: pre-commit stuff
huguesdk Feb 11, 2025
c0a5bb4
[MIG] pos_meal_voucher: migration to 16.0
huguesdk Feb 19, 2025
4b880b8
[IMP] avoid double scanning of meal vouchers
legalsylvain Feb 21, 2025
26deca5
[IMP] adjust information on receipt
huguesdk Mar 19, 2025
232f0b0
fixup! [MIG] pos_meal_voucher: migration to 16.0
huguesdk Mar 19, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
180 changes: 180 additions & 0 deletions pos_meal_voucher/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,180 @@
============================
Point Of Sale - Meal Voucher
============================

..
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:3881e082a79362cd653b81271727fd0bd6c817adf05ba5c87fa872bb7602dca5
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

.. |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%2Fpos-lightgray.png?logo=github
:target: https://github.com/OCA/pos/tree/16.0/pos_meal_voucher
:alt: OCA/pos
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/pos-16-0/pos-16-0-pos_meal_voucher
: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/pos&target_branch=16.0
:alt: Try me on Runboat

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

This module allows to handle meal vouchers in the point of sale.

Meal vouchers are a payment method, available in some countries (France, Belgium, Romania,…) that allows customers to buy food products in grocery stores or pay in restaurants.

**Table of contents**

.. contents::
:local:

Configuration
=============

Products
~~~~~~~~

On a product form, in the "Sales" tab, the "Can be Paid for by Meal Vouchers" checkbox controls whether the product can be paid for by meal vouchers.

.. figure:: https://raw.githubusercontent.com/OCA/pos/16.0/pos_meal_voucher/static/description/product_product_form.png

Product categories can be configured to have a default value for the "Can be Paid for by Meal Vouchers" field for its products.
The "Apply to All Products" button allows to set the value on all products of the category.

.. figure:: https://raw.githubusercontent.com/OCA/pos/16.0/pos_meal_voucher/static/description/product_category_form.png

Point of Sale Payment Methods
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Point of sale payment methods (Point of Sale > Configuration > Payment Methods) have a "Meal Voucher Type" field that defines what type of meal voucher payment method they are:

* (empty): The payment method is not a meal voucher payment method.
* **Paper**: The payment method will be used when scanning meal voucher barcodes.
* **Electronic**: The payment method will be used for electronic meal vouchers.

.. figure:: https://raw.githubusercontent.com/OCA/pos/16.0/pos_meal_voucher/static/description/pos_payment_method_form.png

Settings
~~~~~~~~

This module adds a "Meal Vouchers" section in the point of sale settings (Point of Sale > Configuration > Settings, or Settings > Point of Sale) with several options:

* **Maximum Amount**: Optional maximum amount per order that can be paid by meal vouchers. Set to 0 to disable.
* **Icon on Order Lines**: Whether to display an icon on point of sale order lines (on the product screen) for products that can be paid for by meal vouchers.
* **Information on Receipt**: Whether to display an asterisk (*) on receipts before each product that can be paid for by meal vouchers as well as the total eligible amount.

.. figure:: https://raw.githubusercontent.com/OCA/pos/16.0/pos_meal_voucher/static/description/pos_settings.png

Usage
=====

Product Screen
~~~~~~~~~~~~~~

On the product screen, the products that can be paid for by meal vouchers are (optionally) identified with an icon and the total amount of those products is displayed.

.. figure:: https://raw.githubusercontent.com/OCA/pos/16.0/pos_meal_voucher/static/description/pos_order_screen.png

Payment Screen
~~~~~~~~~~~~~~

On the payment screen, a meal voucher summary is displayed:

.. figure:: https://raw.githubusercontent.com/OCA/pos/16.0/pos_meal_voucher/static/description/pos_payment_screen_meal_vouchers.png

If the received amount is too high, a warning icon is displayed:

.. figure:: https://raw.githubusercontent.com/OCA/pos/16.0/pos_meal_voucher/static/description/pos_payment_screen_warning.png

Receipt
~~~~~~~

The receipts can optionally contain information about the products that can be paid for by meal vouchers and the total amount of those products:

.. figure:: https://raw.githubusercontent.com/OCA/pos/16.0/pos_meal_voucher/static/description/receipt_information.png

Barcodes
~~~~~~~~

A new barcode rule is defined for paper meal vouchers (with 24 characters):

``...........{NNNDD}........``

If you scan the following barcode: ``052566641320080017000000``, a new payment line with an amount of ¤8.00 (``00800``) will be added.

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

Possible Features
~~~~~~~~~~~~~~~~~

* Introduce the Meal Voucher Issuer model.
* Deduce the issuer when scanning a meal voucher barcode.
* Add a report to easily compute the total deposit of meal vouchers (per issuer).
* Prevent to scan the same meal voucher barcode twice.

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

Bugs are tracked on `GitHub Issues <https://github.com/OCA/pos/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/pos/issues/new?body=module:%20pos_meal_voucher%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
~~~~~~~

* GRAP

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

* Sylvain LE GAL <https://twitter.com/legalsylvain>

Other credits
~~~~~~~~~~~~~

The development of this module has been financially supported by:

* Vracoop (https://portail.vracoop.fr/)
* Demain Supermarché (http://www.demainsupermarche.org/)
* Le Drive tout nu (https://ledrivetoutnu.com/)

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.

.. |maintainer-legalsylvain| image:: https://github.com/legalsylvain.png?size=40px
:target: https://github.com/legalsylvain
:alt: legalsylvain

Current `maintainer <https://odoo-community.org/page/maintainer-role>`__:

|maintainer-legalsylvain|

This module is part of the `OCA/pos <https://github.com/OCA/pos/tree/16.0/pos_meal_voucher>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
1 change: 1 addition & 0 deletions pos_meal_voucher/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import models
35 changes: 35 additions & 0 deletions pos_meal_voucher/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# Copyright (C) 2020 - Today: GRAP (http://www.grap.coop)
# @author: Sylvain LE GAL (https://twitter.com/legalsylvain)
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
{
"name": "Point Of Sale - Meal Voucher",
"summary": "Handle meal vouchers in Point of Sale"
" with eligible amount and max amount",
"version": "16.0.1.0.0",
"category": "Point of Sale",
"author": "GRAP, Odoo Community Association (OCA)",
"maintainers": ["legalsylvain"],
"website": "https://github.com/OCA/pos",
"license": "AGPL-3",
"depends": [
"point_of_sale",
],
"data": [
"data/barcode_rule.xml",
"views/pos_payment_method_view.xml",
"views/res_config_settings_view.xml",
"views/view_product_category.xml",
"views/view_product_template.xml",
],
"assets": {
"point_of_sale.assets": [
"pos_meal_voucher/static/src/scss/*.scss",
"pos_meal_voucher/static/src/js/**/*.js",
"pos_meal_voucher/static/src/xml/**/*.xml",
],
},
"demo": [
"demo/product_category.xml",
"demo/product_product.xml",
],
}
21 changes: 21 additions & 0 deletions pos_meal_voucher/data/barcode_rule.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!--
Copyright (C) 2020 - Today: GRAP (http://www.grap.coop)
@author: Sylvain LE GAL (https://twitter.com/legalsylvain)
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
-->
<odoo>

<record id="rule_meal_voucher" model="barcode.rule">
<field name="name">Meal Voucher Payment</field>
<field
name="barcode_nomenclature_id"
ref="barcodes.default_barcode_nomenclature"
/>
<field name="type">meal_voucher_payment</field>
<field name="encoding">any</field>
<field name="sequence">1</field>
<field name="pattern">...........{NNNDD}........</field>
</record>

</odoo>
15 changes: 15 additions & 0 deletions pos_meal_voucher/demo/product_category.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!--
Copyright (C) 2020 - Today: GRAP (http://www.grap.coop)
@author: Sylvain LE GAL (https://twitter.com/legalsylvain)
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
-->
<odoo>

<record id="food_category" model="product.category">
<field name="name">Food</field>
<field name="parent_id" ref="point_of_sale.product_category_pos" />
<field name="meal_voucher_ok" eval="True" />
</record>

</odoo>
17 changes: 17 additions & 0 deletions pos_meal_voucher/demo/product_product.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!--
Copyright (C) 2020 - Today: GRAP (http://www.grap.coop)
@author: Sylvain LE GAL (https://twitter.com/legalsylvain)
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
-->
<odoo>

<record id="bread" model="product.product">
<field name="name">Organic Wholemeal Bread</field>
<field name="categ_id" ref="food_category" />
<field name="meal_voucher_ok" eval="True" />
<field name="available_in_pos" eval="True" />
<field name="list_price">5.30</field>
</record>

</odoo>
Loading