diff --git a/pos_custom_percentage_tip_fixed/README.rst b/pos_custom_percentage_tip_fixed/README.rst new file mode 100644 index 000000000..c665f02f4 --- /dev/null +++ b/pos_custom_percentage_tip_fixed/README.rst @@ -0,0 +1,52 @@ +.. image:: https://img.shields.io/badge/licence-LGPL--3-blue.svg + :target: http://www.gnu.org/licenses/lgpl-3.0-standalone.html + :alt: License: LGPL-3 + +Pos Custom Tips +================================= +Pos Custom Tips module provides a features to manage tips in +percentage.Now we can add tip as percentage in orders.Also we can see +the applied tips in receipts. + +Configuration +============= +* No additional configurations needed + +Company +------- +* `Cybrosys Techno Solutions `__ + +License +------- +General Public License, Version 3 (LGPL v3). +(https://www.odoo.com/documentation/user/16.0/legal/licenses/licenses.html) + + +Credits +------- +* Developers: Cybrosys Techno Solutions odoo@cybrosys.com + Version 16: Gayathri V @cybrosys + +Contacts +-------- +* Mail Contact : odoo@cybrosys.com +* Website : https://cybrosys.com + +Bug Tracker +----------- +Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. + +Maintainer +========== +.. image:: https://cybrosys.com/images/logo.png + :target: https://cybrosys.com + +This module is maintained by Cybrosys Technologies. + +For support and more information, please visit `Our Website `__ + +Further information +=================== +HTML Description: ``__ + + diff --git a/pos_custom_percentage_tip_fixed/__init__.py b/pos_custom_percentage_tip_fixed/__init__.py new file mode 100644 index 000000000..0ad04cf0a --- /dev/null +++ b/pos_custom_percentage_tip_fixed/__init__.py @@ -0,0 +1,23 @@ +"""pos fixed tips""" +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2023-TODAY Cybrosys Technologies() +# Author: Cybrosys Techno Solutions() +# +# You can modify it under the terms of the GNU LESSER +# GENERAL PUBLIC LICENSE (LGPL 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 LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details. +# +# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE +# (LGPL v3) along with this program. +# If not, see . +# +############################################################################# +from . import models diff --git a/pos_custom_percentage_tip_fixed/__manifest__.py b/pos_custom_percentage_tip_fixed/__manifest__.py new file mode 100644 index 000000000..dd522e797 --- /dev/null +++ b/pos_custom_percentage_tip_fixed/__manifest__.py @@ -0,0 +1,48 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2023-TODAY Cybrosys Technologies() +# Author: Cybrosys Techno Solutions() +# +# You can modify it under the terms of the GNU LESSER +# GENERAL PUBLIC LICENSE (LGPL 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 LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details. +# +# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE +# (LGPL v3) along with this program. +# If not, see . +# +############################################################################# +{ + 'name': 'Pos Custom Tips', + 'depends': ['base', 'point_of_sale', 'pos_sale', ], + 'version': '16.0.1.0.0', + 'summary': """To apply a fixed percentage of Tip""", + 'description': """To apply a fixed percentage of tip to orders. + we set a tip percentage it will be applied to the orders""", + 'author': 'Cybrosys Techno Solutions', + 'maintainer': 'Cybrosys Techno Solutions', + 'company': 'Cybrosys Techno Solutions', + 'website': 'https://www.cybrosys.com', + 'category': 'Point Of Sale', + 'data': { + 'views/res_config_settings_views.xml', + }, + 'assets': { + 'point_of_sale.assets': [ + 'pos_custom_percentage_tip_fixed/static/src/js/PaymentScreen.js', + 'pos_custom_percentage_tip_fixed/static/src/xml/PaymentScreen.xml', + ] + }, + 'images': ['static/description/banner.png'], + 'license': 'LGPL-3', + 'installable': True, + 'auto_install': False, + 'application': False, +} diff --git a/pos_custom_percentage_tip_fixed/doc/RELEASE_NOTES.md b/pos_custom_percentage_tip_fixed/doc/RELEASE_NOTES.md new file mode 100644 index 000000000..5af06913d --- /dev/null +++ b/pos_custom_percentage_tip_fixed/doc/RELEASE_NOTES.md @@ -0,0 +1,6 @@ +## Module + +#### 09.03.2023 +#### Version 16.0.1.0.0 +##### ADD +- Initial commit for Pos Custom Tips diff --git a/pos_custom_percentage_tip_fixed/models/__init__.py b/pos_custom_percentage_tip_fixed/models/__init__.py new file mode 100644 index 000000000..f6c0c2a68 --- /dev/null +++ b/pos_custom_percentage_tip_fixed/models/__init__.py @@ -0,0 +1,24 @@ +"""pos custom tips in percentage""" +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2023-TODAY Cybrosys Technologies() +# Author: Cybrosys Techno Solutions() +# +# You can modify it under the terms of the GNU LESSER +# GENERAL PUBLIC LICENSE (LGPL 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 LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details. +# +# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE +# (LGPL v3) along with this program. +# If not, see . +# +############################################################################# +from . import res_config_settings +from . import pos_session diff --git a/pos_custom_percentage_tip_fixed/models/pos_session.py b/pos_custom_percentage_tip_fixed/models/pos_session.py new file mode 100644 index 000000000..a82e642b4 --- /dev/null +++ b/pos_custom_percentage_tip_fixed/models/pos_session.py @@ -0,0 +1,50 @@ +"""loads session to model""" +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2023-TODAY Cybrosys Technologies() +# Author: Cybrosys Techno Solutions() +# +# You can modify it under the terms of the GNU LESSER +# GENERAL PUBLIC LICENSE (LGPL 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 LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details. +# +# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE +# (LGPL v3) along with this program. +# If not, see . +# +############################################################################# +from odoo import models + + +class PosSession(models.Model): + """This class is used to inherit the pos session and loads + the settings model""" + _inherit = 'pos.session' + + def _pos_ui_models_to_load(self): + """This is used to load the res.config.settings model""" + result = super()._pos_ui_models_to_load() + result += [ + 'res.config.settings', + ] + return result + + def _loader_params_res_config_settings(self): + """ This is used to load the fields""" + return { + 'search_params': { + 'fields': ['custom_tip_percentage'], + } + } + + def _get_pos_ui_res_config_settings(self, params): + """This is used to load tip to pos""" + return self.env['res.config.settings'].\ + search_read(**params['search_params']) diff --git a/pos_custom_percentage_tip_fixed/models/res_config_settings.py b/pos_custom_percentage_tip_fixed/models/res_config_settings.py new file mode 100644 index 000000000..cebcf8f2b --- /dev/null +++ b/pos_custom_percentage_tip_fixed/models/res_config_settings.py @@ -0,0 +1,50 @@ +"""pos custom tips""" +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2023-TODAY Cybrosys Technologies() +# Author: Cybrosys Techno Solutions() +# +# You can modify it under the terms of the GNU LESSER +# GENERAL PUBLIC LICENSE (LGPL 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 LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details. +# +# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE +# (LGPL v3) along with this program. +# If not, see . +# +############################################################################# +from odoo import api, fields, models + + +class ResConfigSettings(models.TransientModel): + """this class used to add fields in the settings model""" + _inherit = 'res.config.settings' + + custom_tip_percentage = fields.Float(string="Custom Percentage", + help="enter the percentage custom tips") + + @api.model + def set_values(self): + """ Set values for the fields """ + self.env['ir.config_parameter'].sudo(). \ + set_param('pos_custom_percentage_tip_fixed.custom_tip_percentage', + self.custom_tip_percentage) + return super(ResConfigSettings, self).set_values() + + def get_values(self): + """Getting the values from the transient model""" + res = super(ResConfigSettings, self).get_values() + params = self.env['ir.config_parameter'].sudo().get_param + custom_tip_percentage = params('pos_custom_percentage_tip_fixed.' + 'custom_tip_percentage') + res.update( + custom_tip_percentage=custom_tip_percentage + ) + return res diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/check.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/check.png new file mode 100644 index 000000000..c8e85f51d Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/check.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/chevron.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/chevron.png new file mode 100644 index 000000000..2089293d6 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/chevron.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/cogs.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/cogs.png new file mode 100644 index 000000000..95d0bad62 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/cogs.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/consultation.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/consultation.png new file mode 100644 index 000000000..8319d4baa Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/consultation.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/ecom-black.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/ecom-black.png new file mode 100644 index 000000000..a9385ff13 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/ecom-black.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/education-black.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/education-black.png new file mode 100644 index 000000000..3eb09b27b Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/education-black.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/hotel-black.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/hotel-black.png new file mode 100644 index 000000000..130f613be Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/hotel-black.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/license.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/license.png new file mode 100644 index 000000000..a5869797e Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/license.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/lifebuoy.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/lifebuoy.png new file mode 100644 index 000000000..658d56ccc Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/lifebuoy.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/manufacturing-black.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/manufacturing-black.png new file mode 100644 index 000000000..697eb0e9f Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/manufacturing-black.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/modules/5.gif b/pos_custom_percentage_tip_fixed/static/description/assets/icons/modules/5.gif new file mode 100644 index 000000000..8f40aab85 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/modules/5.gif differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/modules/barcode.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/modules/barcode.png new file mode 100644 index 000000000..618e3e6c4 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/modules/barcode.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/modules/fatoorah.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/modules/fatoorah.png new file mode 100644 index 000000000..991fc77ec Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/modules/fatoorah.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/modules/integration_biometric.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/modules/integration_biometric.png new file mode 100644 index 000000000..ed11bd818 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/modules/integration_biometric.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/modules/product_brand.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/modules/product_brand.png new file mode 100644 index 000000000..1d2238b80 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/modules/product_brand.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/modules/website_cart.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/modules/website_cart.png new file mode 100644 index 000000000..163485cfd Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/modules/website_cart.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/pos-black.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/pos-black.png new file mode 100644 index 000000000..97c0f90c1 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/pos-black.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/puzzle.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/puzzle.png new file mode 100644 index 000000000..65cf854e7 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/puzzle.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/restaurant-black.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/restaurant-black.png new file mode 100644 index 000000000..4a35eb939 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/restaurant-black.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/service-black.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/service-black.png new file mode 100644 index 000000000..301ab51cb Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/service-black.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/trading-black.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/trading-black.png new file mode 100644 index 000000000..9398ba2f1 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/trading-black.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/training.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/training.png new file mode 100644 index 000000000..884ca024d Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/training.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/update.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/update.png new file mode 100644 index 000000000..ecbc5a01a Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/update.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/user.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/user.png new file mode 100644 index 000000000..6ffb23d9f Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/user.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/icons/wrench.png b/pos_custom_percentage_tip_fixed/static/description/assets/icons/wrench.png new file mode 100644 index 000000000..6c04dea0f Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/icons/wrench.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/misc/categories.png b/pos_custom_percentage_tip_fixed/static/description/assets/misc/categories.png new file mode 100644 index 000000000..bedf1e0b1 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/misc/categories.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/misc/check-box.png b/pos_custom_percentage_tip_fixed/static/description/assets/misc/check-box.png new file mode 100644 index 000000000..42caf24b9 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/misc/check-box.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/misc/compass.png b/pos_custom_percentage_tip_fixed/static/description/assets/misc/compass.png new file mode 100644 index 000000000..d5fed8faa Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/misc/compass.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/misc/corporate.png b/pos_custom_percentage_tip_fixed/static/description/assets/misc/corporate.png new file mode 100644 index 000000000..2eb13edbf Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/misc/corporate.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/misc/customer-support.png b/pos_custom_percentage_tip_fixed/static/description/assets/misc/customer-support.png new file mode 100644 index 000000000..79efc72ed Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/misc/customer-support.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/misc/cybrosys-logo.png b/pos_custom_percentage_tip_fixed/static/description/assets/misc/cybrosys-logo.png new file mode 100644 index 000000000..cc3cc0ccf Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/misc/cybrosys-logo.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/misc/features.png b/pos_custom_percentage_tip_fixed/static/description/assets/misc/features.png new file mode 100644 index 000000000..b41769f77 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/misc/features.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/misc/logo.png b/pos_custom_percentage_tip_fixed/static/description/assets/misc/logo.png new file mode 100644 index 000000000..478462d3e Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/misc/logo.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/misc/pictures.png b/pos_custom_percentage_tip_fixed/static/description/assets/misc/pictures.png new file mode 100644 index 000000000..56d255fe9 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/misc/pictures.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/misc/pie-chart.png b/pos_custom_percentage_tip_fixed/static/description/assets/misc/pie-chart.png new file mode 100644 index 000000000..426e05244 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/misc/pie-chart.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/misc/right-arrow.png b/pos_custom_percentage_tip_fixed/static/description/assets/misc/right-arrow.png new file mode 100644 index 000000000..730984a06 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/misc/right-arrow.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/misc/star.png b/pos_custom_percentage_tip_fixed/static/description/assets/misc/star.png new file mode 100644 index 000000000..2eb9ab29f Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/misc/star.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/misc/support.png b/pos_custom_percentage_tip_fixed/static/description/assets/misc/support.png new file mode 100644 index 000000000..4f18b8b82 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/misc/support.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/misc/whatsapp.png b/pos_custom_percentage_tip_fixed/static/description/assets/misc/whatsapp.png new file mode 100644 index 000000000..d513a5356 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/misc/whatsapp.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/modules/5.gif b/pos_custom_percentage_tip_fixed/static/description/assets/modules/5.gif new file mode 100644 index 000000000..2a5f8e659 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/modules/5.gif differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/modules/barcode.png b/pos_custom_percentage_tip_fixed/static/description/assets/modules/barcode.png new file mode 100644 index 000000000..618e3e6c4 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/modules/barcode.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/modules/fatoorah.png b/pos_custom_percentage_tip_fixed/static/description/assets/modules/fatoorah.png new file mode 100644 index 000000000..991fc77ec Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/modules/fatoorah.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/modules/integration_biometric.png b/pos_custom_percentage_tip_fixed/static/description/assets/modules/integration_biometric.png new file mode 100644 index 000000000..ed11bd818 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/modules/integration_biometric.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/modules/product_brand.png b/pos_custom_percentage_tip_fixed/static/description/assets/modules/product_brand.png new file mode 100644 index 000000000..1d2238b80 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/modules/product_brand.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/modules/website_cart.png b/pos_custom_percentage_tip_fixed/static/description/assets/modules/website_cart.png new file mode 100644 index 000000000..163485cfd Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/modules/website_cart.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/screenshots/1.png b/pos_custom_percentage_tip_fixed/static/description/assets/screenshots/1.png new file mode 100644 index 000000000..19054c9ca Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/screenshots/1.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/screenshots/2.png b/pos_custom_percentage_tip_fixed/static/description/assets/screenshots/2.png new file mode 100644 index 000000000..f97e30307 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/screenshots/2.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/screenshots/3.png b/pos_custom_percentage_tip_fixed/static/description/assets/screenshots/3.png new file mode 100644 index 000000000..68147c454 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/screenshots/3.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/screenshots/4.png b/pos_custom_percentage_tip_fixed/static/description/assets/screenshots/4.png new file mode 100644 index 000000000..7c4b7b1a0 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/screenshots/4.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/screenshots/5.png b/pos_custom_percentage_tip_fixed/static/description/assets/screenshots/5.png new file mode 100644 index 000000000..5441fa293 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/screenshots/5.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/assets/screenshots/hero.gif b/pos_custom_percentage_tip_fixed/static/description/assets/screenshots/hero.gif new file mode 100644 index 000000000..886790da1 Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/assets/screenshots/hero.gif differ diff --git a/pos_custom_percentage_tip_fixed/static/description/banner.png b/pos_custom_percentage_tip_fixed/static/description/banner.png new file mode 100644 index 000000000..79cd230da Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/banner.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/icon.png b/pos_custom_percentage_tip_fixed/static/description/icon.png new file mode 100644 index 000000000..9854fa99b Binary files /dev/null and b/pos_custom_percentage_tip_fixed/static/description/icon.png differ diff --git a/pos_custom_percentage_tip_fixed/static/description/index.html b/pos_custom_percentage_tip_fixed/static/description/index.html new file mode 100644 index 000000000..11b628ff2 --- /dev/null +++ b/pos_custom_percentage_tip_fixed/static/description/index.html @@ -0,0 +1,629 @@ +
+ +
+ +
+
+ Community +
+
+ Enterprise +
+
+ Odoo.sh +
+
+
+ + + +

