Odoo is the world's easiest all-in-one management software. It includes hundreds of business apps:
CRM | e-Commerce | Accounting | Inventory | PoS | Project management | MRP | etc.
From the search bar of product now we can search using name of product, but my need is have to search with name or barcode. we can use advanced search barcode, to search a product using barcode. But i want to use only serch bar not advanced search. As per my knowledge i have to change "name_search" in produc.product. Please provide me that function code. correct me if i am wrong.
There is two way to achive your objective.
1) Keep product name and add barcode into search bar.
For this you have to just add "ean13" field into search view by inheriting product search view.
2) Replace product name with Barcode into search bar.
For this you have to just replace "name" field with "ean13" field into search view by inheriting product search view.
U need to add your field name inside search view in .xml file.Lets consider an example:
<record id="view_my_product_filter" model="ir.ui.view">
<field name="arch" type="xml">
<search string="Search Me">
<field name="name" string="Product Name" />
<field name="my_barcode" string="Barcode"/>
So when you type smething on search bar ,a drop down list will appear. Select from the drop down list(product name,barcode) and hit enter.
Visit below link for better understanding
About This Community
This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.Register
Odoo Training Center
Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.Test it now
|Asked: 8/25/14, 1:27 AM|
|Seen: 2722 times|
|Last updated: 3/28/17, 4:13 AM|