diff --git a/recurring_consignment/__manifest__.py b/recurring_consignment/__manifest__.py
index 03439fc4..8bdd5a98 100644
--- a/recurring_consignment/__manifest__.py
+++ b/recurring_consignment/__manifest__.py
@@ -37,6 +37,7 @@
"demo/product_product.xml",
"demo/product_pricelist.xml",
"demo/account_move.xml",
+ "demo/ir_property.xml",
],
"post_init_hook": "create_consignor_sequence",
"installable": True,
diff --git a/recurring_consignment/demo/ir_property.xml b/recurring_consignment/demo/ir_property.xml
new file mode 100644
index 00000000..c34ff711
--- /dev/null
+++ b/recurring_consignment/demo/ir_property.xml
@@ -0,0 +1,23 @@
+
+
+
+
+
+
+ property_account_receivable_id
+
+
+
+
+
+
+ property_account_payable_id
+
+
+
+
+
diff --git a/recurring_consignment/demo/product_pricelist.xml b/recurring_consignment/demo/product_pricelist.xml
index 8726e37e..35364fe5 100644
--- a/recurring_consignment/demo/product_pricelist.xml
+++ b/recurring_consignment/demo/product_pricelist.xml
@@ -7,11 +7,13 @@ License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
+
My Pricelist (-10%)
-
+
+
3_global
percentage
@@ -20,12 +22,14 @@ License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
+
My Pricelist (-50%)
-
+
+
3_global
percentage
diff --git a/recurring_consignment/demo/product_product.xml b/recurring_consignment/demo/product_product.xml
index e8400ee9..640c04b1 100644
--- a/recurring_consignment/demo/product_product.xml
+++ b/recurring_consignment/demo/product_product.xml
@@ -11,6 +11,7 @@ License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
Commission (20% Price Excl)
service
+
@@ -24,6 +25,7 @@ License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
My Consigned Product A (VAT 5% - Consignor 1)
+
@@ -32,6 +34,7 @@ License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
My Consigned Product B (VAT 5% - Consignor 1)
+
@@ -40,6 +43,7 @@ License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
My Consigned Product C (VAT 20% - Consignor 1)
+
@@ -48,6 +52,7 @@ License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
My Consigned Product D (VAT 20% - Consignor 1)
+
diff --git a/recurring_consignment/models/account_move.py b/recurring_consignment/models/account_move.py
index e9882108..9f4ed16c 100644
--- a/recurring_consignment/models/account_move.py
+++ b/recurring_consignment/models/account_move.py
@@ -21,7 +21,7 @@ def action_post(self):
def _recurring_consigment_mark_as_paid(self):
# The first time a commission invoice is posted, create
# a Miscellanious Operation to transfer amount from 'Receivable' account
- # to 'Receiable / Payable' account
+ # to 'Receivable / Payable' account
# and mark the invoice as paid
for move in self:
diff --git a/recurring_consignment/models/product_pricelist_item.py b/recurring_consignment/models/product_pricelist_item.py
index 4fe14ef3..75dd00f6 100644
--- a/recurring_consignment/models/product_pricelist_item.py
+++ b/recurring_consignment/models/product_pricelist_item.py
@@ -12,6 +12,7 @@ class ProductPricelistItem(models.Model):
def _prepare_consignment_exception(self, pricelist, template):
return {
"pricelist_id": pricelist.id,
+ "company_id": template.company_id.id,
"product_tmpl_id": template.id,
"applied_on": "1_product",
"base": "pricelist",
diff --git a/recurring_consignment/tests/test_pricelist.py b/recurring_consignment/tests/test_pricelist.py
index 13e1eb5f..09fa8dd5 100644
--- a/recurring_consignment/tests/test_pricelist.py
+++ b/recurring_consignment/tests/test_pricelist.py
@@ -11,6 +11,7 @@ class TestPricelist(TransactionCase):
@classmethod
def setUpClass(cls):
super().setUpClass()
+ cls.company = cls.env.ref("recurring_consignment.company")
cls.ProductProduct = cls.env["product.product"]
cls.sale_pricelist_10 = cls.env.ref("recurring_consignment.sale_pricelist_10")
@@ -58,6 +59,7 @@ def test_12_pricelist_create_product_alternative(self):
product = self.ProductProduct.create(
{
"name": "New Product",
+ "company_id": self.company.id,
"categ_id": self.product_category.id,
"list_price": 100,
"consignor_partner_id": self.consignor_1.id,
@@ -72,6 +74,7 @@ def test_13_pricelist_create_product_normal(self):
product = self.ProductProduct.create(
{
"name": "New Product",
+ "company_id": self.company.id,
"categ_id": self.product_category.id,
"list_price": 100,
"consignor_partner_id": self.consignor_1.id,