+ Pos Custom Tips

+

+ Pos Custom Tips module provides a features to manage tips in + percentage.

+ + + +
+ + +
+
+ +
+

+ Explore This + Module

+
+ + + + +
+
+ +
+

+ Overview +

+
+
+
+ Pos Custom Tips module provides a features to manage tips in + percentage.Now we can add tip as percentage in orders.Also we can see + the applied tips in receipts. +
+
+ + + +
+
+ +
+

+ Features +

+
+
+
+
+ + We can apply tips in percentage for orders. +
+
+ + + +
+
+ +
+

+ Screenshots +

+
+
+
+ +
+

+ Enable Tips.

+

+ Enable tips in the settings of pos.And add the + percentage tip.

+ +
+ +
+

+ The percentage will be shown on the payment screen

+ +
+ +
+

+ After clicking the tip button the num pad will be + appeared.

+ +
+ +
+

+ When we want to add the tip ,just click on the tip + button.The Tip will be applied to the price.

+ +
+
+

+ It will also shown on the receipt.

+ +
+
+
+ + + +
+
+ +
+

+ Related + Products +

+
+
+
+ +
+
+ + + + +
+
+ +
+

+ Our Services +

+
+ +
+
+
+
+ +
+
+ Odoo + Customization
+
+ +
+
+ +
+
+ Odoo + Implementation
+
+ +
+
+ +
+
+ Odoo + Support
+
+ + +
+
+ +
+
+ Hire + Odoo + Developer
+
+ +
+
+ +
+
+ Odoo + Integration
+
+ +
+
+ +
+
+ Odoo + Migration
+
+ + +
+
+ +
+
+ Odoo + Consultancy
+
+ +
+
+ +
+
+ Odoo + Implementation
+
+ +
+
+ +
+
+ Odoo + Licensing Consultancy
+
+
+ +
+ + + + + +
+
+ +
+

