Browse Source

[ADD] Initial Commit 'customized_barcode_generator'

pull/207/merge
AjmalCybro 3 years ago
parent
commit
512d79a0d4
  1. 16
      customized_barcode_generator/README.rst
  2. 2
      customized_barcode_generator/__init__.py
  3. 24
      customized_barcode_generator/__manifest__.py
  4. 6
      customized_barcode_generator/doc/RELEASE_NOTES.md
  5. 1
      customized_barcode_generator/models/__init__.py
  6. 113
      customized_barcode_generator/models/barcode_generator.py
  7. 0
      customized_barcode_generator/report/__init__.py
  8. 153
      customized_barcode_generator/report/product_label_template.xml
  9. 2
      customized_barcode_generator/security/ir.model.access.csv
  10. BIN
      customized_barcode_generator/static/description/assets/icons/chevron.png
  11. BIN
      customized_barcode_generator/static/description/assets/icons/cogs.png
  12. BIN
      customized_barcode_generator/static/description/assets/icons/consultation.png
  13. BIN
      customized_barcode_generator/static/description/assets/icons/ecom-black.png
  14. BIN
      customized_barcode_generator/static/description/assets/icons/education-black.png
  15. BIN
      customized_barcode_generator/static/description/assets/icons/hotel-black.png
  16. BIN
      customized_barcode_generator/static/description/assets/icons/license.png
  17. BIN
      customized_barcode_generator/static/description/assets/icons/lifebuoy.png
  18. BIN
      customized_barcode_generator/static/description/assets/icons/manufacturing-black.png
  19. BIN
      customized_barcode_generator/static/description/assets/icons/pos-black.png
  20. BIN
      customized_barcode_generator/static/description/assets/icons/puzzle.png
  21. BIN
      customized_barcode_generator/static/description/assets/icons/restaurant-black.png
  22. BIN
      customized_barcode_generator/static/description/assets/icons/service-black.png
  23. BIN
      customized_barcode_generator/static/description/assets/icons/trading-black.png
  24. BIN
      customized_barcode_generator/static/description/assets/icons/training.png
  25. BIN
      customized_barcode_generator/static/description/assets/icons/update.png
  26. BIN
      customized_barcode_generator/static/description/assets/icons/user.png
  27. BIN
      customized_barcode_generator/static/description/assets/icons/wrench.png
  28. BIN
      customized_barcode_generator/static/description/banner.png
  29. BIN
      customized_barcode_generator/static/description/icon.png
  30. BIN
      customized_barcode_generator/static/description/images/checked.png
  31. BIN
      customized_barcode_generator/static/description/images/hero.png
  32. BIN
      customized_barcode_generator/static/description/images/modules/approval_image.png
  33. BIN
      customized_barcode_generator/static/description/images/modules/dynamic_image.png
  34. BIN
      customized_barcode_generator/static/description/images/modules/mulitple-ref_image.png
  35. BIN
      customized_barcode_generator/static/description/images/modules/pos_image.png
  36. BIN
      customized_barcode_generator/static/description/images/modules/shopify_image.png
  37. BIN
      customized_barcode_generator/static/description/images/screenshots/1barcode.png
  38. BIN
      customized_barcode_generator/static/description/images/screenshots/2barcode.png
  39. BIN
      customized_barcode_generator/static/description/images/screenshots/3barcode.png
  40. BIN
      customized_barcode_generator/static/description/images/screenshots/4barcode.png
  41. BIN
      customized_barcode_generator/static/description/images/screenshots/5barcode.png
  42. 579
      customized_barcode_generator/static/description/index.html
  43. 88
      customized_barcode_generator/views/barcode_generator_view.xml

16
customized_barcode_generator/README.rst

@ -0,0 +1,16 @@
Cost Price as Code in Barcode v15
=================================
The module enables user to print customized product labels.
Installation
============
- www.odoo.com/documentation/15.0/setup/install.html
- Install our custom addon
Credits
=======
Developer: Atul Ramesh Varma @ cybrosys, Contact: odoo@cybrosys.com
V13 : Sreenath.
V14 : Minhaj T @cybrosys, Contact: odoo@cybrosys.com
V15 : Mekha K @cybrosys, Contact: odoo@cybrosys.com

2
customized_barcode_generator/__init__.py

@ -0,0 +1,2 @@
from . import report
from . import models

24
customized_barcode_generator/__manifest__.py

@ -0,0 +1,24 @@
# -*- coding: utf-8 -*-
{
'name': 'Cost Price as Code in Barcode',
'version': '15.0.1.0.0',
'summary': """Print user defined product labels.""",
'description': """The module enables user to print customized product labels, Barcode, Barcode Generator, Barcode Label, Product Label, Product Barcode Generator, Product Barcode, Label Print, Product Label Print
""",
'category': 'Tools',
'author': 'Cybrosys Techno Solutions',
'company': 'Cybrosys Techno Solutions',
'maintainer': 'Cybrosys Techno Solutions',
'depends': ['base', 'web', 'product', 'account'],
'website': 'https://www.cybrosys.com',
'data': [
'report/product_label_template.xml',
'views/barcode_generator_view.xml',
'security/ir.model.access.csv'
],
'images': ['static/description/banner.png'],
'license': 'AGPL-3',
'installable': True,
'auto_install': False,
'application': False,
}

6
customized_barcode_generator/doc/RELEASE_NOTES.md

