diff --git a/pos_all_orders/README.rst b/pos_all_orders/README.rst new file mode 100644 index 000000000..8476d3d12 --- /dev/null +++ b/pos_all_orders/README.rst @@ -0,0 +1,50 @@ +.. image:: https://img.shields.io/badge/license-AGPL--3-blue.svg + :target: https://www.gnu.org/licenses/agpl-3.0-standalone.html + :alt: License: AGPL-3 + +POS Order Management +===================== +Module allows you to display all the old orders in Point of Sale. + +Configuration +============= +* No additional configuration required + +Company +------- +* `Cybrosys Techno Solutions `__ + +License +------- +GNU AFFERO GENERAL PUBLIC LICENSE, Version 3 (AGPLv3) +(https://www.gnu.org/licenses/agpl-3.0-standalone.html) + +Credits +------- +Developer: (V16) Megha K, + (V17) Akhil Ashok, + (V18) Nivedhya T, + Contact: odoo@cybrosys.com + +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_all_orders/__init__.py b/pos_all_orders/__init__.py new file mode 100644 index 000000000..d96aecdec --- /dev/null +++ b/pos_all_orders/__init__.py @@ -0,0 +1,22 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2024-TODAY Cybrosys Technologies() +# Author: Cybrosys Techno Solutions() +# +# 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 models diff --git a/pos_all_orders/__manifest__.py b/pos_all_orders/__manifest__.py new file mode 100644 index 000000000..addf8cdc6 --- /dev/null +++ b/pos_all_orders/__manifest__.py @@ -0,0 +1,51 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2024-TODAY Cybrosys Technologies() +# Author: Cybrosys Techno Solutions() +# +# 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 . +# +############################################################################# +{ + 'name': 'POS Order Management', + 'version': '18.0.1.0.0', + 'category': 'Point of Sale', + 'summary': "POS All Order's Management", + 'description': """Module allows you to display all the old orders in Point of Sale. + You will get the detailed view of Order Reference, Receipt Reference, Customer and Order Date.""", + 'author': 'Cybrosys Techno Solutions', + 'maintainer': 'Cybrosys Techno Solutions', + 'company': 'Cybrosys Techno Solutions', + 'website': 'https://www.cybrosys.com', + 'depends': ['base', 'point_of_sale'], + 'data': [ + 'views/res_config_settings_views.xml' + ], + 'assets': { + 'point_of_sale._assets_pos': [ + 'pos_all_orders/static/src/js/models.js', + 'pos_all_orders/static/src/js/all_order_button.js', + 'pos_all_orders/static/src/xml/all_order_button.xml', + 'pos_all_orders/static/src/xml/all_order_screen.xml', + 'pos_all_orders/static/src/js/all_order_screen.js', + ], + }, + 'images': ['static/description/banner.png'], + 'installable': True, + 'application': False, + 'auto_install': False, + 'license': 'AGPL-3', +} diff --git a/pos_all_orders/doc/RELEASE_NOTES.md b/pos_all_orders/doc/RELEASE_NOTES.md new file mode 100644 index 000000000..e49b60fb5 --- /dev/null +++ b/pos_all_orders/doc/RELEASE_NOTES.md @@ -0,0 +1,6 @@ +## Module + +#### 27.12.2024 +#### Version 18.0.1.0.0 +##### ADD +- Initial Commit for POS Order Management diff --git a/pos_all_orders/models/__init__.py b/pos_all_orders/models/__init__.py new file mode 100644 index 000000000..a7839df8c --- /dev/null +++ b/pos_all_orders/models/__init__.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2024-TODAY Cybrosys Technologies() +# Author: Cybrosys Techno Solutions() +# +# 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_session +from . import res_config_settings diff --git a/pos_all_orders/models/pos_session.py b/pos_all_orders/models/pos_session.py new file mode 100644 index 000000000..78463cd7d --- /dev/null +++ b/pos_all_orders/models/pos_session.py @@ -0,0 +1,95 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2024-TODAY Cybrosys Technologies() +# Author: Cybrosys Techno Solutions() +# +# 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 dateutil.relativedelta import relativedelta +from odoo import api, fields, models + + +class PosSession(models.Model): + """inherit pos.session to load data in session.""" + _inherit = 'pos.session' + + @api.model + def get_all_order_config(self): + """Retrieves the configuration parameters related to POS all orders.""" + return { + 'config': self.env['ir.config_parameter'].sudo().get_param('pos_all_orders.pos_all_order'), + 'n_days': self.env['ir.config_parameter'].sudo().get_param('pos_all_orders.n_days') + } + + @api.model + def get_all_order(self, session_id): + """Retrieves POS orders based on the provided session ID and optional number of days.""" + if session_id.get('session'): + order = self.env['pos.order'].search( + [('session_id', '=', session_id.get('session'))]) + orders = [] + if session_id.get('n_days'): + now = fields.Datetime.now() + date_to = (now + relativedelta(days=-int(session_id.get('n_days')))) + order = self.env['pos.order'].search( + [('date_order', '>=', date_to)]) + for rec in order: + orders.append( + {'id': rec.id, 'name': rec.name, 'date_order': rec.date_order, + 'pos_reference': rec.pos_reference, + 'partner_id': rec.partner_id.name, + 'session': 'current_session' + }) + return orders + + @api.model + def get_all_past_orders(self,session_id): + """Get all past orders up to the current date.""" + if session_id.get('session'): + order = self.env['pos.order'].search( + [('session_id', '=', session_id.get('session'))]) + orders = [] + current_date = fields.Datetime.now() + order = self.env['pos.order'].search([ + ('date_order', '<=', current_date), + ('state', 'not in', ['draft', 'cancel']) + ]) + for rec in order: + orders.append( + {'id': rec.id, 'name': rec.name, 'date_order': rec.date_order, + 'pos_reference': rec.pos_reference, + 'partner_id': rec.partner_id.name, + 'session': 'past_order' + }) + return orders + + @api.model + def get_default_all_orders(self,session_id): + """Retrieves all POS orders.""" + if session_id.get('session'): + order = self.env['pos.order'].search([]) + all_orders = [] + for rec in order: + all_orders.append({ + 'id': rec.id, + 'name': rec.name, + 'date_order': rec.date_order, + 'pos_reference': rec.pos_reference, + 'partner_id': rec.partner_id.name, + 'session': rec.session_id + }) + return all_orders diff --git a/pos_all_orders/models/res_config_settings.py b/pos_all_orders/models/res_config_settings.py new file mode 100644 index 000000000..d6a4e4335 --- /dev/null +++ b/pos_all_orders/models/res_config_settings.py @@ -0,0 +1,57 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2024-TODAY Cybrosys Technologies() +# Author: Cybrosys Techno Solutions() +# +# 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 api, fields, models + + +class ResConfigSettings(models.TransientModel): + """ Inherit the base settings to add field.""" + _name = 'res.config.settings' + _inherit = ['res.config.settings','pos.load.mixin'] + + pos_all_order = fields.Selection( + [('current_session', 'Load Orders from the current session'), + ('past_order', 'Load All past Orders'), + ('last_n', 'Load all orders of last n days')],help='Select Order types') + + n_days = fields.Integer(string="No.of Day's",help='Add number of days') + + @api.model + def get_values(self): + """get values from the fields""" + res = super(ResConfigSettings, self).get_values() + params = self.env['ir.config_parameter'].sudo().get_param + pos_all_order = params('pos_all_orders.pos_all_order') + n_days = params('pos_all_orders.n_days') + res.update( + pos_all_order=pos_all_order, + n_days=n_days + ) + return res + + def set_values(self): + """Set values in the fields""" + super(ResConfigSettings, self).set_values() + self.env['ir.config_parameter'].sudo().set_param( + 'pos_all_orders.pos_all_order', self.pos_all_order) + self.env['ir.config_parameter'].sudo().set_param( + 'pos_all_orders.n_days', + self.n_days) diff --git a/pos_all_orders/static/description/assets/cybro-icon.png b/pos_all_orders/static/description/assets/cybro-icon.png new file mode 100644 index 000000000..06e73e11d Binary files /dev/null and b/pos_all_orders/static/description/assets/cybro-icon.png differ diff --git a/pos_all_orders/static/description/assets/cybro-odoo.png b/pos_all_orders/static/description/assets/cybro-odoo.png new file mode 100644 index 000000000..ed02e07a4 Binary files /dev/null and b/pos_all_orders/static/description/assets/cybro-odoo.png differ diff --git a/pos_all_orders/static/description/assets/icons/arrows-repeat.svg b/pos_all_orders/static/description/assets/icons/arrows-repeat.svg new file mode 100644 index 000000000..1d7efabc5 --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/arrows-repeat.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/banner-1.png b/pos_all_orders/static/description/assets/icons/banner-1.png new file mode 100644 index 000000000..c180db172 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/banner-1.png differ diff --git a/pos_all_orders/static/description/assets/icons/banner-2.svg b/pos_all_orders/static/description/assets/icons/banner-2.svg new file mode 100644 index 000000000..e606d97d9 --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/banner-2.svg @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/banner-bg.png b/pos_all_orders/static/description/assets/icons/banner-bg.png new file mode 100644 index 000000000..a8238d3c0 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/banner-bg.png differ diff --git a/pos_all_orders/static/description/assets/icons/banner-bg.svg b/pos_all_orders/static/description/assets/icons/banner-bg.svg new file mode 100644 index 000000000..b1378103e --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/banner-bg.svg @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/banner-call.svg b/pos_all_orders/static/description/assets/icons/banner-call.svg new file mode 100644 index 000000000..96c687e81 --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/banner-call.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/pos_all_orders/static/description/assets/icons/banner-mail.svg b/pos_all_orders/static/description/assets/icons/banner-mail.svg new file mode 100644 index 000000000..cbf0d158d --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/banner-mail.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/pos_all_orders/static/description/assets/icons/banner-pattern.svg b/pos_all_orders/static/description/assets/icons/banner-pattern.svg new file mode 100644 index 000000000..9c1c7e101 --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/banner-pattern.svg @@ -0,0 +1,343 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/banner-promo.svg b/pos_all_orders/static/description/assets/icons/banner-promo.svg new file mode 100644 index 000000000..d52791b11 --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/banner-promo.svg @@ -0,0 +1,147 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/brand-pair.svg b/pos_all_orders/static/description/assets/icons/brand-pair.svg new file mode 100644 index 000000000..d8db7fc1e --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/brand-pair.svg @@ -0,0 +1,41 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/check.png b/pos_all_orders/static/description/assets/icons/check.png new file mode 100644 index 000000000..c8e85f51d Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/check.png differ diff --git a/pos_all_orders/static/description/assets/icons/chevron.png b/pos_all_orders/static/description/assets/icons/chevron.png new file mode 100644 index 000000000..2089293d6 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/chevron.png differ diff --git a/pos_all_orders/static/description/assets/icons/close-icon.svg b/pos_all_orders/static/description/assets/icons/close-icon.svg new file mode 100644 index 000000000..df8cce37a --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/close-icon.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/pos_all_orders/static/description/assets/icons/cogs.png b/pos_all_orders/static/description/assets/icons/cogs.png new file mode 100644 index 000000000..95d0bad62 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/cogs.png differ diff --git a/pos_all_orders/static/description/assets/icons/collabarate-icon.svg b/pos_all_orders/static/description/assets/icons/collabarate-icon.svg new file mode 100644 index 000000000..dd4e10518 --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/collabarate-icon.svg @@ -0,0 +1,3 @@ + + + diff --git a/pos_all_orders/static/description/assets/icons/consultation.png b/pos_all_orders/static/description/assets/icons/consultation.png new file mode 100644 index 000000000..8319d4baa Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/consultation.png differ diff --git a/pos_all_orders/static/description/assets/icons/cybro-logo.png b/pos_all_orders/static/description/assets/icons/cybro-logo.png new file mode 100644 index 000000000..ff4b78220 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/cybro-logo.png differ diff --git a/pos_all_orders/static/description/assets/icons/down.svg b/pos_all_orders/static/description/assets/icons/down.svg new file mode 100644 index 000000000..f21c36271 --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/down.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/pos_all_orders/static/description/assets/icons/ecom-black.png b/pos_all_orders/static/description/assets/icons/ecom-black.png new file mode 100644 index 000000000..a9385ff13 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/ecom-black.png differ diff --git a/pos_all_orders/static/description/assets/icons/education-black.png b/pos_all_orders/static/description/assets/icons/education-black.png new file mode 100644 index 000000000..3eb09b27b Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/education-black.png differ diff --git a/pos_all_orders/static/description/assets/icons/faq.png b/pos_all_orders/static/description/assets/icons/faq.png new file mode 100644 index 000000000..4250b5b81 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/faq.png differ diff --git a/pos_all_orders/static/description/assets/icons/feature-icon.svg b/pos_all_orders/static/description/assets/icons/feature-icon.svg new file mode 100644 index 000000000..fa0ea6850 --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/feature-icon.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/feature.png b/pos_all_orders/static/description/assets/icons/feature.png new file mode 100644 index 000000000..ac7a785c0 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/feature.png differ diff --git a/pos_all_orders/static/description/assets/icons/gear.svg b/pos_all_orders/static/description/assets/icons/gear.svg new file mode 100644 index 000000000..0cc66b6ea --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/gear.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/hero.gif b/pos_all_orders/static/description/assets/icons/hero.gif new file mode 100644 index 000000000..ef92a32f4 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/hero.gif differ diff --git a/pos_all_orders/static/description/assets/icons/hire-odoo.svg b/pos_all_orders/static/description/assets/icons/hire-odoo.svg new file mode 100644 index 000000000..e1ac089b0 --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/hire-odoo.svg @@ -0,0 +1,12 @@ + + + + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/hotel-black.png b/pos_all_orders/static/description/assets/icons/hotel-black.png new file mode 100644 index 000000000..130f613be Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/hotel-black.png differ diff --git a/pos_all_orders/static/description/assets/icons/license.png b/pos_all_orders/static/description/assets/icons/license.png new file mode 100644 index 000000000..a5869797e Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/license.png differ diff --git a/pos_all_orders/static/description/assets/icons/life-ring-icon.svg b/pos_all_orders/static/description/assets/icons/life-ring-icon.svg new file mode 100644 index 000000000..3ae6e1d89 --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/life-ring-icon.svg @@ -0,0 +1,13 @@ + + + + + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/lifebuoy.png b/pos_all_orders/static/description/assets/icons/lifebuoy.png new file mode 100644 index 000000000..658d56ccc Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/lifebuoy.png differ diff --git a/pos_all_orders/static/description/assets/icons/mail.svg b/pos_all_orders/static/description/assets/icons/mail.svg new file mode 100644 index 000000000..1eedde695 --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/mail.svg @@ -0,0 +1,3 @@ + + + diff --git a/pos_all_orders/static/description/assets/icons/manufacturing-black.png b/pos_all_orders/static/description/assets/icons/manufacturing-black.png new file mode 100644 index 000000000..697eb0e9f Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/manufacturing-black.png differ diff --git a/pos_all_orders/static/description/assets/icons/notes.png b/pos_all_orders/static/description/assets/icons/notes.png new file mode 100644 index 000000000..ee5e95404 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/notes.png differ diff --git a/pos_all_orders/static/description/assets/icons/notification icon.svg b/pos_all_orders/static/description/assets/icons/notification icon.svg new file mode 100644 index 000000000..053189973 --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/notification icon.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/odoo-consultancy.svg b/pos_all_orders/static/description/assets/icons/odoo-consultancy.svg new file mode 100644 index 000000000..e05f65bde --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/odoo-consultancy.svg @@ -0,0 +1,4 @@ + + + + diff --git a/pos_all_orders/static/description/assets/icons/odoo-licencing.svg b/pos_all_orders/static/description/assets/icons/odoo-licencing.svg new file mode 100644 index 000000000..2606c88b0 --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/odoo-licencing.svg @@ -0,0 +1,3 @@ + + + diff --git a/pos_all_orders/static/description/assets/icons/odoo-logo.png b/pos_all_orders/static/description/assets/icons/odoo-logo.png new file mode 100644 index 000000000..0e4d0eb5a Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/odoo-logo.png differ diff --git a/pos_all_orders/static/description/assets/icons/patter.svg b/pos_all_orders/static/description/assets/icons/patter.svg new file mode 100644 index 000000000..25c9c0a8f --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/patter.svg @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/pattern1.png b/pos_all_orders/static/description/assets/icons/pattern1.png new file mode 100644 index 000000000..09ab0fb2d Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/pattern1.png differ diff --git a/pos_all_orders/static/description/assets/icons/pos-black.png b/pos_all_orders/static/description/assets/icons/pos-black.png new file mode 100644 index 000000000..97c0f90c1 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/pos-black.png differ diff --git a/pos_all_orders/static/description/assets/icons/puzzle-piece-icon.svg b/pos_all_orders/static/description/assets/icons/puzzle-piece-icon.svg new file mode 100644 index 000000000..3e9ad9373 --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/puzzle-piece-icon.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/puzzle.png b/pos_all_orders/static/description/assets/icons/puzzle.png new file mode 100644 index 000000000..65cf854e7 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/puzzle.png differ diff --git a/pos_all_orders/static/description/assets/icons/replace-icon.svg b/pos_all_orders/static/description/assets/icons/replace-icon.svg new file mode 100644 index 000000000..d0e3a7af1 --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/replace-icon.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/restaurant-black.png b/pos_all_orders/static/description/assets/icons/restaurant-black.png new file mode 100644 index 000000000..4a35eb939 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/restaurant-black.png differ diff --git a/pos_all_orders/static/description/assets/icons/screenshot-main.png b/pos_all_orders/static/description/assets/icons/screenshot-main.png new file mode 100644 index 000000000..575f8e676 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/screenshot-main.png differ diff --git a/pos_all_orders/static/description/assets/icons/screenshot.png b/pos_all_orders/static/description/assets/icons/screenshot.png new file mode 100644 index 000000000..cef272529 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/screenshot.png differ diff --git a/pos_all_orders/static/description/assets/icons/service-black.png b/pos_all_orders/static/description/assets/icons/service-black.png new file mode 100644 index 000000000..301ab51cb Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/service-black.png differ diff --git a/pos_all_orders/static/description/assets/icons/skype-fill.svg b/pos_all_orders/static/description/assets/icons/skype-fill.svg new file mode 100644 index 000000000..c17423639 --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/skype-fill.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/skype.png b/pos_all_orders/static/description/assets/icons/skype.png new file mode 100644 index 000000000..51b409fb3 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/skype.png differ diff --git a/pos_all_orders/static/description/assets/icons/skype.svg b/pos_all_orders/static/description/assets/icons/skype.svg new file mode 100644 index 000000000..df3dad39b --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/skype.svg @@ -0,0 +1,3 @@ + + + diff --git a/pos_all_orders/static/description/assets/icons/star-1.svg b/pos_all_orders/static/description/assets/icons/star-1.svg new file mode 100644 index 000000000..7e55ab162 --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/star-1.svg @@ -0,0 +1,53 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/star-2.svg b/pos_all_orders/static/description/assets/icons/star-2.svg new file mode 100644 index 000000000..5ae9f507a --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/star-2.svg @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/support.png b/pos_all_orders/static/description/assets/icons/support.png new file mode 100644 index 000000000..4f18b8b82 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/support.png differ diff --git a/pos_all_orders/static/description/assets/icons/test-1 - Copy.png b/pos_all_orders/static/description/assets/icons/test-1 - Copy.png new file mode 100644 index 000000000..f6a902663 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/test-1 - Copy.png differ diff --git a/pos_all_orders/static/description/assets/icons/test-1.png b/pos_all_orders/static/description/assets/icons/test-1.png new file mode 100644 index 000000000..0908add2b Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/test-1.png differ diff --git a/pos_all_orders/static/description/assets/icons/test-2.png b/pos_all_orders/static/description/assets/icons/test-2.png new file mode 100644 index 000000000..4671fe91e Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/test-2.png differ diff --git a/pos_all_orders/static/description/assets/icons/trading-black.png b/pos_all_orders/static/description/assets/icons/trading-black.png new file mode 100644 index 000000000..9398ba2f1 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/trading-black.png differ diff --git a/pos_all_orders/static/description/assets/icons/training.png b/pos_all_orders/static/description/assets/icons/training.png new file mode 100644 index 000000000..884ca024d Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/training.png differ diff --git a/pos_all_orders/static/description/assets/icons/translate.svg b/pos_all_orders/static/description/assets/icons/translate.svg new file mode 100644 index 000000000..af9c8a1aa --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/translate.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/update.png b/pos_all_orders/static/description/assets/icons/update.png new file mode 100644 index 000000000..ecbc5a01a Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/update.png differ diff --git a/pos_all_orders/static/description/assets/icons/user.png b/pos_all_orders/static/description/assets/icons/user.png new file mode 100644 index 000000000..6ffb23d9f Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/user.png differ diff --git a/pos_all_orders/static/description/assets/icons/video.png b/pos_all_orders/static/description/assets/icons/video.png new file mode 100644 index 000000000..576705b17 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/video.png differ diff --git a/pos_all_orders/static/description/assets/icons/whatsapp.png b/pos_all_orders/static/description/assets/icons/whatsapp.png new file mode 100644 index 000000000..d513a5356 Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/whatsapp.png differ diff --git a/pos_all_orders/static/description/assets/icons/wrench-icon.svg b/pos_all_orders/static/description/assets/icons/wrench-icon.svg new file mode 100644 index 000000000..174b5a465 --- /dev/null +++ b/pos_all_orders/static/description/assets/icons/wrench-icon.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/pos_all_orders/static/description/assets/icons/wrench.png b/pos_all_orders/static/description/assets/icons/wrench.png new file mode 100644 index 000000000..6c04dea0f Binary files /dev/null and b/pos_all_orders/static/description/assets/icons/wrench.png differ diff --git a/pos_all_orders/static/description/assets/modules/b1.png b/pos_all_orders/static/description/assets/modules/b1.png new file mode 100644 index 000000000..73845cfbf Binary files /dev/null and b/pos_all_orders/static/description/assets/modules/b1.png differ diff --git a/pos_all_orders/static/description/assets/modules/b2.png b/pos_all_orders/static/description/assets/modules/b2.png new file mode 100644 index 000000000..0cd7e58c2 Binary files /dev/null and b/pos_all_orders/static/description/assets/modules/b2.png differ diff --git a/pos_all_orders/static/description/assets/modules/b3.png b/pos_all_orders/static/description/assets/modules/b3.png new file mode 100644 index 000000000..12d8c74fb Binary files /dev/null and b/pos_all_orders/static/description/assets/modules/b3.png differ diff --git a/pos_all_orders/static/description/assets/modules/b4.png b/pos_all_orders/static/description/assets/modules/b4.png new file mode 100644 index 000000000..127f51e0b Binary files /dev/null and b/pos_all_orders/static/description/assets/modules/b4.png differ diff --git a/pos_all_orders/static/description/assets/modules/b5.png b/pos_all_orders/static/description/assets/modules/b5.png new file mode 100644 index 000000000..c46f05f78 Binary files /dev/null and b/pos_all_orders/static/description/assets/modules/b5.png differ diff --git a/pos_all_orders/static/description/assets/modules/b6.png b/pos_all_orders/static/description/assets/modules/b6.png new file mode 100644 index 000000000..a48b400df Binary files /dev/null and b/pos_all_orders/static/description/assets/modules/b6.png differ diff --git a/pos_all_orders/static/description/assets/screenshots/screenshot1.png b/pos_all_orders/static/description/assets/screenshots/screenshot1.png new file mode 100644 index 000000000..d0b5eafa4 Binary files /dev/null and b/pos_all_orders/static/description/assets/screenshots/screenshot1.png differ diff --git a/pos_all_orders/static/description/assets/screenshots/screenshot2.png b/pos_all_orders/static/description/assets/screenshots/screenshot2.png new file mode 100644 index 000000000..34b354b2a Binary files /dev/null and b/pos_all_orders/static/description/assets/screenshots/screenshot2.png differ diff --git a/pos_all_orders/static/description/assets/screenshots/screenshot3.png b/pos_all_orders/static/description/assets/screenshots/screenshot3.png new file mode 100644 index 000000000..62b036474 Binary files /dev/null and b/pos_all_orders/static/description/assets/screenshots/screenshot3.png differ diff --git a/pos_all_orders/static/description/assets/screenshots/screenshot4.png b/pos_all_orders/static/description/assets/screenshots/screenshot4.png new file mode 100644 index 000000000..a4df92ada Binary files /dev/null and b/pos_all_orders/static/description/assets/screenshots/screenshot4.png differ diff --git a/pos_all_orders/static/description/assets/screenshots/screenshot5.png b/pos_all_orders/static/description/assets/screenshots/screenshot5.png new file mode 100644 index 000000000..2e304c7f9 Binary files /dev/null and b/pos_all_orders/static/description/assets/screenshots/screenshot5.png differ diff --git a/pos_all_orders/static/description/banner.png b/pos_all_orders/static/description/banner.png new file mode 100644 index 000000000..9616a8b7a Binary files /dev/null and b/pos_all_orders/static/description/banner.png differ diff --git a/pos_all_orders/static/description/icon.png b/pos_all_orders/static/description/icon.png new file mode 100644 index 000000000..0bc96eddd Binary files /dev/null and b/pos_all_orders/static/description/icon.png differ diff --git a/pos_all_orders/static/description/index.html b/pos_all_orders/static/description/index.html new file mode 100644 index 000000000..b528a915e --- /dev/null +++ b/pos_all_orders/static/description/index.html @@ -0,0 +1,914 @@ + + + + + + POS Order Management + + + + + + + + + + +
+
+ + + +
+
+ Community +
+
+ Enterprise +
+
+ Odoo.sh +
+
+
+ +
+
+
+
+