+ Our + Industries +

+
+ +
+
+
+
+ +
+ Trading +
+

+ Easily procure + and + sell your products

+
+
+ +
+
+ +
+ POS +
+

+ Easy + configuration + and convivial experience

+
+
+ +
+
+ +
+ Education +
+

+ A platform for + educational management

+
+
+ +
+
+ +
+ Manufacturing +
+

+ Plan, track and + schedule your operations

+
+
+ +
+
+ +
+ E-commerce & Website +
+

+ Mobile + friendly, + awe-inspiring product pages

+
+
+ +
+
+ +
+ Service Management +
+

+ Keep track of + services and invoice

+
+
+ +
+
+ +
+ Restaurant +
+

+ Run your bar or + restaurant methodically

+
+
+ +
+
+ +
+ Hotel Management +
+

+ An + all-inclusive + hotel management application

+
+
+
+
+ + + + +
+
+ +
+

+ Support +

+
+
+
+
+
+
+ +
+
+

Need Help?

+

Got questions or need + help? Get in touch.

+ +

+ odoo@cybrosys.com

+
+
+
+
+
+
+
+ +
+
+

WhatsApp

+

Say hi to us on + WhatsApp!

+ +

+ +91 86068 + 27707

+
+
+
+
+
+
+
+ +
+
+
+
+ \ No newline at end of file diff --git a/pos_custom_percentage_tip_fixed/static/src/js/PaymentScreen.js b/pos_custom_percentage_tip_fixed/static/src/js/PaymentScreen.js new file mode 100644 index 000000000..93d1668e2 --- /dev/null +++ b/pos_custom_percentage_tip_fixed/static/src/js/PaymentScreen.js @@ -0,0 +1,58 @@ +odoo.define('pos_custom_percentage_tip_fixed.tips', function (require) { + 'use strict'; + + const Registries = require('point_of_sale.Registries'); + var { PosGlobalState } = require('point_of_sale.models'); + const PaymentScreen = require('point_of_sale.PaymentScreen'); + const { parse } = require('web.field_utils'); + const PosTipsPercentGlobalState = (PosGlobalState) => class PosTipsPercentGlobalState extends PosGlobalState { + //@override + async _processData(loadedData) { + await super._processData(loadedData); + this.res_config = loadedData['res.config.settings'] + } + } + Registries.Model.extend(PosGlobalState, PosTipsPercentGlobalState); + + const CustomButtonPaymentScreen = (PaymentScreen) => + class extends PaymentScreen { + setup() { + super.setup(...arguments); + } + async CustomTipButton(){ + // It is used to update the tip to payment + var custom_tip_percentage = this.env.pos.res_config[this.env.pos.res_config.length-1].custom_tip_percentage + if(custom_tip_percentage){ + this.env.pos.tips = true; + this.env.pos.custom_tip = custom_tip_percentage + var cust_tip = ((this.currentOrder.get_total_with_tax() + this.currentOrder.get_rounding_applied() ) * parseInt(custom_tip_percentage) /100); + let value = cust_tip === 0 && change > 0 ? change : cust_tip; + const { confirmed, payload } = await this.showPopup('NumberPopup', { + title: cust_tip ? this.env._t('Change Tip') : this.env._t('Add Tip'), + startingValue: value, + isInputSelected: true, + }); + if (confirmed) { + this.currentOrder.set_tip(parse.float(payload.toString())); + } + } + } + get Tips() { + // calculates the tips and return to the template + var custom_tip_percentage = this.env.pos.res_config[this.env.pos.res_config.length-1].custom_tip_percentage + if(custom_tip_percentage){ + this.env.pos.tips = true; + this.env.pos.custom_tip = custom_tip_percentage + } + else{ + this.env.pos.tips = false; + } + return { + tip:custom_tip_percentage, + tip_enable:this.env.pos.tips, + }; + } + }; + Registries.Component.extend(PaymentScreen, CustomButtonPaymentScreen); + return CustomButtonPaymentScreen; +}); \ No newline at end of file diff --git a/pos_custom_percentage_tip_fixed/static/src/xml/PaymentScreen.xml b/pos_custom_percentage_tip_fixed/static/src/xml/PaymentScreen.xml new file mode 100644 index 000000000..3d61e81e5 --- /dev/null +++ b/pos_custom_percentage_tip_fixed/static/src/xml/PaymentScreen.xml @@ -0,0 +1,16 @@ + + + + + + +
+ + Tip ()% +
+
+
+
+
+ diff --git a/pos_custom_percentage_tip_fixed/views/res_config_settings_views.xml b/pos_custom_percentage_tip_fixed/views/res_config_settings_views.xml new file mode 100644 index 000000000..7df644248 --- /dev/null +++ b/pos_custom_percentage_tip_fixed/views/res_config_settings_views.xml @@ -0,0 +1,25 @@ + + + + + res.config.settings.view.form.inherit.pos.custom.tips + + res.config.settings + + + + +
+
+
+ Add % tip +
+ +
+
+
+
+
+
\ No newline at end of file