How to change mag_ prefix in imported sale orders

Created by Jordi Esteve (www.zikzakmedia.com)
Keywords:
mag prefix sale order

A typical customization is change the mag_ prefix added in all the imported sale orders from Magento. It can be done going to the object mapping frame in magento instances, then double click on sale order, double clikc on increment_id field and change in import Python function the 'mgn_' text.

I do not know if this has collateral effects (e.g. 'mag_' text is hardcoded and used in other places in the connector). I see the 'mag_' prefix is used in magentoerpconnect/sale.py:

line 136: 'mag_oder' I think this is for addresses from sale orders buying as a guest customer and is a Magento computed value that must not be changed.

line 232 and 234: 'mag_'+payment['payment_id'] is used as a payment reference in OpenERP. I think it does not matter if it differs from the sale order prefix. Anyway, it would be nice if it could be easily customize like the sale order prefix.