From acfa7624fa8ea56bb572f9a33af2a567a582b50e Mon Sep 17 00:00:00 2001 From: AjmalCybro Date: Thu, 13 Jul 2023 12:39:32 +0530 Subject: [PATCH] Jul 13 : [FIX] Bug Fixed 'customer_product_qrcode' --- customer_product_qrcode/__manifest__.py | 9 +- .../data/ir_sequence_data.xml | 19 ++ customer_product_qrcode/doc/RELEASE_NOTES.md | 9 +- customer_product_qrcode/models/__init__.py | 6 +- customer_product_qrcode/models/models.py | 205 ------------------ .../models/product_product.py | 114 ++++++++++ .../models/product_template.py | 40 ++++ .../models/res_config_settings.py | 62 ++++++ customer_product_qrcode/models/res_partner.py | 110 ++++++++++ customer_product_qrcode/report/parser.py | 7 + customer_product_qrcode/report/report.xml | 44 ++-- .../views/product_product_views.xml | 21 ++ .../views/product_template_views.xml | 17 ++ .../views/res_config_settings_views.xml | 41 ++++ .../views/res_partner_views.xml | 21 ++ customer_product_qrcode/views/view.xml | 105 --------- 16 files changed, 492 insertions(+), 338 deletions(-) create mode 100644 customer_product_qrcode/data/ir_sequence_data.xml delete mode 100755 customer_product_qrcode/models/models.py create mode 100644 customer_product_qrcode/models/product_product.py create mode 100644 customer_product_qrcode/models/product_template.py create mode 100644 customer_product_qrcode/models/res_config_settings.py create mode 100755 customer_product_qrcode/models/res_partner.py create mode 100644 customer_product_qrcode/views/product_product_views.xml create mode 100644 customer_product_qrcode/views/product_template_views.xml create mode 100644 customer_product_qrcode/views/res_config_settings_views.xml create mode 100755 customer_product_qrcode/views/res_partner_views.xml delete mode 100755 customer_product_qrcode/views/view.xml diff --git a/customer_product_qrcode/__manifest__.py b/customer_product_qrcode/__manifest__.py index dd45525ea..ca90a5066 100755 --- a/customer_product_qrcode/__manifest__.py +++ b/customer_product_qrcode/__manifest__.py @@ -24,7 +24,8 @@ 'name': 'Customer and Product QR Code Generator', 'version': '15.0.1.0.0', 'summary': 'Generate Unique QR Codes for Customers and Products', - 'description': 'QR Code, QR Code Generator, Odoo QR Code Generator, Customer QR Code, Product QR Code, QR, QR Code Odoo', + 'description': 'QR Code, QR Code Generator, Odoo QR Code Generator, ' + 'Customer QR Code, Product QR Code, QR, QR Code Odoo', 'category': 'Extra Tools', 'author': 'Cybrosys Techno solutions', 'maintainer': 'Cybrosys Techno Solutions', @@ -32,9 +33,13 @@ 'website': 'https://www.cybrosys.com', 'depends': ['base', 'sale', 'stock'], 'data': [ + 'data/ir_sequence_data.xml', 'report/paperformat.xml', 'report/report.xml', - 'views/view.xml', + 'views/product_product_views.xml', + 'views/product_template_views.xml', + 'views/res_config_settings_views.xml', + 'views/res_partner_views.xml', 'report/template.xml', ], 'images': ['static/description/banner.png'], diff --git a/customer_product_qrcode/data/ir_sequence_data.xml b/customer_product_qrcode/data/ir_sequence_data.xml new file mode 100644 index 000000000..9a8d77357 --- /dev/null +++ b/customer_product_qrcode/data/ir_sequence_data.xml @@ -0,0 +1,19 @@ + + + + + customer_sequence + res.partner + + 5 + + + + + product_sequence + product.product + + 5 + + + diff --git a/customer_product_qrcode/doc/RELEASE_NOTES.md b/customer_product_qrcode/doc/RELEASE_NOTES.md index d7e81a4a1..4133dc2a2 100644 --- a/customer_product_qrcode/doc/RELEASE_NOTES.md +++ b/customer_product_qrcode/doc/RELEASE_NOTES.md @@ -1,6 +1,7 @@ ## Module -#### 18.11.2021 -#### Version 15.0.1.0.0 -#### ADD -- Initial commit for customer_product_qrcode \ No newline at end of file +#### 10.07.2023 +#### Version 15.0.2.0.0 +#### UPDT + +- Code Refactored diff --git a/customer_product_qrcode/models/__init__.py b/customer_product_qrcode/models/__init__.py index f2c5a4636..88193f57f 100755 --- a/customer_product_qrcode/models/__init__.py +++ b/customer_product_qrcode/models/__init__.py @@ -19,5 +19,7 @@ # If not, see . # ############################################################################# - -from . import models +from . import product_product +from . import product_template +from . import res_config_settings +from . import res_partner diff --git a/customer_product_qrcode/models/models.py b/customer_product_qrcode/models/models.py deleted file mode 100755 index 8ab2ea7c0..000000000 --- a/customer_product_qrcode/models/models.py +++ /dev/null @@ -1,205 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################# -# -# Cybrosys Technologies Pvt. Ltd. -# -# Copyright (C) 2021-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 . -# -############################################################################# - -try: - import qrcode -except ImportError: - qrcode = None -try: - import base64 -except ImportError: - base64 = None -from io import BytesIO - -from odoo import models, fields, api, _, SUPERUSER_ID -from odoo.exceptions import UserError - - -class Partners(models.Model): - _inherit = 'res.partner' - - sequence = fields.Char(string="QR Sequence", readonly=True) - qr = fields.Binary(string="QR Code") - - def init(self): - for record in self.env['res.partner'].search( - [('customer_rank', '=', True)]): - name = record.name.replace(" ", "") - record.sequence = 'DEF' + name.upper() + str(record.id) - - @api.model - def create(self, vals): - prefix = self.env['ir.config_parameter'].sudo().get_param( - 'customer_product_qr.config.customer_prefix') - if not prefix: - raise UserError(_('Set A Customer Prefix In General Settings')) - prefix = str(prefix) - seq = prefix + self.env['ir.sequence'].next_by_code( - 'res.partner') or '/' - vals['sequence'] = seq - return super(Partners, self).create(vals) - - @api.depends('sequence') - def generate_qr(self): - if qrcode and base64: - if not self.sequence: - prefix = self.env['ir.config_parameter'].sudo().get_param( - 'customer_product_qr.config.customer_prefix') - if not prefix: - raise UserError( - _('Set A Customer Prefix In General Settings')) - prefix = str(prefix) - self.sequence = prefix + self.env['ir.sequence'].next_by_code( - 'res.partner') or '/' - qr = qrcode.QRCode( - version=1, - error_correction=qrcode.constants.ERROR_CORRECT_L, - box_size=10, - border=4, - ) - qr.add_data(self.sequence) - qr.make(fit=True) - - img = qr.make_image() - temp = BytesIO() - img.save(temp, format="PNG") - qr_image = base64.b64encode(temp.getvalue()) - self.write({'qr': qr_image}) - return self.env.ref( - 'customer_product_qrcode.print_qr').report_action(self, data={ - 'data': self.id, 'type': 'cust'}) - else: - raise UserError( - _('Necessary Requirements To Run This Operation Is Not Satisfied')) - - def get_partner_by_qr(self, **args): - return self.env['res.partner'].search([('sequence', '=', self.id), ], - limit=1).id - - -class Products(models.Model): - _inherit = 'product.product' - - sequence = fields.Char(string="QR Sequence", readonly=True) - qr = fields.Binary(string="QR Code") - - @api.model - def create(self, vals): - prefix = self.env['ir.config_parameter'].sudo().get_param( - 'customer_product_qr.config.product_prefix') - if not prefix: - raise UserError(_('Set A Product Prefix In General Settings')) - prefix = str(prefix) - seq = prefix + self.env['ir.sequence'].next_by_code( - 'product.product') or '/' - vals['sequence'] = seq - qr = qrcode.QRCode( - version=1, - error_correction=qrcode.constants.ERROR_CORRECT_L, - box_size=10, - border=4, - ) - qr.add_data(vals['sequence']) - qr.make(fit=True) - - img = qr.make_image() - temp = BytesIO() - img.save(temp, format="PNG") - qr_image = base64.b64encode(temp.getvalue()) - vals.update({'qr': qr_image}) - return super(Products, self).create(vals) - - @api.depends('sequence') - def generate_qr(self): - if qrcode and base64: - if not self.sequence: - prefix = self.env['ir.config_parameter'].sudo().get_param( - 'customer_product_qr.config.product_prefix') - if not prefix: - raise UserError( - _('Set A Customer Prefix In General Settings')) - prefix = str(prefix) - self.sequence = prefix + self.env['ir.sequence'].next_by_code( - 'product.product') or '/' - qr = qrcode.QRCode( - version=1, - error_correction=qrcode.constants.ERROR_CORRECT_L, - box_size=10, - border=4, - ) - qr.add_data(self.sequence) - qr.make(fit=True) - - img = qr.make_image() - temp = BytesIO() - img.save(temp, format="PNG") - qr_image = base64.b64encode(temp.getvalue()) - self.write({'qr': qr_image}) - return self.env.ref( - 'customer_product_qrcode.print_qr2').report_action(self, data={ - 'data': self.id, 'type': 'prod'}) - else: - raise UserError( - _('Necessary Requirements To Run This Operation Is Not Satisfied')) - - def get_product_by_qr(self, **args): - return self.env['product.product'].search( - [('sequence', '=', self.id), ], limit=1).id - - -class ProductTemplate(models.Model): - _inherit = 'product.template' - - def generate_qr(self): - product = self.env['product.product'].search( - [('product_tmpl_id', '=', self.id)]) - for rec in product: - rec.generate_qr() - return self.env.ref('customer_product_qrcode.print_qr2').report_action( - self, data={'data': self.id, 'type': 'all'}) - - -class ResConfigSettings(models.TransientModel): - _inherit = 'res.config.settings' - - customer_prefix = fields.Char(string="Customer QR Prefix") - product_prefix = fields.Char(string="Product QR Prefix") - - def get_values(self): - res = super(ResConfigSettings, self).get_values() - customer_prefix = self.env["ir.config_parameter"].get_param( - "customer_product_qr.config.customer_prefix") - product_prefix = self.env["ir.config_parameter"].get_param( - "customer_product_qr.config.product_prefix") - res.update({ - 'customer_prefix': customer_prefix if type( - customer_prefix) else False, - 'product_prefix': product_prefix if type(product_prefix) else False - } - ) - return res - - def set_values(self): - self.env['ir.config_parameter'].sudo().set_param( - 'customer_product_qr.config.customer_prefix', self.customer_prefix) - self.env['ir.config_parameter'].sudo().set_param( - 'customer_product_qr.config.product_prefix', self.product_prefix) diff --git a/customer_product_qrcode/models/product_product.py b/customer_product_qrcode/models/product_product.py new file mode 100644 index 000000000..370de04c9 --- /dev/null +++ b/customer_product_qrcode/models/product_product.py @@ -0,0 +1,114 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2021-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 . +# +############################################################################# +try: + import qrcode +except ImportError: + qrcode = None +try: + import base64 +except ImportError: + base64 = None +from io import BytesIO +from odoo import api, fields, models, _ +from odoo.exceptions import UserError + + +class Products(models.Model): + """ + ProductProduct class for add methods and fields for generate qr code, + Methods: + create(self, vals): + Create method for adding sequence when new product creating. + generate_qr(self): + QRcode generating method + get_product_by_qr(self, **args): + For getting qr code info of corresponding product + """ + _inherit = 'product.product' + + sequence = fields.Char(string="QR Sequence", readonly=True) + qr = fields.Binary(string="QR Code") + + @api.model + def create(self, vals): + """ Supering create method to assign qr code to the product """ + prefix = self.env['ir.config_parameter'].sudo().get_param( + 'customer_product_qr.config.product_prefix') + if not prefix: + raise UserError(_('Set A Product Prefix In General Settings')) + prefix = str(prefix) + seq = prefix + self.env['ir.sequence'].next_by_code( + 'product.product') or '/' + vals['sequence'] = seq + qr = qrcode.QRCode( + version=1, + error_correction=qrcode.constants.ERROR_CORRECT_L, + box_size=10, + border=4, + ) + qr.add_data(vals['sequence']) + qr.make(fit=True) + img = qr.make_image() + temp = BytesIO() + img.save(temp, format="PNG") + qr_image = base64.b64encode(temp.getvalue()) + vals.update({'qr': qr_image}) + return super(Products, self).create(vals) + + @api.depends('sequence') + def generate_qr(self): + """ QR code generating method """ + if qrcode and base64: + if not self.sequence: + prefix = self.env['ir.config_parameter'].sudo().get_param( + 'customer_product_qr.config.product_prefix') + if not prefix: + raise UserError( + _('Set A Customer Prefix In General Settings')) + prefix = str(prefix) + self.sequence = prefix + self.env['ir.sequence'].next_by_code( + 'product.product') or '/' + qr = qrcode.QRCode( + version=1, + error_correction=qrcode.constants.ERROR_CORRECT_L, + box_size=10, + border=4, + ) + qr.add_data(self.sequence) + qr.make(fit=True) + + img = qr.make_image() + temp = BytesIO() + img.save(temp, format="PNG") + qr_image = base64.b64encode(temp.getvalue()) + self.write({'qr': qr_image}) + return self.env.ref( + 'customer_product_qrcode.print_qr2').report_action(self, data={ + 'data': self.id, 'type': 'prod'}) + else: + raise UserError(_('Necessary Requirements To Run This ' + 'Operation Is Not Satisfied')) + + def get_product_by_qr(self, **args): + """ To get corresponding product by qr info """ + return self.env['product.product'].search( + [('sequence', '=', self.id), ], limit=1).id diff --git a/customer_product_qrcode/models/product_template.py b/customer_product_qrcode/models/product_template.py new file mode 100644 index 000000000..ff5e18fd3 --- /dev/null +++ b/customer_product_qrcode/models/product_template.py @@ -0,0 +1,40 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2021-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 fields, models + + +class ProductTemplate(models.Model): + """ + ProductTemplate class for add methods and field for generate qr code, + Methods: + generate_qr(self): + QRcode generating method + """ + _inherit = 'product.template' + + def generate_qr(self): + product = self.env['product.product'].search( + [('product_tmpl_id', '=', self.id)]) + for rec in product: + rec.generate_qr() + return self.env.ref('customer_product_qrcode.print_qr2').report_action( + self, data={'data': self.id, 'type': 'all'}) diff --git a/customer_product_qrcode/models/res_config_settings.py b/customer_product_qrcode/models/res_config_settings.py new file mode 100644 index 000000000..dc0b64acb --- /dev/null +++ b/customer_product_qrcode/models/res_config_settings.py @@ -0,0 +1,62 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2021-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 fields, models + + +class ResConfigSettings(models.TransientModel): + """ + ResConfigSettings class for add methods and field for generate qr code + options in general settings, + Methods: + get_values(self): + For getting values from ResConfigSettings Transient model + set_values(self): + For setting values for ResConfigSettings Transient model, ie saving + the changes that made from general settings. + """ + _inherit = 'res.config.settings' + + customer_prefix = fields.Char(string="Customer QR Prefix") + product_prefix = fields.Char(string="Product QR Prefix") + + def get_values(self): + """ For getting values from ResConfigSettings Transient model """ + res = super(ResConfigSettings, self).get_values() + customer_prefix = self.env["ir.config_parameter"].get_param( + "customer_product_qr.config.customer_prefix") + product_prefix = self.env["ir.config_parameter"].get_param( + "customer_product_qr.config.product_prefix") + res.update({ + 'customer_prefix': customer_prefix if type( + customer_prefix) else False, + 'product_prefix': product_prefix if type(product_prefix) else False + } + ) + return res + + def set_values(self): + """ Saving the changes made from general settings """ + self.env['ir.config_parameter'].sudo().set_param( + 'customer_product_qr.config.customer_prefix', self.customer_prefix) + self.env['ir.config_parameter'].sudo().set_param( + 'customer_product_qr.config.product_prefix', self.product_prefix) + super(ResConfigSettings, self).set_values() diff --git a/customer_product_qrcode/models/res_partner.py b/customer_product_qrcode/models/res_partner.py new file mode 100755 index 000000000..57f1b3dda --- /dev/null +++ b/customer_product_qrcode/models/res_partner.py @@ -0,0 +1,110 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2021-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 . +# +############################################################################# +try: + import qrcode +except ImportError: + qrcode = None +try: + import base64 +except ImportError: + base64 = None +from io import BytesIO + +from odoo import api, fields, models, _ +from odoo.exceptions import UserError + + +class Partners(models.Model): + """ + ResPartners class for add methods and field for generate qr code, + Methods: + init(self): + Initializing res.partners to add sequence + create(self, vals): + Create method for adding sequence when new partner creating. + generate_qr(self): + QRcode generating method + get_partner_by_qr(self, **args): + For getting qr code info of corresponding partner + """ + _inherit = 'res.partner' + + sequence = fields.Char(string="QR Sequence", readonly=True) + qr = fields.Binary(string="QR Code") + + def init(self): + """ Initializing res.partners to add sequence """ + for record in self.env['res.partner'].search( + [('customer_rank', '=', True)]): + name = record.name.replace(" ", "") + record.sequence = 'DEF' + name.upper() + str(record.id) + + @api.model + def create(self, vals): + """ Create method for adding sequence when new partner creating. """ + prefix = self.env['ir.config_parameter'].sudo().get_param( + 'customer_product_qr.config.customer_prefix') + if not prefix: + raise UserError(_('Set A Customer Prefix In General Settings')) + prefix = str(prefix) + seq = prefix + self.env['ir.sequence'].next_by_code( + 'res.partner') or '/' + vals['sequence'] = seq + return super(Partners, self).create(vals) + + @api.depends('sequence') + def generate_qr(self): + """ QR code generating method """ + if qrcode and base64: + if not self.sequence: + prefix = self.env['ir.config_parameter'].sudo().get_param( + 'customer_product_qr.config.customer_prefix') + if not prefix: + raise UserError( + _('Set A Customer Prefix In General Settings')) + prefix = str(prefix) + self.sequence = prefix + self.env['ir.sequence'].next_by_code( + 'res.partner') or '/' + qr = qrcode.QRCode( + version=1, + error_correction=qrcode.constants.ERROR_CORRECT_L, + box_size=10, + border=4, + ) + qr.add_data(self.sequence) + qr.make(fit=True) + img = qr.make_image() + temp = BytesIO() + img.save(temp, format="PNG") + qr_image = base64.b64encode(temp.getvalue()) + self.write({'qr': qr_image}) + return self.env.ref( + 'customer_product_qrcode.print_qr').report_action(self, data={ + 'data': self.id, 'type': 'cust'}) + else: + raise UserError( + _('Necessary Requirements To Run This Operation Is Not Satisfied')) + + def get_partner_by_qr(self, **args): + """ For getting qr code info of curresponding partner """ + return self.env['res.partner'].search([('sequence', '=', self.id), ], + limit=1).id diff --git a/customer_product_qrcode/report/parser.py b/customer_product_qrcode/report/parser.py index 79afdd000..bfb6c0a64 100755 --- a/customer_product_qrcode/report/parser.py +++ b/customer_product_qrcode/report/parser.py @@ -24,10 +24,17 @@ from odoo.http import request class CustomerBadge(models.AbstractModel): + """ + Class for qr code report + Methods: + _get_report_values(self, docids, data=None): + method to get values for the report + """ _name = 'report.customer_product_qrcode.customer_qr_template' @api.model def _get_report_values(self, docids, data=None): + """ getting values for the report to print """ if data['type'] == 'cust': dat = [request.env['res.partner'].browse(data['data'])] elif data['type'] == 'all': diff --git a/customer_product_qrcode/report/report.xml b/customer_product_qrcode/report/report.xml index 189fd7b67..83b3445d2 100755 --- a/customer_product_qrcode/report/report.xml +++ b/customer_product_qrcode/report/report.xml @@ -1,38 +1,42 @@ - - - + - + - - - - - - - - - - + menu="False" + /> + + + + + + + + + + + + \ No newline at end of file diff --git a/customer_product_qrcode/views/product_product_views.xml b/customer_product_qrcode/views/product_product_views.xml new file mode 100644 index 000000000..ad88d790c --- /dev/null +++ b/customer_product_qrcode/views/product_product_views.xml @@ -0,0 +1,21 @@ + + + + + product.product.form.qr.inherit + product.product + + +
+ +
+ + + + +
+
\ No newline at end of file diff --git a/customer_product_qrcode/views/product_template_views.xml b/customer_product_qrcode/views/product_template_views.xml new file mode 100644 index 000000000..7fa4a4e0a --- /dev/null +++ b/customer_product_qrcode/views/product_template_views.xml @@ -0,0 +1,17 @@ + + + + + product.template.form.qr.inherit + product.template + + +
+ +
+
+
+
\ No newline at end of file diff --git a/customer_product_qrcode/views/res_config_settings_views.xml b/customer_product_qrcode/views/res_config_settings_views.xml new file mode 100644 index 000000000..7c29eac3c --- /dev/null +++ b/customer_product_qrcode/views/res_config_settings_views.xml @@ -0,0 +1,41 @@ + + + + + res.config.inherit.qr + res.config.settings + + + +
+

Setup QRCode

+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file diff --git a/customer_product_qrcode/views/res_partner_views.xml b/customer_product_qrcode/views/res_partner_views.xml new file mode 100755 index 000000000..54d2f3bfe --- /dev/null +++ b/customer_product_qrcode/views/res_partner_views.xml @@ -0,0 +1,21 @@ + + + + + res.partner.form.qr.inherit + res.partner + + +
+ +
+ + + + +
+
diff --git a/customer_product_qrcode/views/view.xml b/customer_product_qrcode/views/view.xml deleted file mode 100755 index 8627cf1c0..000000000 --- a/customer_product_qrcode/views/view.xml +++ /dev/null @@ -1,105 +0,0 @@ - - - - - res.partner.form.qr.inherit - res.partner - - -
- -
- - - - -
- - product.product.form.qr.inherit - product.product - - -
- -
- - - - -
- - product.template.form.qr.inherit - product.template - - -
- - -
-
-
- - res.config.inherit.qr - res.config.settings - - - -
-

Setup QRCode

-
-
-
-
-
-
-
-
-
-
-
- - - customer_sequence - res.partner - - 5 - - - - - product_sequence - product.product - - 5 - - -
\ No newline at end of file