+ Allows the detailed view of all orders in POS +

+

POS Order Management +

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

Key + Highlights

+
+
+
+
+ +
+
+ Module allows you to display all the old orders in Point of Sale. +
+

+

+
+
+
+
+ +
+
+
+ POS Order Management +

+ Are you ready to make your business more + organized? +
Improve now! +

+ +
+
+ +
+
+
+ + + +
+
+ +
+
+
+
+ acc_bg +
+ +
+
+
+
+

+ Click the button + + All order's +

+
+
+

+ Click this button to show the order screen.

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

+ Set the pos orders views in + + configuration +

+
+
+

+ In the configuration we can set the pos orders views. +

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

+ Current session + + Orders +

+
+
+

+ +

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

+ All past + + orders +

+
+
+

+

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

+ In the configuration set the pos + + orders views. +

+
+
+

+

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

+ Odoo POS All Orders List Module allows you to display all the old orders in Point of Sale.

+
+ +
+
+
+
+
+
+ +
+

+ Using this module you will get the detailed view of Order Reference, Receipt Reference, Customer and Order Date.

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

+ This module provides the + ability to view all previous + orders directly within the Point of Sale + (POS) system. It ensures you can easily + access historical order information + without leaving the POS interface. +

+
+
+ +
+ +
+

+ You can view detailed information about old orders, including: + Order Reference, Receipt Reference, Customer, Order Date. + +

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

