~openerp-dev/openobject-client/duplication_of_ir.filters

« back to all changes in this revision

Viewing changes to bin/widget/view/form_gtk/many2one.py

  • Committer: RGA(OpenERP)
  • Date: 2010-10-12 11:11:19 UTC
  • mfrom: (1564.1.45 trunk)
  • Revision ID: rga@tinyerp.com-20101012111119-jsuwv2erjdxq44us
Merge with trunk

Show diffs side-by-side

added added

removed removed

Lines of Context:
215
215
            self.display(self._view.model, self._view.modelfield)
216
216
            self.ok = True
217
217
        else:
218
 
            search_mode = self.attrs.get('search_mode', 'tree')
219
218
            win = win_search(self.attrs['relation'], sel_multi=False,
220
219
                    ids=map(lambda x: x[0], ids), context=context,
221
 
                    domain=domain, window=self._window,
222
 
                    search_mode=search_mode)
 
220
                    domain=domain, window=self._window)
223
221
            ids = win.go()
224
222
            if ids:
225
223
                name = rpc.session.rpc_exec_auth('/object', 'execute',
261
259
                self.ok = True
262
260
                return True
263
261
 
264
 
            search_mode = self.attrs.get('search_mode', 'tree')
265
 
            win = win_search(self.attrs['relation'], sel_multi=False, ids=map(lambda x: x[0], ids), context=context, domain=domain, parent=self._window, search_mode=search_mode)
 
262
            win = win_search(self.attrs['relation'], sel_multi=False, ids=map(lambda x: x[0], ids), context=context, domain=domain, parent=self._window)
266
263
            ids = win.go()
267
264
            if ids:
268
265
                name = rpc.session.rpc_exec_auth('/object', 'execute', self.attrs['relation'], 'name_get', [ids[0]], rpc.session.context)[0]