@ -0,0 +1,6 @@
## Module <customized_barcode_generator>
#### 09.10.2021
#### Version 15.0.1.0.0
##### ADD
- Initial commit for Customized Barcode Generator

1
customized_barcode_generator/models/__init__.py

@ -0,0 +1 @@
from . import barcode_generator

113
customized_barcode_generator/models/barcode_generator.py

@ -0,0 +1,113 @@
from odoo import api, fields, models, _
import datetime
from odoo.exceptions import UserError
class ResConfigSettings(models.TransientModel):
_inherit = 'res.config.settings'
active_standard_price = fields.Boolean(string='Standard price as a code',
help="check this box to show cost on the product labels as code")
active_ref = fields.Boolean(string='Show product reference ',
help="check this box to show product reference as in product labels")
@api.model
def get_values(self):
res = super(ResConfigSettings, self).get_values()
params = self.env['ir.config_parameter'].sudo()
active_standard_price = params.get_param('active_standard_price', default=False)
active_ref = params.get_param('active_ref', default=False)
res.update(
active_standard_price=bool(active_standard_price),
active_ref=bool(active_ref),
)
return res
def set_values(self):
super(ResConfigSettings, self).set_values()
self.env['ir.config_parameter'].sudo().set_param("active_standard_price",
self.active_standard_price)
self.env['ir.config_parameter'].sudo().set_param("active_ref",
self.active_ref)
class CustomizeBarcodeGenerator(models.Model):
_name = 'barcode.code'
name = fields.Char(default='Numeric Code')
code_for_zero = fields.Char(string=' 0 ', required=True, limit=1, size=1,
default='a', help="insert substitute code ")
code_for_one = fields.Char(string='1 ', required=True, limit=1, size=1,
default='b', help="insert substitute code ")
code_for_two = fields.Char(string='2 ', required=True, limit=1, size=1,
default='c', help="insert substitute code ")
code_for_three = fields.Char(string='3 ', required=True, limit=1, size=1,
default='d', help="insert substitute code ")
code_for_four = fields.Char(string='4 ', required=True, limit=1, size=1,
default='e', help="insert substitute code ")
code_for_five = fields.Char(string='5 ', required=True, limit=1, size=1,
default='f', help="insert substitute code ")
code_for_six = fields.Char(string='6 ', required=True, limit=1, size=1,
default='g', help="insert substitute code ")
code_for_seven = fields.Char(string='7 ', required=True, limit=1, size=1,
default='h', help="insert substitute code ")
code_for_eight = fields.Char(string='8 ', required=True, limit=1, size=1,
default='i', help="insert substitute code ")
code_for_nine = fields.Char(string='9 ', required=True, limit=1, size=1,
default='j', help="insert substitute code ")
active_check = fields.Boolean(string="Active", default=False)
date_check = fields.Datetime(default=datetime.datetime.today(), string="Date")
@api.onchange('active_check')
def onchange_active_check(self):
for i in self.search([]):
if i.active_check == self.active_check and self.active_check:
self.active_check = False
raise UserError(_("Only one rule for code can be active at a time"))
class CostToCode(models.Model):
_inherit = 'product.template'
cost_in_code = fields.Char(string='Cost in code', compute='get_cost_in_code')
@api.depends('standard_price')
def get_cost_in_code(self):
code = self.env['barcode.code'].sudo().search([('active_check', '=', True)])
active_check = self.env['ir.config_parameter'].sudo().search([('key','=','active_standard_price'),('value','=',True)])
if active_check:
if code:
real = str(self.standard_price).split('.')[0]
for i in real:
if i == '0':
real = real.replace('0', code.code_for_zero)
elif i == '1':
real = real.replace('1', code.code_for_one)
elif i == '2':
real = real.replace('2', code.code_for_two)
elif i == '3':
real = real.replace('3', code.code_for_three)
elif i == '4':
real = real.replace('4', code.code_for_four)
elif i == '5':
real = real.replace('5', code.code_for_five)
elif i == '6':
real = real.replace('6', code.code_for_six)
elif i == '7':
real = real.replace('7', code.code_for_seven)
elif i == '8':
real = real.replace('8', code.code_for_eight)
else:
real = real.replace('9', code.code_for_nine)
return real
else:
return " "
else:
return " "
def get_product_ref(self):
active_check = self.env['ir.config_parameter'].sudo().search([('key','=','active_ref'),('value','=',True)])
if active_check:
return self.default_code
else:
return " "

0
customized_barcode_generator/report/__init__.py

153
customized_barcode_generator/report/product_label_template.xml

