-
-
Notifications
You must be signed in to change notification settings - Fork 603
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by chienandalu
- Loading branch information
Showing
19 changed files
with
818 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
============================= | ||
Point Of Sale Default Partner | ||
============================= | ||
|
||
.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! | ||
!! 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%2Fpos-lightgray.png?logo=github | ||
:target: https://github.com/OCA/pos/tree/13.0/pos_default_partner | ||
:alt: OCA/pos | ||
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png | ||
:target: https://translation.odoo-community.org/projects/pos-13-0/pos-13-0-pos_default_partner | ||
: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/13.0 | ||
:alt: Try me on Runbot | ||
|
||
|badge1| |badge2| |badge3| |badge4| |badge5| | ||
|
||
Define a default partner for Point Of Sale order on each company. | ||
|
||
**Table of contents** | ||
|
||
.. contents:: | ||
:local: | ||
|
||
Configuration | ||
============= | ||
|
||
Go to Point of Sale's settings page and select a default customer for a | ||
specific PoS configuration. | ||
|
||
Known issues / Roadmap | ||
====================== | ||
|
||
Set the default customer also on the PoS UI. | ||
|
||
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_default_partner%0Aversion:%2013.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 | ||
~~~~~~~ | ||
|
||
* Akretion | ||
|
||
Contributors | ||
~~~~~~~~~~~~ | ||
|
||
* Akretion | ||
|
||
* David Beal <david.beal@akretion.com> | ||
* Foram Shah <foram.shah@initos.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. | ||
|
||
This module is part of the `OCA/pos <https://github.com/OCA/pos/tree/13.0/pos_default_partner>`_ project on GitHub. | ||
|
||
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
from . import models |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
# copyright 2020 Akretion David BEAL | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). | ||
|
||
{ | ||
"name": "Point Of Sale Default Partner", | ||
"summary": "Add a default customer in pos order", | ||
"license": "AGPL-3", | ||
"version": "14.0.1.0.0", | ||
"author": "Akretion," "Odoo Community Association (OCA)", | ||
"maintainer": "Akretion", | ||
"category": "Point of sale", | ||
"depends": ["point_of_sale"], | ||
"data": ["views/pos_config.xml"], | ||
"website": "https://github.com/OCA/pos", | ||
"installable": True, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# Translation of Odoo Server. | ||
# This file contains the translation of the following modules: | ||
# * pos_default_partner | ||
# | ||
msgid "" | ||
msgstr "" | ||
"Project-Id-Version: Odoo Server 12.0\n" | ||
"Report-Msgid-Bugs-To: \n" | ||
"PO-Revision-Date: 2020-07-27 11:19+0000\n" | ||
"Last-Translator: Daniel Martinez Vila <daniel.martinez@qubiq.es>\n" | ||
"Language-Team: none\n" | ||
"Language: es\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" | ||
"X-Generator: Weblate 3.10\n" | ||
|
||
#. module: pos_default_partner | ||
#: model_terms:ir.ui.view,arch_db:pos_default_partner.pos_config_view_form | ||
msgid "Customers" | ||
msgstr "Clientes" | ||
|
||
#. module: pos_default_partner | ||
#: model:ir.model.fields,field_description:pos_default_partner.field_pos_config__default_partner_id | ||
#: model_terms:ir.ui.view,arch_db:pos_default_partner.pos_config_view_form | ||
msgid "Default Customer" | ||
msgstr "Cliente predeterminado" | ||
|
||
#. module: pos_default_partner | ||
#: model_terms:ir.ui.view,arch_db:pos_default_partner.pos_config_view_form | ||
msgid "Default customer to use if none is set" | ||
msgstr "Cliente predeterminado para usar si no se establece ninguno" | ||
|
||
#. module: pos_default_partner | ||
#: model:ir.model,name:pos_default_partner.model_pos_config | ||
msgid "Point of Sale Configuration" | ||
msgstr "Configuración del punto de venta" | ||
|
||
#. module: pos_default_partner | ||
#: model:ir.model,name:pos_default_partner.model_pos_order | ||
msgid "Point of Sale Orders" | ||
msgstr "Pedidos de Punto de Venta" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
# Translation of Odoo Server. | ||
# This file contains the translation of the following modules: | ||
# * pos_default_partner | ||
# | ||
msgid "" | ||
msgstr "" | ||
"Project-Id-Version: Odoo Server 13.0\n" | ||
"Report-Msgid-Bugs-To: \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: \n" | ||
|
||
#. module: pos_default_partner | ||
#: model_terms:ir.ui.view,arch_db:pos_default_partner.pos_config_view_form | ||
msgid "Customers" | ||
msgstr "" | ||
|
||
#. module: pos_default_partner | ||
#: model:ir.model.fields,field_description:pos_default_partner.field_pos_config__default_partner_id | ||
#: model_terms:ir.ui.view,arch_db:pos_default_partner.pos_config_view_form | ||
msgid "Default Customer" | ||
msgstr "" | ||
|
||
#. module: pos_default_partner | ||
#: model_terms:ir.ui.view,arch_db:pos_default_partner.pos_config_view_form | ||
msgid "Default customer to use if none is set" | ||
msgstr "" | ||
|
||
#. module: pos_default_partner | ||
#: model:ir.model,name:pos_default_partner.model_pos_config | ||
msgid "Point of Sale Configuration" | ||
msgstr "" | ||
|
||
#. module: pos_default_partner | ||
#: model:ir.model,name:pos_default_partner.model_pos_order | ||
msgid "Point of Sale Orders" | ||
msgstr "" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
from . import pos_order | ||
from . import pos_config |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
# Copyright 2020 Creu Blanca | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). | ||
|
||
from odoo import fields, models | ||
|
||
|
||
class PosConfig(models.Model): | ||
|
||
_inherit = "pos.config" | ||
|
||
default_partner_id = fields.Many2one( | ||
comodel_name="res.partner", | ||
string="Default Customer", | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
# copyright 2020 Akretion David BEAL | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). | ||
|
||
from odoo import api, models | ||
|
||
|
||
class PosOrder(models.Model): | ||
_inherit = "pos.order" | ||
|
||
@api.model | ||
def _complete_values_from_session(self, session, values): | ||
result = super()._complete_values_from_session(session, values) | ||
if session.config_id.default_partner_id and not result.get("partner_id"): | ||
result["partner_id"] = session.config_id.default_partner_id.id | ||
return result |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
Go to Point of Sale's settings page and select a default customer for a | ||
specific PoS configuration. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
* Akretion | ||
|
||
* David Beal <david.beal@akretion.com> | ||
* Foram Shah <foram.shah@initos.com> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Define a default partner for Point Of Sale order on each company. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Set the default customer also on the PoS UI. |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.