Skip to content

Commit

Permalink
[MIG] pos_margin: Migration to 16.0
Browse files Browse the repository at this point in the history
  • Loading branch information
suker committed Mar 9, 2023
1 parent f910df0 commit 3d645c2
Show file tree
Hide file tree
Showing 33 changed files with 263 additions and 788 deletions.
44 changes: 21 additions & 23 deletions pos_margin/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,22 +14,18 @@ PoS Order Margin
: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/14.0/pos_margin
:target: https://github.com/OCA/pos/tree/16.0/pos_margin
:alt: OCA/pos
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/pos-14-0/pos-14-0-pos_margin
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
:target: https://runbot.odoo-community.org/runbot/184/14.0
:target: https://runbot.odoo-community.org/runbot/184/16.0
:alt: Try me on Runbot

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

This module extends the functionality of point of sale to support margin on
pos orders.

This gives the profitability by calculating the difference between the Unit
Price and Cost Price.
This module shows margins in PoS frontend during an order creation.

**Table of contents**

Expand All @@ -40,9 +36,9 @@ Configuration
=============

* If you want to disable the display of the margin, in the front-office UI, you can
uncheck the check box in the ``pos.config`` form:
uncheck the check box in the ``res.config.settings`` form:

.. figure:: https://raw.githubusercontent.com/OCA/pos/14.0/pos_margin/static/description/pos_config_form.png
.. figure:: https://raw.githubusercontent.com/OCA/pos/16.0/pos_margin/static/description/pos_config_form.png

Usage
=====
Expand All @@ -52,18 +48,9 @@ Usage
* Make an order. Each time a line is added, updated, or deleted, the margin and the margin rate
will be updated.

.. figure:: https://raw.githubusercontent.com/OCA/pos/14.0/pos_margin/static/description/pos_front_end.png
.. figure:: https://raw.githubusercontent.com/OCA/pos/16.0/pos_margin/static/description/pos_front_end.png
:width: 800px

**In the PoS Back Office**

To use this module, you need to:

* Go to 'Point Of Sale' / 'Orders' / 'Orders'
* Open an order

.. figure:: https://raw.githubusercontent.com/OCA/pos/14.0/pos_margin/static/description/pos_order_form.png
:width: 800px

Known issues / Roadmap
======================
Expand All @@ -74,6 +61,16 @@ for exemple).

Changelog
=========
16.0.1.0.0
~~~~~~~~~~

* Migrate to v16.0
* Remove ``pos.order`` and ``pos.order.line`` funcionality from V14.0.
It's already done by core V16.0.
* Remove tests.
* Create a ``res.config.settings`` field `pos_iface_display_margin`
to display margins in PoS frontend.


14.0.1.0.0
~~~~~~~~~~
Expand All @@ -95,7 +92,7 @@ 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 smashing it by providing a detailed and welcomed
`feedback <https://github.com/OCA/pos/issues/new?body=module:%20pos_margin%0Aversion:%2014.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
`feedback <https://github.com/OCA/pos/issues/new?body=module:%20pos_margin%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.

Expand All @@ -114,6 +111,7 @@ Contributors
* Wolfgang Pichler
* Murtaza Mithaiwala (https://twitter.com/MurtazaMithaiw4)
* Dhara Solanki <[email protected]>
* Juan Carlos <[email protected]>

Maintainers
~~~~~~~~~~~
Expand All @@ -134,8 +132,8 @@ promote its widespread use.

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

|maintainer-legalsylvain|
|maintainer-legalsylvain|

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

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
20 changes: 12 additions & 8 deletions pos_margin/__manifest__.py
Original file line number Diff line number Diff line change
@@ -1,26 +1,30 @@
# Copyright (C) 2017 - Today: GRAP (http://www.grap.coop)
# Copyright (C) 2023 - 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": "PoS Order Margin",
"summary": "Margin on PoS Order",
"version": "14.0.1.0.2",
"version": "16.0.1.0.0",
"category": "Point Of Sale",
"author": "GRAP, Odoo Community Association (OCA)",
"author": "GRAP, FactorLibre, Odoo Community Association (OCA)",
"maintainers": ["legalsylvain"],
"website": "https://github.com/OCA/pos",
"license": "AGPL-3",
"depends": [
"point_of_sale",
],
"data": [
"views/templates.xml",
"views/view_pos_config.xml",
"views/res_config_settings_view.xml",
"views/view_pos_order.xml",
],
"qweb": [
"static/src/xml/pos_margin.xml",
],
"assets": {
"point_of_sale.assets": [
"pos_margin/static/src/xml/*.xml",
"pos_margin/static/src/js/models.js",
"pos_margin/static/src/js/OrderSummaryMargin.js",
"pos_margin/static/src/css/*.css",
],
},
"installable": True,
}
85 changes: 54 additions & 31 deletions pos_margin/i18n/es.po
Original file line number Diff line number Diff line change
@@ -1,31 +1,45 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * pos_margin
# * pos_margin
#
# Translators:
# OCA Transbot <[email protected]>, 2017
# enjolras <[email protected]>, 2018
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 10.0\n"
"Project-Id-Version: Odoo Server 16.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2018-03-01 02:01+0000\n"
"PO-Revision-Date: 2018-03-01 02:01+0000\n"
"Last-Translator: enjolras <[email protected]>, 2018\n"
"Language-Team: Spanish (https://www.transifex.com/oca/teams/23907/es/)\n"
"Language: es\n"
"POT-Creation-Date: 2023-01-22 22:22+0000\n"
"PO-Revision-Date: 2023-01-22 22:22+0000\n"
"Last-Translator: \n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"Plural-Forms: \n"