@ -0,0 +1,153 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<data>
<template id="report_template_inherit" inherit_id="product.report_simple_label2x7">
<xpath expr="//div" position="replace">
<t t-set="barcode_size" t-value="'width:33mm;height:14mm'"/>
<t t-set="table_style" t-value="'width:97mm;height:37.1mm;' + table_style"/>
<td t-att-style="make_invisible and 'visibility:hidden;'" >
<div class="o_label_full" t-att-style="table_style">
<div class="o_label_name">
<strong t-field="product.display_name"/>
</div>
<div class="o_label_data">
<div class="text-center o_label_left_column">
<span class="text-nowrap" t-field="product.default_code"/>
<t> | </t>
<t t-esc="product.get_cost_in_code()"/>
<t t-if="barcode">
<div t-out="barcode" t-options="{'widget': 'barcode', 'symbology': 'auto', 'img_style': barcode_size}"/>
<span class="text-center" t-out="barcode"/>
</t>
</div>
<div class="text-right" style="line-height:normal">
<!-- <t t-esc="product.get_cost_in_code()"/>-->
<div class="o_label_extra_data">
<t t-out="extra_html"/>
</div>
<t t-if="product.is_product_variant">
<strong class="o_label_price" t-field="product.lst_price" t-options="{'widget': 'monetary', 'label_price': True}"/>
</t>
<t t-else="">
<strong class="o_label_price" t-field="product.list_price" t-options="{'widget': 'monetary', 'label_price': True}"/>
</t>
</div>
<div class="o_label_clear"></div>
</div>
</div>
</td>
</xpath>
</template>
<template id="report_template_inherit1" inherit_id="product.report_simple_label4x7">
<xpath expr="//div" position="replace">
<t t-set="barcode_size" t-value="'width:33mm;height:8mm'"/>
<t t-set="table_style" t-value="'width:47mm;height:37.1mm;' + table_style"/>
<td t-att-style="make_invisible and 'visibility:hidden;'" >
<div class="o_label_full" t-att-style="table_style">
<div class="o_label_name">
<strong t-field="product.display_name"/>
</div>
<div class="text-right" style="padding-top:0;padding-bottom:0">
<t t-if="product.is_product_variant">
<strong class="o_label_price_medium" t-field="product.lst_price" t-options="{'widget': 'monetary', 'label_price': True}"/>
</t>
<t t-else="">
<strong class="o_label_price_medium" t-field="product.list_price" t-options="{'widget': 'monetary', 'label_price': True}"/>
</t>
</div>
<div class= "text-center o_label_small_barcode">
<span class="text-nowrap" t-field="product.default_code"/>
<t> | </t>
<t t-esc="product.get_cost_in_code()"/>
<t t-if="barcode">
<div t-out="barcode" style="padding:0" t-options="{'widget': 'barcode', 'symbology': 'auto', 'img_style': barcode_size}"/>
<span class="text-center" t-out="barcode"/>
<span t-field="product.barcode"/>
</t>
</div>
</div>
</td>
</xpath>
</template>
<template id="report_template_inherit3" inherit_id="product.report_simple_label4x12">
<xpath expr="//div" position="replace">
<t t-set="barcode_size" t-value="'width:33mm;height:4mm'"/>
<t t-set="table_style" t-value="'width:43mm;height:19mm;' + table_style"/>
<td t-att-style="make_invisible and 'visibility:hidden;'" >
<div class="o_label_full o_label_small_text" t-att-style="table_style">
<div class="o_label_name">
<strong t-field="product.display_name"/>
</div>
<t t-if="price_included">
<div class="o_label_left_column">
<span class="text-nowrap" t-field="product.default_code"/>
<t> | </t>
<t t-esc="product.get_cost_in_code()"/>
</div>
<div class="o_label_price_medium text-right">
<t t-if="product.is_product_variant">
<strong t-field="product.lst_price" t-options="{'widget': 'monetary', 'label_price': True}"/>
</t>
<t t-else="">
<strong t-field="product.list_price" t-options="{'widget': 'monetary', 'label_price': True}"/>
</t>
</div>
</t>
<t t-else="">
<div class="o_label_left_column o_label_full_with">
<span class="text-nowrap" t-field="product.default_code"/>
<t> ---- </t>
<t t-esc="product.get_cost_in_code()"/>
</div>
</t>
<div class= "text-center o_label_small_barcode">
<t t-if="barcode">
<div t-out="barcode" style="padding:0" t-options="{'widget': 'barcode', 'symbology': 'auto', 'img_style': barcode_size}"/>
<span class="text-center" t-out="barcode"/>
</t>
<t t-else=""><span class="text-muted">No barcode available</span></t>
</div>
</div>
</td>
</xpath>
</template>
<template id="report_template_inherit2" inherit_id="product.report_simple_label_dymo">
<xpath expr="//div" position="replace">
<div class="o_label_sheet o_label_dymo" t-att-style="padding_page">
<div class="o_label_full" t-att-style="table_style">
<div class= "text-left o_label_small_barcode">
<t t-if="barcode">
<!-- `quiet=0` to remove the left and right margins on the barcode -->
<div t-out="barcode" style="padding:0" t-options="{'widget': 'barcode', 'quiet': 0, 'symbology': 'auto', 'img_style': barcode_size}"/>
<div class="o_label_name" style="line-height: 130%;height:2.7em;background-color: transparent;">
<span t-out="barcode"/>
</div>
</t>
</div>
<div class="o_label_name" style="line-height: 130%;height:2.7em;background-color: transparent;">
<span t-field="product.display_name"/>
</div>
<div class="o_label_left_column">
<small class="text-nowrap" t-field="product.default_code"/>
<t> | </t>
<t t-esc="product.get_cost_in_code()"/>
</div>
<div class="text-right" style="padding: 0 4px;">
<t t-if="product.is_product_variant">
<strong class="o_label_price_small" t-field="product.lst_price" t-options="{'widget': 'monetary', 'label_price': True}"/>
</t>
<t t-else="">
<strong class="o_label_price_small" t-field="product.list_price" t-options="{'widget': 'monetary', 'label_price': True}"/>
</t>
<div class="o_label_extra_data">
<t t-out="extra_html"/>
</div>
</div>
</div>
</div>
</xpath>
</template>
</data>
</odoo>

2
customized_barcode_generator/security/ir.model.access.csv

