forked from OCA/pos
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[IMP] pos_default_partner add continuation
- Loading branch information
Jaime Arroyo
committed
Jul 3, 2020
1 parent
5a730a3
commit 0f0508a
Showing
12 changed files
with
79 additions
and
69 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
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
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 |
---|---|---|
@@ -1,3 +1,2 @@ | ||
from . import company | ||
from . import config | ||
from . import pos_order | ||
from . import pos_config |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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
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 |
---|---|---|
@@ -1 +1,2 @@ | ||
Set default partner on POS settings | ||
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 @@ | ||
Set the default customer also on the PoS UI. |
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
This file was deleted.
Oops, something went wrong.
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,33 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<!-- Copyright 2020 Creu Blanca | ||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). --> | ||
|
||
<odoo> | ||
|
||
<record model="ir.ui.view" id="pos_config_view_form"> | ||
<field name="name">pos.config.form (in pos_default_partner)</field> | ||
<field name="model">pos.config</field> | ||
<field name="inherit_id" ref="point_of_sale.pos_config_view_form"/> | ||
<field name="arch" type="xml"> | ||
<xpath expr="//div[@id='inventory_location']" position="after"> | ||
<h2>Customers</h2> | ||
<div class="row mt16 o_settings_container" id="customers_config"> | ||
<div class="col-12 col-lg-6 o_setting_box"> | ||
<div class="o_setting_right_pane"> | ||
<label for="default_partner_id" string="Default Customer"/> | ||
<div class="text-muted"> | ||
Default customer to use if none is set | ||
</div> | ||
<div class="content-group mt16"> | ||
<field name="default_partner_id"/> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</xpath> | ||
</field> | ||
</record> | ||
|
||
|
||
|
||
</odoo> |