跳至内容
菜单
此问题已终结
1 回复
712 查看

I need to do a very basic ZPL label that has the item name and the customer name when printing labels from the delivery ticket.  


Basically I gutted the code on the Product Label to display the item name, but I don't know how to bring in the customer name. 


I've tried everything I can think of to no avail. 


Here's the code I have with just the item name.  So if anyone has any suggestions on what to add to get the company name on there it would be much appreciated!  


<t t-name="stock.label_product_product_view">

    <t t-foreach="quantity.items()" t-as="barcode_and_qty_by_product">

                <t t-set="product" t-value="barcode_and_qty_by_product[0]"/>

                <t t-foreach="barcode_and_qty_by_product[1]" t-as="product_info">

                    <t t-set="barcode" t-value="product_info['barcode']"/>

                    <t t-set="currency_id" t-value="pricelist.currency_id or product.currency_id"/>

                    <t t-foreach="range(product_info['quantity'])" t-as="qty">

                        <t t-translation="off">

^XA


^CFJ,250

^FO50,100^FD<t t-out="product_info['display_name_markup']"/>^FS


^XZ

                        </t>

                    </t>

                </t>

            </t>

        </t>

形象
丢弃
最佳答案

I've had success using

<t t-esc="value"/>

to get values from the records in other labels, including zpl labels

形象
丢弃
相关帖文 回复 查看 活动
0
1月 24
1062
0
6月 22
1719
0
1月 21
2831
0
11月 19
4884
0
3月 25
724