@ -0,0 +1,2 @@
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
access_customized_barcode_generator,customized.barcode.generator.user,model_barcode_code,account.group_account_manager,1,1,1,1
1 id name model_id:id group_id:id perm_read perm_write perm_create perm_unlink
2 access_customized_barcode_generator customized.barcode.generator.user model_barcode_code account.group_account_manager 1 1 1 1

BIN
customized_barcode_generator/static/description/assets/icons/chevron.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 310 B

BIN
customized_barcode_generator/static/description/assets/icons/cogs.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

BIN
customized_barcode_generator/static/description/assets/icons/consultation.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

BIN
customized_barcode_generator/static/description/assets/icons/ecom-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 576 B

BIN
customized_barcode_generator/static/description/assets/icons/education-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 733 B

BIN
customized_barcode_generator/static/description/assets/icons/hotel-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 911 B

BIN
customized_barcode_generator/static/description/assets/icons/license.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

BIN
customized_barcode_generator/static/description/assets/icons/lifebuoy.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

BIN
customized_barcode_generator/static/description/assets/icons/manufacturing-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 673 B

BIN
customized_barcode_generator/static/description/assets/icons/pos-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 878 B

BIN
customized_barcode_generator/static/description/assets/icons/puzzle.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 653 B

BIN
customized_barcode_generator/static/description/assets/icons/restaurant-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 905 B

BIN
customized_barcode_generator/static/description/assets/icons/service-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 839 B

BIN
customized_barcode_generator/static/description/assets/icons/trading-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 427 B

BIN
customized_barcode_generator/static/description/assets/icons/training.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 627 B

BIN
customized_barcode_generator/static/description/assets/icons/update.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

BIN
customized_barcode_generator/static/description/assets/icons/user.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 988 B

BIN
customized_barcode_generator/static/description/assets/icons/wrench.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

BIN
customized_barcode_generator/static/description/banner.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 60 KiB

BIN
customized_barcode_generator/static/description/icon.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

BIN
customized_barcode_generator/static/description/images/checked.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

BIN
customized_barcode_generator/static/description/images/hero.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 33 KiB

BIN
customized_barcode_generator/static/description/images/modules/approval_image.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 51 KiB

BIN
customized_barcode_generator/static/description/images/modules/dynamic_image.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 52 KiB

BIN
customized_barcode_generator/static/description/images/modules/mulitple-ref_image.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 53 KiB

BIN
customized_barcode_generator/static/description/images/modules/pos_image.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 52 KiB

BIN
customized_barcode_generator/static/description/images/modules/shopify_image.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 54 KiB

BIN
customized_barcode_generator/static/description/images/screenshots/1barcode.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 143 KiB

BIN
customized_barcode_generator/static/description/images/screenshots/2barcode.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 43 KiB

BIN
customized_barcode_generator/static/description/images/screenshots/3barcode.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 47 KiB

BIN
customized_barcode_generator/static/description/images/screenshots/4barcode.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 135 KiB

BIN
customized_barcode_generator/static/description/images/screenshots/5barcode.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 90 KiB

579
customized_barcode_generator/static/description/index.html

