Odoo Help


OpenERP 7 search box showing long patient record list how to set min limit

on 5/10/13, 9:39 AM 3,144 views

In openerp 7 i have more than 2000 patient records in search box entered letter 'a' its shows all the record how to set minimum limit to search record which method need to override in Openerp 7 version?

<record id="view_intake_filter" model="ir.ui.view">
          <field name="name">intake.filter</field>
          <field name="model">patinet.form</field>
          <field name="type">search</field>
          <field name="arch" type="xml">
          <search string="patient Intake">
               <field name="patient_id"/>
On 5/10/13, 2:47 PM

Add <field name="limit">100</field> to your action


Override the search method

def search(self, cr, uid, args, offset=0, limit=None, order=None, context=None, count=False):
    limit = 100
    return super(patinet_form, self).search(cr, uid, args, offset, limit, order, context, count)

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.


Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

0 follower(s)


Asked: 5/10/13, 9:39 AM
Seen: 3144 times
Last updated: 3/16/15, 8:10 AM