Ir al contenido
Menú
Se marcó esta pregunta

in the inventory app in ver. 16 i would like to print inventory labels.

these label i would like to print would be from the product items.

once printed they can show the product picture, and brief desc. and price  better yet and bar code to say bring item to counter scan it and it will tell me how many i have left and cost.

how can this be done?

thank you in advance..

label printer is printing on like 2x3" about size of business card or baseball card size



Avatar
Descartar
Mejor respuesta

Hi Brent,

To create a barcode product label in Odoo there are two common ways:

  1. Develop own label (by yourself or with Odoo developers);
  2. Use the app that allows to print and design own labels.

The first approach is not so flexible because after the label creation, if you want to change the label you will need to go into code and change something there.

The second way is more easy and convenient if you use some Odoo module, that is developed at the high level and covered with support and assistance.

We into the product label development since 2017, in the last year, we built our Odoo Product Label Builder. It allows designing and creating your own labels by Odoo UI. You can watch details in this YouTube video.


With the Product Label Builder, you can put into labels your product data and other information from various standard Odoo apps. In this case, you need additional extensions in addition to the Product Label Builder app. The list of these extensions is the following, and you can choose ones that you need:

  • Stock Product Labels — to print from the Stock documents and use its data on your label templates: 
    • Stock Transfers (stock.picking), 
    • Stock Inventory Adjustments (stock.quant),
    • Stock Lots (stock.lot), 
    • Stock Packages (stock.quant.package), 
    • Stock Scrap (stock.scrap).
  • Product Packaging Labels — to print from Product Packaging (product.packaging) and use its data on your label templates.
  • Purchase Product Labels — to print from Purchase Orders (purchaser.order) and use its data on your label templates.
  • MRP Product Labels — to print from Manufacturing Orders (mrp.production) and use its data on your label templates.
  • MRP Workorder Labels — to print from Manufacturing Work Orders (mrp.workorder) and use its data on your label templates (Odoo Enterprise feature only).
  • Repair Product Labels — to print from Repair Orders (repair.order) and use its data on your label templates.
  • Maintenance Barcode Labels — to print from the Maintenance documents and use its data on your label templates: 
    • Maintenance Requests (maintenance.request),
    • Maintenance Equipments (maintenance.equipment).
  • Sales Product Labels  — to print from Sales Orders (sale.order) and use its data on your label templates (in the development at the current moment).


If you need additional assistance or information, please contact us.


Best regards, Yurii Razumovskyi.

Company Garazd CreationOdoo solutions for e-Commerce, SEO, Data Feeds, Website Tracking, Marketing and Analytics integrations, Product Label designing and printing.

https://garazd.biz  |  Our solutions on Odoo Apps

Avatar
Descartar
Autor Mejor respuesta

thank you for your input and time.,

this looks just about like what i am trying to complete.

i may contact you Monday in regard to maybe a little customization.

thank you i think i got your direct contact info..

thanks to all that read and responded im trying all

Avatar
Descartar
Mejor respuesta

Hi,

Try to Inherits the pdf template

<?xml version="1.0" encoding="UTF-8"?>
<odoo>
    <data>
        <!-- Inherit the existing label template -->
<template id="label_product_product_view" inherit_id="stock.label_product_product_view">
            <xpath expr="//t" position="after">
                <!-- Add product cost -->
<t t-foreach="range(product_info['quantity'])" t-as="qty">
                    <t t-translation="off">
                        ^FT100,185^A0N,30,24^FDCost: <t t-esc="product.standard_price" t-options='{"widget": "float", "precision": 2}'/>^FS
                    </t>
                </t>
                <!-- Add quantity on hand -->
<t t-foreach="range(product_info['quantity'])" t-as="qty">
                    <t t-translation="off">
^FT100,220^A0N,30,24^FDQty: <t t-esc="product.qty_available"/>^FS
                    </t>
                </t>
            </xpath>
        </template>

        <!-- Define Odoo report -->
        <record id="label_product_product" model="ir.actions.report">
            <field name="name">Product Label (ZPL)</field>
<field name="model">product.product</field>
<field name="report_type">qweb-text</field>
<field name="report_name">stock.label_product_product_view_inherited</field>
<field name="report_file">stock.label_product_product_view_inherited</field>
            <field name="binding_model_id" eval="False"/>
<field name="binding_type">report</field>
        </record>
    </data>
</odoo>


if you need to change the print report size, please add a new style in the print label wizard action and add a new paper format to it

class ProductLabel(models.Model):
    _inherit = 'product.product'

    print_format = fields.Selection([
        ('dymo', 'Dymo'),
        ('2x7xprice', '2 x 7 with price'),
        ('4x7xprice', '4 x 7 with price'),
        ('4x12', '4 x 12'),
        ('4x12xprice', '4 x 12 with price'),
        ('2x3', '2 x 3 (Business Card Size)')  # New size option
    ], string="Format", default='2x7xprice', required=True)

<!-- Update existing template to handle different sizes -->
<template id="label_product_product_view" inherit_id="stock.label_product_product_view">
<xpath expr="//field[@name='print_format']/selection[@name='print_format']/value[last()]" position="after">
                <value>2x3</value>
            </xpath>
        </template>

        <!-- Define Odoo report for 2x3" label size -->
        <record id="label_product_product_2x3" model="ir.actions.report">
            <field name="name">Product Label 2x3 (ZPL)</field>
<field name="model">product.product</field>
<field name="report_type">qweb-text</field>
<field name="report_name">stock.label_product_product_view_2x3</field>
<field name="report_file">stock.label_product_product_view_2x3</field>
            <field name="binding_model_id" eval="False"/>
<field name="binding_type">report</field>
        </record>



Hope it helps

Avatar
Descartar
Publicaciones relacionadas Respuestas Vistas Actividad
3
mar 24
3025
5
dic 23
17984
2
mar 15
7169
1
jul 25
182
5
mar 25
5726