[7.0] Bank statement wrong currency

Bug #1359711 reported by Kinner Vachhani
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenERP Community Backports (Addons)
New
Undecided
Unassigned

Bug Description

Hi,

The bank statement currency is taking user company currency which is wrong. Ideally it should take currency from journal.

Wrong code:

        res_users_obj = self.pool.get('res.users')
        default_currency = res_users_obj.browse(cursor, user,
                user, context=context).company_id.currency_id
        for statement in self.browse(cursor, user, ids, context=context):
            currency = statement.journal_id.currency
            if not currency:
                currency = default_currency

Recommendation
          currency = statement.journal_id.currency or statement.journal_id.company_id.currency_id

summary: - [7.0] Bank statement currency is wrong
+ [7.0] Bank statement wrong currency
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.