Skip to Content
Meniu
Trebuie să fiți înregistrat pentru a interacționa cu comunitatea.
Această întrebare a fost marcată
1 Răspunde
15586 Vizualizări

I have this module I use to attach certain information to stock.production.lot. How should I make these fields searchable in the main search bar? i.e. if I wanted to find a product that has an associated unique Serial Number, that has associated Toner Level (x_toner) field set to 'Full'?

Can someone point me to good examples or some specific reading?

from odoo import models, fields, api

class x_wh(models.Model):
_inherit = 'stock.production.lot'

x_toner = fields.Char(
'Toner Level', index=True
)
x_print_count = fields.Integer(
'Print Count', index=True
)
x_description = fields.Text(
'Description'
)
x_condition = fields.Char(
'Product Condition', index=True
)





Imagine profil
Abandonează
Cel mai bun răspuns

Hi Zendo..!


You can please refer to this link, you can get the answer.


https://www.odoo.com/forum/help-1/question/making-a-custom-field-searchable-w-o-advanced-search-55299


Thanks
Imagine profil
Abandonează
Autor

Thanks, Nikhil, that was what I needed

Related Posts Răspunsuri Vizualizări Activitate
0
mai 21
3060
1
feb. 19
2721
0
dec. 18
2995
0
iul. 18
3335
1
mai 18
4339