@ -0,0 +1,579 @@
<div style="padding: 3.5rem 1.5rem !important; background-color: #ffffff !important;">
<div class="container">
<!-- HERO -->
<div class="row">
<div class="col-lg-12 d-flex flex-column justify-content-center"
style="text-align: center; padding: 1rem !important;">
<h1 class="text-center" style="color: #212121 !important; font-size: 3rem !important;"><span
style="font-weight: 700 !important;">Customized Barcode Generator</span></h1>
<p class="text-center"
style="color: #212529 !important; font-size: 1.5rem !important; letter-spacing: 1px !important;">
Print user defined product labels.</p>
<img src="./images/hero.png" class="img-responsive">
</div>
</div>
<!-- END OF HERO -->
<!-- OVERVIEW -->
<div class="row">
<div class="col-lg-12 d-flex flex-column justify-content-center"
style="text-align: center; padding: 2.5rem 1rem !important;">
<h2 style="color: #212529 !important;">Overview</h2>
<hr
style="border: 3px solid #AC1015 !important; background-color: #AC1015 !important; width: 80px !important; margin-bottom: 2rem !important;" />
<p class="text-center" style="color: #212529 !important; font-size: 1.5rem !important;">
The module enables user to print customized product labels.
</p>
</div>
</div>
<!-- END OF OVERVIEW -->
<!-- KEY FEATURES -->
<div class="row">
<div class="col-lg-12 d-flex flex-column justify-content-center" style="padding: 2.5rem 1rem !important;">
<h2 class="text-center" style="color: #212529 !important;">Key Features</h2>
<hr
style="border: 3px solid #AC1015 !important; background-color: #AC1015 !important; width: 80px !important; margin-bottom: 2rem !important;" />
<div class="row">
<div class="col-lg-12">
<div class="d-flex deep-2"
style="height: 60px !important; padding: 1rem 1.5rem !important; border-radius: 0 !important; margin: 1.5rem 0">
<img src="./images/checked.png" style="height: 24px !important; width: 24px !important;"
class="mt-1 mr-2" height="24px" width="24px">
<p style="color: #212529 !important; font-size: 1.3rem !important;">
Create custom code for printing standard price on product labels.
</p>
</div>
<div class="d-flex deep-2"
style="height: 60px !important; padding: 1rem 1.5rem !important; border-radius: 0 !important; margin: 1.5rem 0">
<img src="./images/checked.png" style="height: 24px !important; width: 24px !important;"
class="mt-1 mr-2" height="24px" width="24px">
<p style="color: #212529 !important; font-size: 1.3rem !important;">
Show/hide product reference on product labels.
</p>
</div>
<div class="d-flex deep-2"
style="height: 60px !important; padding: 1rem 1.5rem !important; border-radius: 0 !important; margin: 1.5rem 0">
<img src="./images/checked.png" style="height: 24px !important; width: 24px !important;"
class="mt-1 mr-2" height="24px" width="24px">
<p style="color: #212529 !important; font-size: 1.3rem !important;">
Show/hide cost price as a code on product labels.
</p>
</div>
</div>
</div>
</div>
</div>
<!-- END OF KEY FEATURES -->
<!-- SCREENSHOTS -->
<div class="row">
<div class="col-lg-12 d-flex flex-column justify-content-center" style="padding: 2.5rem 1rem !important;">
<h2 style="text-align: center; color: #212529 !important;">Screenshots</h2>
<hr
style="border: 3px solid #AC1015 !important; background-color: #AC1015 !important; width: 80px !important; margin-bottom: 2rem !important;" />
<!-- img -->
<div class="d-flex m-0" style="border-bottom: 1px solid #e5e5e5 !important;">
<div class="mr-3">
<h3
style="font-size: 2rem !important; font-weight: 800 !important; color: #ffffff !important; background-color: #AC1015 !important; padding: 1rem !important; width: 70px !important; height: 75px !important;">
01</h3>
</div>
<div>
<h3 style="font-size: 1.7rem !important; font-weight: 600 !important;">
Go to Invoicing --> Settings
</h3>
<p
style="color: #212529 !important; font-size: 1.3rem !important; font-weight: 300 !important;">
Select whether to show/hide standard price as code or product reference on product
labels and click Save.
</p>
</div>
</div>
<img src="./images/screenshots/1barcode.png" class="img-responsive border"
style="margin-top: -15px !important; margin-top: 1rem !important; margin-bottom: 4rem !important;">
<!-- endo of img -->
<!-- img -->
<div class="d-flex m-0" style="border-bottom: 1px solid #e5e5e5 !important;">
<div class="mr-3">
<h3
style="font-size: 2rem !important; font-weight: 800 !important; color: #ffffff !important; background-color: #AC1015 !important; padding: 1rem !important; width: 70px !important; height: 75px !important;">
02</h3>
</div>
<div>
<h3 style="font-size: 1.7rem !important; font-weight: 600 !important;">
Go to Invoicing --> Settings --> Product Labels
</h3>
<p
style="color: #212529 !important; font-size: 1.3rem !important; font-weight: 300 !important;">
Click on barcode code to create a new rules.
</p>
</div>
</div>
<img src="./images/screenshots/2barcode.png" class="img-responsive border"
style="margin-top: -15px !important; margin-top: 1rem !important; margin-bottom: 4rem !important;">
<!-- endo of img -->
<!-- img -->
<div class="d-flex m-0" style="border-bottom: 1px solid #e5e5e5 !important;">
<div class="mr-3">
<h3
style="font-size: 2rem !important; font-weight: 800 !important; color: #ffffff !important; background-color: #AC1015 !important; padding: 1rem !important; width: 70px !important; height: 75px !important;">
03</h3>
</div>
<div>
<h3 style="font-size: 1.7rem !important; font-weight: 600 !important;">
Set codes for each digits.
</h3>
<p
style="color: #212529 !important; font-size: 1.3rem !important; font-weight: 300 !important;">
In the form view, you can set the code for each digit. Click on the active button to use
this rule on the product label.
</p>
</div>
</div>
<img src="./images/screenshots/3barcode.png" class="img-responsive border"
style="margin-top: -15px !important; margin-top: 1rem !important; margin-bottom: 4rem !important;">
<!-- endo of img -->
<!-- img -->
<div class="d-flex m-0" style="border-bottom: 1px solid #e5e5e5 !important;">
<div class="mr-3">
<h3
style="font-size: 2rem !important; font-weight: 800 !important; color: #ffffff !important; background-color: #AC1015 !important; padding: 1rem !important; width: 70px !important; height: 75px !important;">
04</h3>
</div>
<div>
<h3 style="font-size: 1.7rem !important; font-weight: 600 !important;">
Printing the labels
</h3>
<p
style="color: #212529 !important; font-size: 1.3rem !important; font-weight: 300 !important;">
Go to Products view select products and print product labels as shown below.
</p>
</div>
</div>
<img src="./images/screenshots/4barcode.png" class="img-responsive border"
style="margin-top: -15px !important; margin-top: 1rem !important; margin-bottom: 4rem !important;">
<!-- endo of img -->
<!-- img -->
<div class="d-flex m-0" style="border-bottom: 1px solid #e5e5e5 !important;">
<div class="mr-3">
<h3
style="font-size: 2rem !important; font-weight: 800 !important; color: #ffffff !important; background-color: #AC1015 !important; padding: 1rem !important; width: 70px !important; height: 75px !important;">
05</h3>
</div>
<div>
<h3 style="font-size: 1.7rem !important; font-weight: 600 !important;">
Labels with standard price of products and product reference
</h3>
<p
style="color: #212529 !important; font-size: 1.3rem !important; font-weight: 300 !important;">
You can see the standard price of products on the bottom right of product label as code
using the active rule, and at the bottom left you can see the product reference.
</p>
</div>
</div>
<img src="./images/screenshots/5barcode.png" class="img-responsive border"
style="margin-top: -15px !important; margin-top: 1rem !important; margin-bottom: 4rem !important;">
<!-- endo of img -->
</div>
</div>
<!-- END OF SCREENSHOTS -->
<!-- SUGGESTED PRODUCTS -->
<div class="row">
<div class="col-lg-12 d-flex flex-column justify-content-center"
style="text-align: center; padding: 2.5rem 1rem !important;">
<h2 style="color: #212529 !important;">Suggested Products</h2>
<hr
style="border: 3px solid #AC1015 !important; background-color: #AC1015 !important; width: 80px !important; margin-bottom: 2rem !important;" />
<div id="demo1" class="row carousel slide" data-ride="carousel">
<!-- The slideshow -->
<div class="carousel-inner">
<div class="carousel-item active" style="min-height:0px">
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16" style="float:left">
<a href="https://apps.odoo.com/apps/modules/14.0/dynamic_accounts_report/"
target="_blank">
<div style="border-radius:10px">
<img class="img img-responsive center-block"
style="border-top-left-radius:10px; border-top-right-radius:10px"
src="./images/modules/dynamic_image.png">
</div>
</a>
</div>
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16" style="float:left">
<a href="https://apps.odoo.com/apps/modules/14.0/dashboard_pos/" target="_blank">
<div style="border-radius:10px">
<img class="img img-responsive center-block"
style="border-top-left-radius:10px; border-top-right-radius:10px"
src="./images/modules/pos_image.png">
</div>
</a>
</div>
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16" style="float:left">
<a href="https://apps.odoo.com/apps/modules/14.0/product_approval_management/"
target="_blank">
<div style="border-radius:10px">
<img class="img img-responsive center-block"
style="border-top-left-radius:10px; border-top-right-radius:10px"
src="./images/modules/approval_image.png">
</div>
</a>
</div>
</div>
<div class="carousel-item" style="min-height:0px">
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16" style="float:left">
<a href="https://apps.odoo.com/apps/modules/14.0/multiple_reference_per_product/"
target="_blank">
<div style="border-radius:10px">
<img class="img img-responsive center-block"
style="border-top-left-radius:10px; border-top-right-radius:10px"
src="./images/modules/mulitple-ref_image.png">
</div>
</a>
</div>
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16" style="float:left">
<a href="https://apps.odoo.com/apps/modules/14.0/shopify_odoo_connector/"
target="_blank">
<div style="border-radius:10px">
<img class="img img-responsive center-block"
style="border-top-left-radius:10px; border-top-right-radius:10px"
src="./images/modules/shopify_image.png">
</div>
</a>
</div>
</div>
</div>
<!-- Left and right controls -->
<a class="carousel-control-prev" href="#demo1" data-slide="prev"
style="left:-25px;width: 35px;color: #000;"> <span class="carousel-control-prev-icon"><i
class="fa fa-chevron-left" style="font-size:24px"></i></span> </a> <a
class="carousel-control-next" href="#demo1" data-slide="next"
style="right:-25px;width: 35px;color: #000;">
<span class="carousel-control-next-icon"><i class="fa fa-chevron-right"
style="font-size:24px"></i></span>
</a>
</div>
</div>
</div>
<!-- END OF SUGGESTED PRODUCTS -->
<!-- OUR SERVICES -->
<section class="container" style="margin-top: 6rem !important;">
<div class="row">
<div class="col-lg-12 d-flex flex-column justify-content-center align-items-center">
<h2 style="color: #212529 !important;">Our Services</h2>
<hr
style="border: 3px solid #AC1015 !important; background-color: #AC1015 !important; width: 80px !important; margin-bottom: 2rem !important;" />
</div>
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4">
<div class="d-flex justify-content-center align-items-center mx-3 my-3"
style="background-color: #1dd1a1 !important; border-radius: 15px !important; height: 80px; width: 80px;">
<img src="assets/icons/cogs.png" class="img-responsive" height="48px" width="48px">
</div>
<h6 class="text-center"
style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;">Odoo
Customization</h6>
</div>
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4">
<div class="d-flex justify-content-center align-items-center mx-3 my-3"
style="background-color: #ff6b6b !important; border-radius: 15px !important; height: 80px; width: 80px;">
<img src="assets/icons/wrench.png" class="img-responsive" height="48px" width="48px">
</div>
<h6 class="text-center"
style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;">Odoo
Implementation</h6>
</div>
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4">
<div class="d-flex justify-content-center align-items-center mx-3 my-3"
style="background-color: #6462CD !important; border-radius: 15px !important; height: 80px; width: 80px;">
<img src="assets/icons/lifebuoy.png" class="img-responsive" height="48px" width="48px">
</div>
<h6 class="text-center"
style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;">Odoo
Support</h6>
</div>
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4">
<div class="d-flex justify-content-center align-items-center mx-3 my-3"
style="background-color: #ffa801 !important; border-radius: 15px !important; height: 80px; width: 80px;">
<img src="assets/icons/user.png" class="img-responsive" height="48px" width="48px">
</div>
<h6 class="text-center"
style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;">Hire
Odoo
Developer</h6>
</div>
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4">
<div class="d-flex justify-content-center align-items-center mx-3 my-3"
style="background-color: #54a0ff !important; border-radius: 15px !important; height: 80px; width: 80px;">
<img src="assets/icons/puzzle.png" class="img-responsive" height="48px" width="48px">
</div>
<h6 class="text-center"
style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;">Odoo
Integration</h6>
</div>
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4">
<div class="d-flex justify-content-center align-items-center mx-3 my-3"
style="background-color: #6d7680 !important; border-radius: 15px !important; height: 80px; width: 80px;">
<img src="assets/icons/update.png" class="img-responsive" height="48px" width="48px">
</div>
<h6 class="text-center"
style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;">Odoo
Migration</h6>
</div>
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4">
<div class="d-flex justify-content-center align-items-center mx-3 my-3"
style="background-color: #786fa6 !important; border-radius: 15px !important; height: 80px; width: 80px;">
<img src="assets/icons/consultation.png" class="img-responsive" height="48px" width="48px">
</div>
<h6 class="text-center"
style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;">Odoo
Consultancy</h6>
</div>
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4">
<div class="d-flex justify-content-center align-items-center mx-3 my-3"
style="background-color: #f8a5c2 !important; border-radius: 15px !important; height: 80px; width: 80px;">
<img src="assets/icons/training.png" class="img-responsive" height="48px" width="48px">
</div>
<h6 class="text-center"
style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;">Odoo
Implementation</h6>
</div>
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4">
<div class="d-flex justify-content-center align-items-center mx-3 my-3"
style="background-color: #e6be26 !important; border-radius: 15px !important; height: 80px; width: 80px;">
<img src="assets/icons/license.png" class="img-responsive" height="48px" width="48px">
</div>
<h6 class="text-center"
style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;">Odoo
Licensing Consultancy</h6>
</div>
</div>
</section>
<!-- END OF END OF OUR SERVICES -->
<!-- OUR INDUSTRIES -->
<section class="container" style="margin-top: 6rem !important;">
<div class="row">
<div class="col-lg-12 d-flex flex-column justify-content-center align-items-center">
<h2 style="color: #212529 !important;">Our Industries</h2>
<hr
style="border: 3px solid #AC1015 !important; background-color: #AC1015 !important; width: 80px !important; margin-bottom: 2rem !important;" />
</div>
<div class="col-lg-3">
<div class="my-4 d-flex flex-column justify-content-center"
style="background-color: #f6f8f9 !important; border-radius: 10px; padding: 2rem !important; height: 250px !important;">
<img src="./assets/icons/trading-black.png" class="img-responsive mb-3" height="48px"
width="48px">
<h5
style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;">
Trading
</h5>
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;">
Easily procure
and
sell your products</p>
</div>
</div>
<div class="col-lg-3">
<div class="my-4 d-flex flex-column justify-content-center"
style="background-color: #f6f8f9 !important; border-radius: 10px; padding: 2rem !important; height: 250px !important;">
<img src="./assets/icons/pos-black.png" class="img-responsive mb-3" height="48px" width="48px">
<h5
style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;">
POS
</h5>
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;">
Easy
configuration
and convivial experience</p>
</div>
</div>
<div class="col-lg-3">
<div class="my-4 d-flex flex-column justify-content-center"
style="background-color: #f6f8f9 !important; border-radius: 10px; padding: 2rem !important; height: 250px !important;">
<img src="./assets/icons/education-black.png" class="img-responsive mb-3" height="48px"
width="48px">
<h5
style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;">
Education
</h5>
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;">
A platform for
educational management</p>
</div>
</div>
<div class="col-lg-3">
<div class="my-4 d-flex flex-column justify-content-center"
style="background-color: #f6f8f9 !important; border-radius: 10px; padding: 2rem !important; height: 250px !important;">
<img src="./assets/icons/manufacturing-black.png" class="img-responsive mb-3" height="48px"
width="48px">
<h5
style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;">
Manufacturing
</h5>
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;">
Plan, track and
schedule your operations</p>
</div>
</div>
<div class="col-lg-3">
<div class="my-4 d-flex flex-column justify-content-center"
style="background-color: #f6f8f9 !important; border-radius: 10px; padding: 2rem !important; height: 250px !important;">
<img src="./assets/icons/ecom-black.png" class="img-responsive mb-3" height="48px" width="48px">
<h5
style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;">
E-commerce &amp; Website
</h5>
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;">
Mobile
friendly,
awe-inspiring product pages</p>
</div>
</div>
<div class="col-lg-3">
<div class="my-4 d-flex flex-column justify-content-center"
style="background-color: #f6f8f9 !important; border-radius: 10px; padding: 2rem !important; height: 250px !important;">
<img src="./assets/icons/service-black.png" class="img-responsive mb-3" height="48px"
width="48px">
<h5
style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;">
Service Management
</h5>
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;">
Keep track of
services and invoice</p>
</div>
</div>
<div class="col-lg-3">
<div class="my-4 d-flex flex-column justify-content-center"
style="background-color: #f6f8f9 !important; border-radius: 10px; padding: 2rem !important; height: 250px !important;">
<img src="./assets/icons/restaurant-black.png" class="img-responsive mb-3" height="48px"
width="48px">
<h5
style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;">
Restaurant
</h5>
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;">
Run your bar or
restaurant methodically</p>
</div>
</div>
<div class="col-lg-3">
<div class="my-4 d-flex flex-column justify-content-center"
style="background-color: #f6f8f9 !important; border-radius: 10px; padding: 2rem !important; height: 250px !important;">
<img src="./assets/icons/hotel-black.png" class="img-responsive mb-3" height="48px"
width="48px">
<h5
style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;">
Hotel Management
</h5>
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;">
An
all-inclusive
hotel management application</p>
</div>
</div>
</div>
</section>
<!-- END OF END OF OUR INDUSTRIES -->
<!-- FOOTER -->
<!-- Footer Section -->
<section class="container" style="margin: 5rem auto 2rem;">
<div class="row" style="max-width:1540px;">
<div class="col-lg-12 d-flex flex-column justify-content-center align-items-center">
<h2 style="color: #212529 !important;">Need Help?</h2>
<hr
style="border: 3px solid #AC1015 !important; background-color: #AC1015 !important; width: 80px !important; margin-bottom: 2rem !important;" />
</div>
</div>
<!-- Contact Cards -->
<div class="row d-flex justify-content-center align-items-center"
style="max-width:1540px; margin: 0 auto 2rem auto;">
<div class="col-lg-12" style="padding: 0rem 3rem 2rem; border-radius: 10px; margin-right: 3rem; ">
<div class="row mt-4">
<div class="col-lg-4">
<a href="mailto:odoo@cybrosys.com" target="_blank" class="btn btn-block mb-2 deep_hover"
style="text-decoration: none; background-color: #4d4d4d; color: #FFF; border-radius: 4px;"><i
class="fa fa-envelope mr-2"></i>odoo@cybrosys.com</a>
</div>
<div class="col-lg-4">
<a href="https://api.WhatsApp.com/send?phone=918606827707" target="_blank"
class="btn btn-block mb-2 deep_hover"
style="text-decoration: none; background-color: #25D366; color: #FFF; border-radius: 4px;"><i
class="fa fa-WhatsApp mr-2"></i>WhatsApp</a>
</div>
<div class="col-lg-4">
<a href="skype:cybrosystechnologies?chat" target="_blank" class="btn btn-block deep_hover"
style="text-decoration: none; background-color: #4d4d4d; color: #FFF; border-radius: 4px;"><i
class="fa fa-envelope mr-2"></i>cybrosystechnologies</a>
</div>
</div>
</div>
</div>
<!-- End of Contact Cards -->
</section>
<!-- Footer -->
<section class="oe_container" style="padding: 2rem 3rem 1rem;">
<div class="row" style="max-width:1540px; margin: 0 auto; margin-right: 3rem; ">
<!-- Logo -->
<div class="col-lg-12 d-flex justify-content-center align-items-center" style="margin-top: 3rem;">
<img src="https://www.cybrosys.com/images/logo.png" width="200px" height="auto" />
</div>
<!-- End of Logo -->
<div class="col-lg-12">
<hr
style="margin-top: 3rem;background: linear-gradient(90deg, rgba(2,0,36,0) 0%, rgba(229,229,229,1) 33%, rgba(229,229,229,1) 58%, rgba(0,212,255,0) 100%); height: 2px; border-style: none;">
<!-- End of Footer Section -->
</div>
</div>
</section>
<!-- END OF FOOTER -->
</div>
</div>

