diff --git a/total_quantity_pos/__init__.py b/total_quantity_pos/__init__.py index 7055292ad..19c86297e 100644 --- a/total_quantity_pos/__init__.py +++ b/total_quantity_pos/__init__.py @@ -19,3 +19,4 @@ # If not, see . # ############################################################################### +from . import models \ No newline at end of file diff --git a/total_quantity_pos/__manifest__.py b/total_quantity_pos/__manifest__.py index c05983d42..f1da548d6 100644 --- a/total_quantity_pos/__manifest__.py +++ b/total_quantity_pos/__manifest__.py @@ -21,7 +21,7 @@ ############################################################################### { 'name': 'Total Items and Total Quantity in POS', - 'version': '17.0.1.0.0', + 'version': '17.0.1.0.1', 'category': 'Point of Sale', 'summary': "To Show the Total Quantity and Total Items Ordered in POS", 'description': "This app will shows the number of " @@ -34,6 +34,7 @@ 'website': 'https://www.cybrosys.com', 'depends': ['point_of_sale'], 'data': [ + 'views/res_config_settings_views.xml', ], 'assets': { 'point_of_sale._assets_pos': [ diff --git a/total_quantity_pos/doc/RELEASE_NOTES.md b/total_quantity_pos/doc/RELEASE_NOTES.md index e41c3f714..abaf3ae8e 100644 --- a/total_quantity_pos/doc/RELEASE_NOTES.md +++ b/total_quantity_pos/doc/RELEASE_NOTES.md @@ -4,3 +4,8 @@ #### Version 17.0.1.0.0 #### ADD Initial Commit for Total Items and Total Quantity in POS. + +#### 28.08.2024 +#### Version 17.0.1.0.1 +##### UPDT +- Bug Fix-Added the boolean field in the settings. diff --git a/total_quantity_pos/models/__init__.py b/total_quantity_pos/models/__init__.py new file mode 100644 index 000000000..ff90621c9 --- /dev/null +++ b/total_quantity_pos/models/__init__.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +############################################################################### +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2023-TODAY Cybrosys Technologies() +# Author: Prathyunnan R (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################### +from . import pos_config +from . import res_config_settings diff --git a/total_quantity_pos/models/pos_config.py b/total_quantity_pos/models/pos_config.py new file mode 100644 index 000000000..3f9401e59 --- /dev/null +++ b/total_quantity_pos/models/pos_config.py @@ -0,0 +1,39 @@ +# -*- coding: utf-8 -*- +############################################################################### +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2023-TODAY Cybrosys Technologies() +# Author: Subina (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################### +from odoo import fields, models + + +class PosConfig(models.Model): + """ Class for adding the fields in the pos config""" + _inherit = "pos.config" + + pos_total_items = fields.Boolean(string="Total Items", + help="The boolean field" + " in pos.config respective" + " to the total_items field" + " in res.config.settings") + pos_total_quantity = fields.Boolean(string="Total Quantity", + help="The boolean field" + " in pos.config respective" + " to the total_quantity field" + " in res.config.settings") + diff --git a/total_quantity_pos/models/res_config_settings.py b/total_quantity_pos/models/res_config_settings.py new file mode 100644 index 000000000..91725d3c7 --- /dev/null +++ b/total_quantity_pos/models/res_config_settings.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +############################################################################### +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2023-TODAY Cybrosys Technologies() +# Author: Subina (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################### +from odoo import fields, models + + +class ConfigSettings(models.TransientModel): + """Class for adding the fields in res.config.settings""" + _inherit = 'res.config.settings' + + total_items = fields.Boolean(string="Enable Total Items", + related="pos_config_id.pos_total_items", + readonly=False, help="Enable this option " + "will show the total" + " number of items and" + " total quantities of" + " product in the " + "PoS screen.") + total_quantity = fields.Boolean(string="Enable Total Quantity", + related="pos_config_id.pos_total_quantity", + readonly=False, help="Enable this option " + "will show the total" + " number of items and" + " total quantities of" + " product in the" + " receipt.") diff --git a/total_quantity_pos/static/description/assets/modules/6.gif b/total_quantity_pos/static/description/assets/modules/6.gif new file mode 100644 index 000000000..0b7368dc0 Binary files /dev/null and b/total_quantity_pos/static/description/assets/modules/6.gif differ diff --git a/total_quantity_pos/static/description/assets/screenshots/screenshot_5.png b/total_quantity_pos/static/description/assets/screenshots/screenshot_5.png new file mode 100644 index 000000000..b99595f20 Binary files /dev/null and b/total_quantity_pos/static/description/assets/screenshots/screenshot_5.png differ diff --git a/total_quantity_pos/static/description/assets/screenshots/screenshot_6.png b/total_quantity_pos/static/description/assets/screenshots/screenshot_6.png new file mode 100644 index 000000000..27ccbfd53 Binary files /dev/null and b/total_quantity_pos/static/description/assets/screenshots/screenshot_6.png differ diff --git a/total_quantity_pos/static/description/assets/screenshots/screenshot_7.png b/total_quantity_pos/static/description/assets/screenshots/screenshot_7.png new file mode 100644 index 000000000..0f3a70906 Binary files /dev/null and b/total_quantity_pos/static/description/assets/screenshots/screenshot_7.png differ diff --git a/total_quantity_pos/static/description/assets/screenshots/screenshot_8.png b/total_quantity_pos/static/description/assets/screenshots/screenshot_8.png new file mode 100644 index 000000000..918d0ef50 Binary files /dev/null and b/total_quantity_pos/static/description/assets/screenshots/screenshot_8.png differ diff --git a/total_quantity_pos/static/src/overrides/components/order_receipt.xml b/total_quantity_pos/static/src/overrides/components/order_receipt.xml index 39315c7a0..bf87898ff 100755 --- a/total_quantity_pos/static/src/overrides/components/order_receipt.xml +++ b/total_quantity_pos/static/src/overrides/components/order_receipt.xml @@ -4,14 +4,16 @@ t-inherit="point_of_sale.OrderReceipt" t-inherit-mode="extension"> -
Total Items: - -
- -
- Total Quantity: - -
+ +
Total Items: + +
+ +
+ Total Quantity: + +
+
diff --git a/total_quantity_pos/static/src/overrides/components/order_widget.xml b/total_quantity_pos/static/src/overrides/components/order_widget.xml index 54968feaf..d8b552529 100755 --- a/total_quantity_pos/static/src/overrides/components/order_widget.xml +++ b/total_quantity_pos/static/src/overrides/components/order_widget.xml @@ -5,25 +5,28 @@ t-inherit="point_of_sale.OrderWidget" t-inherit-mode="extension" owl="1"> + -
-
- Item Count: - - - - + +
+
+ Item Count: + + + + +
+ +
+ Total Quantity: + + + + +
- -
- Total Quantity: - - - - -
-
+ diff --git a/total_quantity_pos/static/src/xml/order_receipt.xml b/total_quantity_pos/static/src/xml/order_receipt.xml deleted file mode 100644 index ba76c6d9e..000000000 --- a/total_quantity_pos/static/src/xml/order_receipt.xml +++ /dev/null @@ -1,32 +0,0 @@ - - - - - - - -
-
- Total Items: - -
- Total Quantity: - - - - - - - -
-
-
-
-
-
-
-
diff --git a/total_quantity_pos/static/src/xml/product_screen.xml b/total_quantity_pos/static/src/xml/product_screen.xml deleted file mode 100644 index e177c3dc5..000000000 --- a/total_quantity_pos/static/src/xml/product_screen.xml +++ /dev/null @@ -1,33 +0,0 @@ - - - - - - - -
-
- Total Items: - -
- Total Quantity: - - - - - - - - -
-
-
-
-
-
-
-
diff --git a/total_quantity_pos/views/res_config_settings_views.xml b/total_quantity_pos/views/res_config_settings_views.xml new file mode 100644 index 000000000..bce5b8422 --- /dev/null +++ b/total_quantity_pos/views/res_config_settings_views.xml @@ -0,0 +1,43 @@ + + + + + res.config.settings.inherit.view + res.config.settings + + + +
+
+
+ +
+
+
+
+
+
+ + +
+
+
+ +
+
+
+
+
+
+
+
+