+ Latest Release 18.0.1.0.0 +

+ + 06th December, 2024 + +
+
+
+
+
+ Add +
+
+
+
    +
  • + Initial Commit +
  • +
+
+
+
+
+
+
+
+
+
+ + + +
+

+ Related Products +

+ +
+ +
+

+ Our Services

+ +
+ +
+
+ .... +
+
+ +
+ + +
+
+ + + + + + diff --git a/pos_all_orders/static/src/js/all_order_button.js b/pos_all_orders/static/src/js/all_order_button.js new file mode 100644 index 000000000..90e9c96a4 --- /dev/null +++ b/pos_all_orders/static/src/js/all_order_button.js @@ -0,0 +1,66 @@ +/** @odoo-module **/ +import { ControlButtons } from "@point_of_sale/app/screens/product_screen/control_buttons/control_buttons"; +import { Component } from "@odoo/owl"; +import { usePos } from "@point_of_sale/app/store/pos_hook"; +import { patch } from "@web/core/utils/patch"; +import { useService } from "@web/core/utils/hooks"; +import { ProductScreen } from "@point_of_sale/app/screens/product_screen/product_screen"; + + +patch(ControlButtons.prototype, { + setup() { + super.setup(...arguments) + this.orm = useService("orm"); + this.pos = usePos(); + + }, + async onClick() { + const session = this.pos.config.current_session_id.id + var self = this; + await this.orm.call( + "pos.session", "get_all_order_config", [], {} + ).then(function(result){ + if ( result.config == 'current_session'){ + self.orm.call( + "pos.session", "get_all_order", [{session:session}], {} + ).then(function(order){ + self.pos.showScreen('CustomALLOrdrScreen', { + orders: order, + pos: self.env.pos + }); + + }); + } + else if (result.config == 'past_order'){ + self.orm.call( + "pos.session", "get_all_past_orders", [{session:session}], {} + ).then(function(order){ + self.pos.showScreen('CustomALLOrdrScreen', { + orders: order, + pos: self.env.pos + }); + }); + } + else if (result.config == 'last_n'){ + self.orm.call( + "pos.session", "get_all_order", [{session: session, n_days: result.n_days}], {} + ).then(function(order){ + self.pos.showScreen('CustomALLOrdrScreen', { + orders: order, + pos: self.env.pos + }); + }); + } + else{ + self.orm.call( + "pos.session", "get_default_all_orders", [{session:session}], {} + ).then(function(order){ + self.pos.showScreen('CustomALLOrdrScreen', { + orders: order, + pos: self.env.pos + }); + }); + } + }); + } +}); \ No newline at end of file diff --git a/pos_all_orders/static/src/js/all_order_screen.js b/pos_all_orders/static/src/js/all_order_screen.js new file mode 100644 index 000000000..7cf877ae8 --- /dev/null +++ b/pos_all_orders/static/src/js/all_order_screen.js @@ -0,0 +1,24 @@ +/** @odoo-module **/ +import { Component } from "@odoo/owl"; +import { registry } from "@web/core/registry"; +import { TicketScreen } from "@point_of_sale/app/screens/ticket_screen/ticket_screen"; +import { usePos } from "@point_of_sale/app/store/pos_hook"; +import { useService } from "@web/core/utils/hooks"; +import { useState } from "@odoo/owl"; + +class CustomALLOrdrScreen extends Component { + static template = "pos_all_orders.CustomALLOrdrScreen"; + setup() { + super.setup(); + this.pos = usePos(); + this.orm = useService("orm"); + this.state = useState({ + order: this.props.orders + }); + } + back() { + // on clicking the back button it will redirected Product screen + this.pos.showScreen('ProductScreen'); + } +} +registry.category("pos_screens").add("CustomALLOrdrScreen", CustomALLOrdrScreen); diff --git a/pos_all_orders/static/src/js/models.js b/pos_all_orders/static/src/js/models.js new file mode 100644 index 000000000..55a234988 --- /dev/null +++ b/pos_all_orders/static/src/js/models.js @@ -0,0 +1,11 @@ +/** @odoo-module */ +import { PosStore } from "@point_of_sale/app/store/pos_store"; +import { patch } from "@web/core/utils/patch"; + +patch(PosStore.prototype, { + async processServerData() { + super.processServerData(...arguments); + this.pos_orders = this.data.models['pos.order'].getFirst(); + this.pos_order_lines = this.data.models['pos.order.line'].getAll() + } +}); diff --git a/pos_all_orders/static/src/xml/all_order_button.xml b/pos_all_orders/static/src/xml/all_order_button.xml new file mode 100644 index 000000000..ab6b36e52 --- /dev/null +++ b/pos_all_orders/static/src/xml/all_order_button.xml @@ -0,0 +1,14 @@ + + + + + + + + + + diff --git a/pos_all_orders/static/src/xml/all_order_screen.xml b/pos_all_orders/static/src/xml/all_order_screen.xml new file mode 100644 index 000000000..b8e6ad6c3 --- /dev/null +++ b/pos_all_orders/static/src/xml/all_order_screen.xml @@ -0,0 +1,58 @@ + + + +
+
+
+
+ + Back +
+
+
+
+
+
+
Order Reference
+
Receipt Reference
+
Customer
+
Order Date
+
+ +
+
+
+ +
+
+
+
+ +
+
+ +
+
+ +
+
+
+ +
+
+ +
+
+
+
+
+ +
+
+
+
+
+
+
+
+
\ No newline at end of file diff --git a/pos_all_orders/views/res_config_settings_views.xml b/pos_all_orders/views/res_config_settings_views.xml new file mode 100644 index 000000000..ef947b1dc --- /dev/null +++ b/pos_all_orders/views/res_config_settings_views.xml @@ -0,0 +1,34 @@ + + + + + res.config.settings.view.form.inherit.pos_all_orders + res.config.settings + + + +

POS Order

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