diff --git a/addons/account_followup/__openerp__.py b/addons/account_followup/__openerp__.py index ae6fb8e4fce..3f62a675c2a 100644 --- a/addons/account_followup/__openerp__.py +++ b/addons/account_followup/__openerp__.py @@ -50,7 +50,8 @@ 'wizard/account_followup_print_view.xml', 'report/account_followup_report.xml', 'account_followup_view.xml', - 'account_followup_data.xml' + 'account_followup_data.xml', + 'security/account_followup_security.xml' ], 'demo_xml': ['account_followup_demo.xml'], 'test': ['test/account_followup.yml'], diff --git a/addons/account_followup/security/account_followup_security.xml b/addons/account_followup/security/account_followup_security.xml new file mode 100644 index 00000000000..aa524b11e77 --- /dev/null +++ b/addons/account_followup/security/account_followup_security.xml @@ -0,0 +1,21 @@ + + + + + + Account Followup Rule + + + ['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])] + + + + Account Followup Statistics by Partner Rule + + + ['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])] + + + + + diff --git a/addons/account_followup/wizard/account_followup_print.py b/addons/account_followup/wizard/account_followup_print.py index 5d9c2da860f..580477f481f 100644 --- a/addons/account_followup/wizard/account_followup_print.py +++ b/addons/account_followup/wizard/account_followup_print.py @@ -115,7 +115,7 @@ class account_followup_print_all(osv.osv_memory): _name = 'account.followup.print.all' _description = 'Print Followup & Send Mail to Customers' _columns = { - 'partner_ids': fields.many2many('account_followup.stat.by.partner', 'partner_stat_rel', 'osv_memory_id', 'partner_id', 'Partners', required=True, domain="[('account_id.type', '=', 'receivable'), ('account_id.reconcile', '=', True), ('reconcile_id','=', False), ('state', '!=', 'draft'), ('account_id.active', '=' True), ('debit', '>', 0)]"), + 'partner_ids': fields.many2many('account_followup.stat.by.partner', 'partner_stat_rel', 'osv_memory_id', 'partner_id', 'Partners', required=True), 'email_conf': fields.boolean('Send email confirmation'), 'email_subject': fields.char('Email Subject', size=64), 'partner_lang': fields.boolean('Send Email in Partner Language', help='Do not change message text, if you want to send email in partner language, or configure from company'),