[Expired for OpenERP Server because there has been no activity for 60
days.]

** Changed in: openobject-server
       Status: Incomplete => Expired

-- 
You received this bug notification because you are a member of OpenERP
CTP, which is subscribed to OpenERP Server.
https://bugs.launchpad.net/bugs/776458

Title:
  missing default on m2o field, widget=selection

Status in OpenERP Server:
  Expired

Bug description:
  Hi, I'm reporting this in openobject-server as I suspect it is a
  general framework issue. (v6)

  If we take a m2o field that has a 'selection' widget in the view, for
  example the shop in the sale order, then if there are i.e. two shops,
  but the first one can't be correctly visualized because of multi-
  company rules or other things, then by default we get an empty value,
  instead of the first usable one.

  In that case the first shop cannot be visualized because of i.e.
  multicompany rules, I expect to see the second one, not an empty
  string.

  In that specific case, a workaround is adding

  _defaults = {
          'shop_id': lambda self, cr, uid, context: 
self.pool.get('sale.shop').search(cr, uid, [])[0],
  }

  to the sale.order definition. However this seems to be a workaround
  for a bug that does exist somewhere in the framework.

  thanks!

To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-server/+bug/776458/+subscriptions

_______________________________________________
Mailing list: https://launchpad.net/~openerp-dev-gtk
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~openerp-dev-gtk
More help   : https://help.launchpad.net/ListHelp

Reply via email to