#. module: pos_margin
#: model:ir.model.fields,field_description:pos_margin.field_pos_order_line_purchase_price
#: model:ir.model,name:pos_margin.model_res_config_settings
msgid "Config Settings"
msgstr "Opciones de configuración"

#. module: pos_margin
#: model:ir.model.fields,field_description:pos_margin.field_pos_order_line__purchase_price
msgid "Cost Price"
msgstr "Precio de coste"

#. module: pos_margin
#: model:ir.model.fields,help:pos_margin.field_pos_order_margin
#: model:ir.model.fields,field_description:pos_margin.field_pos_config__iface_display_margin
#: model:ir.model.fields,field_description:pos_margin.field_res_config_settings__pos_iface_display_margin
msgid "Diplay Margin"
msgstr "Mostrar margen"

#. module: pos_margin
#: model:ir.model.fields,help:pos_margin.field_pos_config__iface_display_margin
#: model:ir.model.fields,help:pos_margin.field_res_config_settings__pos_iface_display_margin
#: model_terms:ir.ui.view,arch_db:pos_margin.res_config_settings_view_form_margin_inherit
msgid "Display Margin and Margin Rate in the frontend"
msgstr "Mostrar margen y tasa de margen en el frontend"

#. module: pos_margin
#: model:ir.model.fields,help:pos_margin.field_pos_order__margin
msgid ""
"It gives profitability by calculating the difference between the Unit Price "
"and the cost price."
Expand All @@ -34,28 +48,38 @@ msgstr ""
"precio de coste."

#. module: pos_margin
#: model:ir.model,name:pos_margin.model_pos_order_line
#, fuzzy
msgid "Lines of Point of Sale Orders"
msgstr "Líneas del punto de venta"

#. module: pos_margin
#: model:ir.model.fields,field_description:pos_margin.field_pos_order_line_margin
#: model:ir.model.fields,field_description:pos_margin.field_pos_order_margin
#: model:ir.model.fields,field_description:pos_margin.field_pos_order__margin
#: model:ir.model.fields,field_description:pos_margin.field_pos_order_line__margin
msgid "Margin"
msgstr "Margen"

#. module: pos_margin
#: model:ir.model.fields,field_description:pos_margin.field_report_pos_order_margin_rate
#, fuzzy
msgid "Margin Rate"
msgstr "Margen"
#: model:ir.model.fields,field_description:pos_margin.field_report_pos_order__margin_rate
msgid "Margin Rate (%)"
msgstr "Tasa de Margen (%)"

#. module: pos_margin
#: model:ir.model.fields,field_description:pos_margin.field_report_pos_order_margin_total
#, fuzzy
#: model:ir.model.fields,field_description:pos_margin.field_report_pos_order__margin_total
#: model_terms:ir.ui.view,arch_db:pos_margin.view_pos_order_tree
msgid "Margin Total"
msgstr "Margen"
msgstr "Margen total"

#. module: pos_margin
#. odoo-javascript
#: code:addons/pos_margin/static/src/xml/pos_margin.xml:0
#, python-format
msgid "Margin:"
msgstr "Margen:"

#. module: pos_margin
#: model:ir.model,name:pos_margin.model_pos_config
msgid "Point of Sale Configuration"
msgstr "Configuración del TPV"

#. module: pos_margin
#: model:ir.model,name:pos_margin.model_pos_order_line
msgid "Point of Sale Order Lines"
msgstr "Líneas de Orden de Punto de Venta"

#. module: pos_margin
#: model:ir.model,name:pos_margin.model_pos_order
Expand All @@ -64,6 +88,5 @@ msgstr "Pedidos del TPV"

#. module: pos_margin
#: model:ir.model,name:pos_margin.model_report_pos_order
#, fuzzy
msgid "Point of Sale Orders Statistics"
msgstr "Pedidos del TPV"
msgid "Point of Sale Orders Report"
msgstr "Informe de Órdenes del Punto de Venta"
92 changes: 0 additions & 92 deletions pos_margin/i18n/fr.po

This file was deleted.

Loading

0 comments on commit 3d645c2

Please sign in to comment.