88
customized_barcode_generator/views/barcode_generator_view.xml

@ -0,0 +1,88 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<record model="ir.ui.view" id="barcode_code_form">
<field name="name">barcode.code.form.view</field>
<field name="model">barcode.code</field>
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Barcode code" create="false" delete="false">
<sheet>
<label for="active_check"/>
<field name="active_check"/>
<group>
<group>
<field name="code_for_zero"/>
<field name="code_for_one"/>
<field name="code_for_two"/>
<field name="code_for_three" />
<field name="code_for_four"/>
<field name="code_for_five"/>
<field name="code_for_six"/>
<field name="code_for_seven"/>
<field name="code_for_eight"/>
<field name="code_for_nine"/>
</group>
</group>
</sheet>
</form>
</field>
</record>
<record model="ir.ui.view" id="barcode_code_tree">
<field name="name">barcode.code.tree.view</field>
<field name="model">barcode.code</field>
<field name="type">tree</field>
<field name="arch" type="xml">
<tree string="Barcode code">
<field name="name"/>
<field name="date_check"/>
<field name="active_check"/>
</tree>
</field>
</record>
<record model="ir.actions.act_window" id="action_barcode_code_view">
<field name="name">Barcode Code</field>
<field name="res_model">barcode.code</field>
<field name="view_mode">tree,form</field>
<field name="help" type="html">
<p class="oe_view_nocontent_create">Create new code
</p>
</field>
</record>
<record id="res_config_settings_view_customize_barcode" model="ir.ui.view">
<field name="name">res.config.settings.view.form.customize.barcode</field>
<field name="model">res.config.settings</field>
<field name="priority" eval="100"/>
<field name="inherit_id" ref="account.res_config_settings_view_form" />
<field name="arch" type="xml">
<xpath expr="//field[@name='has_chart_of_accounts']" position="before">
<h2>Product Labels</h2>
<div class="row mt16 o_settings_container">
<div class="col-xs-12 col-md-6 o_setting_box">
<div class="o_setting_left_pane">
<field name="active_standard_price"/>
</div>
<div class="o_setting_right_pane">
<label for="active_standard_price"/>
<div>
<button name="%(customized_barcode_generator.action_barcode_code_view)d" icon="fa-arrow-right"
type="action" string="Barcode code " class="btn-link"
attrs="{'invisible': [('active_standard_price', '=', False)]}"/>
</div>
</div>
</div>
<div class="col-xs-12 col-md-6 o_setting_box">
<div class="o_setting_left_pane">
<field name="active_ref"/>
</div>
<div class="o_setting_right_pane">
<label for="active_ref"/>
</div>
</div>
</div>
</xpath>
</field>
</record>
</odoo>
Loading…
Cancel
Save