diff --git a/addons/crm/crm_lead.py b/addons/crm/crm_lead.py index ddfdb05ca66..fff47205582 100644 --- a/addons/crm/crm_lead.py +++ b/addons/crm/crm_lead.py @@ -27,13 +27,15 @@ import time import tools from tools.translate import _ +from base.res.res_partner import format_address + CRM_LEAD_PENDING_STATES = ( crm.AVAILABLE_STATES[2][0], # Cancelled crm.AVAILABLE_STATES[3][0], # Done crm.AVAILABLE_STATES[4][0], # Pending ) -class crm_lead(base_stage, osv.osv): +class crm_lead(base_stage, format_address, osv.osv): """ CRM Lead Case """ _name = "crm.lead" _description = "Lead/Opportunity" @@ -105,6 +107,12 @@ class crm_lead(base_stage, osv.osv): return result, fold + def fields_view_get(self, cr, user, view_id=None, view_type='form', context=None, toolbar=False, submenu=False): + res = super(crm_lead,self).fields_view_get(cr, user, view_id, view_type, context, toolbar=toolbar, submenu=submenu) + if view_type == 'form': + res['arch'] = self.fields_view_get_address(cr, user, res['arch'], context=context) + return res + _group_by_full = { 'stage_id': _read_group_stage_ids } diff --git a/addons/sale/wizard/sale_make_invoice_advance.py b/addons/sale/wizard/sale_make_invoice_advance.py index a2c45bead62..ee3aa942b7b 100644 --- a/addons/sale/wizard/sale_make_invoice_advance.py +++ b/addons/sale/wizard/sale_make_invoice_advance.py @@ -30,7 +30,7 @@ class sale_advance_payment_inv(osv.osv_memory): 'advance_payment_method':fields.selection( [('all', 'Invoice the whole sale order'), ('percentage','Percentage'), ('fixed','Fixed price (deposit)'), ('lines', 'Some order lines')], - 'Invoice Method', required=True, + 'What do you want to invoice?', required=True, help="""Use All to create the final invoice. Use Percentage to invoice a percentage of the total amount. Use Fixed Price to invoice a specific amound in advance.