Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
50 commits
Select commit Hold shift + click to select a range
74e58ed
[ADD][12.0] pos_meal_voucher
legalsylvain Jun 8, 2020
bc54a17
[UPD] Update pos_meal_voucher.pot
oca-travis Oct 30, 2020
cb4496d
[UPD] README.rst
OCA-git-bot Oct 30, 2020
b678be1
[ADD] icon.png
OCA-git-bot Oct 30, 2020
bc9dce2
pos_meal_voucher 12.0.1.0.2
OCA-git-bot Oct 30, 2020
0601cdd
[FIX] pos_meal_voucher: remove unoverloadable function.
legalsylvain Nov 16, 2020
1bd75a5
[IMP] pos_meal_voucher : do not display meal voucher features, if the…
legalsylvain Nov 20, 2020
fb408ad
[FIX] pos_meal_voucher: run onchange on product.product model.
legalsylvain May 12, 2021
00a89f0
pos_meal_voucher 12.0.1.0.3
OCA-git-bot May 13, 2021
66ea3a1
[UPD] Update pos_meal_voucher.pot
oca-travis May 13, 2021
3bcb752
Update translation files
oca-transbot May 13, 2021
94b14fc
[UPD] Update pos_meal_voucher.pot
oca-travis May 14, 2021
8bdf25d
pos_meal_voucher 12.0.1.0.4
OCA-git-bot May 14, 2021
6a95da6
Update translation files
oca-transbot May 14, 2021
955cb2c
[UPD] Update pos_meal_voucher.pot
oca-travis May 14, 2021
45a24b7
Update translation files
oca-transbot May 14, 2021
9efbc20
[UPD] Update pos_meal_voucher.pot
oca-travis May 17, 2021
36cd0b3
pos_meal_voucher 12.0.1.0.5
OCA-git-bot May 17, 2021
f983f9d
Update translation files
oca-transbot May 17, 2021
45ce4e0
[REF] pos_meal_voucher : make module compatible with pos_margin. homo…
legalsylvain Jun 10, 2021
13dbf6e
[UPD] Update pos_meal_voucher.pot
oca-travis Jun 15, 2021
99f8b9a
Update translation files
oca-transbot Jun 15, 2021
a2f16e7
[UPD] Update pos_meal_voucher.pot
oca-travis Jun 15, 2021
9489da4
Update translation files
oca-transbot Jun 15, 2021
9d17bd0
Added translation using Weblate (Italian)
eLBati Jun 30, 2021
60058d4
Translated using Weblate (Italian)
eLBati Jun 30, 2021
371181f
[REF] adopt several modules
legalsylvain Aug 13, 2021
f93ebae
[UPD] README.rst
OCA-git-bot Aug 13, 2021
6246eaf
pos_meal_voucher 12.0.1.0.6
OCA-git-bot Aug 13, 2021
998eca4
[IMP] pre-commit run -a
ivantodorovich Jul 12, 2022
bd82b27
pos_meal_voucher 12.0.1.0.7
OCA-git-bot Aug 5, 2022
681a957
Translated using Weblate (Italian)
mymage Mar 17, 2023
9479846
Translated using Weblate (Italian)
mymage Mar 22, 2023
9694893
[IMP] pos_meal_voucher : add information on ticket
legalsylvain Jan 5, 2023
fcd3b91
[UPD] Update pos_meal_voucher.pot
Apr 18, 2023
48de970
[UPD] README.rst
OCA-git-bot Apr 18, 2023
2e7f23f
pos_meal_voucher 12.0.1.0.8
OCA-git-bot Apr 18, 2023
e93ad03
Update translation files
weblate Apr 18, 2023
eb8aefc
Translated using Weblate (Italian)
mymage Apr 25, 2023
b50b0c6
[UPD] README.rst
OCA-git-bot Sep 3, 2023
8e663bf
Translated using Weblate (Italian)
mymage Oct 16, 2023
2552b36
Translated using Weblate (Italian)
mymage Nov 21, 2023
6f7b1e7
[IMP] pos_meal_voucher: pre-commit stuff
huguesdk Feb 11, 2025
2fe3bb7
[MIG] pos_meal_voucher: migration to 16.0
huguesdk Feb 19, 2025
b036da0
[IMP] avoid double scanning of meal vouchers
legalsylvain Feb 21, 2025
8469de0
[IMP] adjust information on receipt
huguesdk Mar 19, 2025
4c1ba40
fixup! [MIG] pos_meal_voucher: migration to 16.0
huguesdk Mar 19, 2025
bb64ae3
[BOT] post-merge updates
OCA-git-bot Apr 16, 2025
62dec1b
[IMP] pos_meal_voucher: pre-commit auto fixes
P-H-Phuc May 27, 2026
4ff394a
[MIG] pos_meal_voucher: Migration to 18.0
P-H-Phuc May 8, 2026
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
217 changes: 217 additions & 0 deletions pos_meal_voucher/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,217 @@
============================
Point Of Sale - Meal Voucher
============================

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

.. |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/18.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-18-0/pos-18-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=18.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.

|product_product_form|

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.

|product_category_form|

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.

|pos_payment_method_form|

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.

|pos_settings|

.. |product_product_form| image:: https://raw.githubusercontent.com/OCA/pos/18.0/pos_meal_voucher/static/description/product_product_form.png
.. |product_category_form| image:: https://raw.githubusercontent.com/OCA/pos/18.0/pos_meal_voucher/static/description/product_category_form.png
.. |pos_payment_method_form| image:: https://raw.githubusercontent.com/OCA/pos/18.0/pos_meal_voucher/static/description/pos_payment_method_form.png
.. |pos_settings| image:: https://raw.githubusercontent.com/OCA/pos/18.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.

|pos_order_screen|

Payment Screen
--------------

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

|pos_payment_screen_meal_vouchers|

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

|pos_payment_screen_warning|

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:

|receipt_information|

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.

.. |pos_order_screen| image:: https://raw.githubusercontent.com/OCA/pos/18.0/pos_meal_voucher/static/description/pos_order_screen.png
.. |pos_payment_screen_meal_vouchers| image:: https://raw.githubusercontent.com/OCA/pos/18.0/pos_meal_voucher/static/description/pos_payment_screen_meal_vouchers.png
.. |pos_payment_screen_warning| image:: https://raw.githubusercontent.com/OCA/pos/18.0/pos_meal_voucher/static/description/pos_payment_screen_warning.png
.. |receipt_information| image:: https://raw.githubusercontent.com/OCA/pos/18.0/pos_meal_voucher/static/description/receipt_information.png

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:%2018.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\\> <https://twitter.com/legalsylvain\>>`__
- Trobz <`https://www.trobz.com\\> <https://www.trobz.com\>>`__

- Phan Hong Phuc <phucph@trobz.com>

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/18.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
36 changes: 36 additions & 0 deletions pos_meal_voucher/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# 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": "18.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": [
"pos_meal_voucher/static/src/app/*",
"pos_meal_voucher/static/src/overrides/components/**/*",
"pos_meal_voucher/static/src/overrides/models/**/*",
"pos_meal_voucher/static/src/scss/*.scss",
],
},
"demo": [
"demo/product_category.xml",
"demo/product_product.xml",
],
}
19 changes: 19 additions & 0 deletions pos_meal_voucher/data/barcode_rule.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
<?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>
13 changes: 13 additions & 0 deletions pos_meal_voucher/demo/product_category.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?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>
15 changes: 15 additions & 0 deletions pos_meal_voucher/demo/product_product.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="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
Loading