← Back to team overview

c2c-oerpscenario team mailing list archive

[Bug 705797] Re: [trunk][account][low] Inversion of two columns in a many2many field

 

Hello Olivier DOSSMANN,

I have merged your branch with the following branch:-
https://code.launchpad.net/~openerp-commiter/openobject-addons/trunk-dev-addons3-mtr1 branch.
Revision ID: mtr@mtr-20110127121721-j3i1np6ku2craczs
Revision no: 4714 

Thanks for your contribution.

Thanks
mtr

** Changed in: openobject-addons
       Status: In Progress => Fix Committed

-- 
You received this bug notification because you are a member of C2C
OERPScenario, which is subscribed to the OpenERP Project Group.
https://bugs.launchpad.net/bugs/705797

Title:
  [trunk][account][low] Inversion of two columns in a many2many field

Status in OpenERP Modules (addons):
  Fix Released

Bug description:
  Addons: revno. 4372

  By browsing the table account_bank_statement_line_move_rel in a database created with the trunk, I see that this table have two columns : 
  - move_id
  - statement_id

  The first should refers to account_move, the second to
  account_bank_statement.

  By using openerp, I have some values inserted into the database. It
  seems that move_id contains values that should be in statement_id and
  inversely.

  In fact it's easy to change this. You just have to go to
  account/account_bank_statement.py#465-467 and change lines :

  'move_ids': fields.many2many('account.move',
      'account_bank_statement_line_move_rel', 'move_id','statement_id',
      'Moves'),

  by :

  'move_ids': fields.many2many('account.move',
      'account_bank_statement_line_move_rel', 'statement_id','move_id',
      'Moves'),

  It's not so important because of ORM methods use (like browse, etc.).
  But imagine someone develop a module which use a sql query like in
  account/account_move_line.py#786-790 but on
  account_bank_statement_line_move_rel ... that will affect the
  developer's result.

  Thanks for advance about this non-critical bug but important for those
  who parses the database and develops modules ;)





References