diff --git a/addons/account_followup/__openerp__.py b/addons/account_followup/__openerp__.py index 61e9ea2d4ae..f85ecc4ee90 100644 --- a/addons/account_followup/__openerp__.py +++ b/addons/account_followup/__openerp__.py @@ -29,7 +29,7 @@ Module to automate letters for unpaid invoices, with multi-level recalls. You can define your multiple levels of recall through the menu: --------------------------------------------------------------- - Configuration / Follow-Up Levels + Configuration / Follow-up / Follow-up Levels Once it is defined, you can automatically print recalls every day through simply clicking on the menu: ------------------------------------------------------------------------------------------------------ @@ -55,6 +55,7 @@ Note that if you want to check the follow-up level for a given partner/account e 'account_followup_view.xml', 'account_followup_customers.xml', 'wizard/account_followup_print_view.xml', + 'res_config_view.xml', 'views/report_followup.xml', 'account_followup_reports.xml' ], diff --git a/addons/account_followup/account_followup.py b/addons/account_followup/account_followup.py index eae361913ad..820a179efdb 100644 --- a/addons/account_followup/account_followup.py +++ b/addons/account_followup/account_followup.py @@ -30,7 +30,7 @@ class followup(osv.osv): _columns = { 'followup_line': fields.one2many('account_followup.followup.line', 'followup_id', 'Follow-up'), 'company_id': fields.many2one('res.company', 'Company', required=True), - 'name': fields.related('company_id', 'name', string = "Name"), + 'name': fields.related('company_id', 'name', string = "Name", readonly=True, type="char"), } _defaults = { 'company_id': lambda s, cr, uid, c: s.pool.get('res.company')._company_default_get(cr, uid, 'account_followup.followup', context=c), @@ -479,4 +479,20 @@ class res_partner(osv.osv): fnct_search=_payment_earliest_date_search), } + +class account_config_settings(osv.TransientModel): + _name = 'account.config.settings' + _inherit = 'account.config.settings' + + def open_followup_level_form(self, cr, uid, ids, context=None): + res_ids = self.pool.get('account_followup.followup').search(cr, uid, [], context=context) + + return { + 'type': 'ir.actions.act_window', + 'name': 'Payment Follow-ups', + 'res_model': 'account_followup.followup', + 'res_id': res_ids and res_ids[0] or False, + 'view_mode': 'form,tree', + } + # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/account_followup/account_followup_view.xml b/addons/account_followup/account_followup_view.xml index 57f71566db0..94b4f6dce9a 100644 --- a/addons/account_followup/account_followup_view.xml +++ b/addons/account_followup/account_followup_view.xml @@ -71,7 +71,9 @@ account_followup.followup
-

+

+