Scheduled failure Logs and keep days for email .

This commit is contained in:
kunjal patel 2018-02-08 09:21:46 +00:00 committed by Parthiv Patel
parent 5d8eb4fb9f
commit eccbea79bb
13 changed files with 257 additions and 106 deletions

View File

@ -13,6 +13,19 @@
<field eval="False" name="doall"/>
</record>
<record forcecreate="True" id="ir_cron_mail_unlink" model="ir.cron">
<field name="name">Mail: Email Unlink</field>
<field name="model_id" ref="model_mail_mail"/>
<field name="state">code</field>
<field name="code">model.process_email_unlink()</field>
<field name="user_id" ref="base.user_root"/>
<field name="interval_number">1</field>
<field name="interval_type">days</field>
<field name="numbercall">-1</field>
<field eval="False" name="doall"/>
</record>
<record id="ir_cron_module_update_notification" model="ir.cron">
<field name="name">Publisher: Update Notification</field>
<field name="model_id" ref="model_publisher_warranty_contract"/>

View File

@ -50,12 +50,31 @@ class MailMail(models.Model):
auto_delete = fields.Boolean(
'Auto Delete',
help="Permanently delete this email after sending it, to save space")
keep_days = fields.Integer('Keep days', default=-1,
help="This value defines the no. of days "
"the emails should be recorded "
"in the system: \n -1 = Email will be deleted "
"immediately once it is send \n greater than 0 = Email "
"will be deleted after "
"the no. of days are met.")
delete_date = fields.Date(compute='_compute_delete_on_date',
string='Delete on.', store=True)
failure_reason = fields.Text(
'Failure Reason', readonly=1,
help="Failure reason. This is usually the exception thrown by the email server, stored to ease the debugging of mailing issues.")
scheduled_date = fields.Char('Scheduled Send Date',
help="If set, the queue manager will send the email after the date. If not set, the email will be send as soon as possible.")
@api.depends('keep_days')
def _compute_delete_on_date(self):
mail_date = fields.Datetime.from_string(self.date)
if self.keep_days > 0:
delete_on = mail_date + datetime.timedelta(days=self.keep_days)
self.delete_date = delete_on
else:
self.delete_date = mail_date.date()
@api.model
def create(self, values):
# notification field: if not set, set if mail comes from an existing mail.message
@ -89,6 +108,12 @@ class MailMail(models.Model):
def cancel(self):
return self.write({'state': 'cancel'})
@api.model
def process_email_unlink(self):
mail_ids = self.sudo().search([('delete_date', '=', datetime.datetime.now().date())])
mail_ids.filtered('auto_delete').unlink()
@api.model
def process_email_queue(self, ids=None):
"""Send immediately queued messages, committing after each
@ -146,6 +171,8 @@ class MailMail(models.Model):
'email_status': 'exception',
})
if mail_sent:
if self.keep_days > 0:
return True
self.sudo().filtered(lambda self: self.auto_delete).unlink()
return True
@ -254,7 +281,8 @@ class MailMail(models.Model):
try:
mail = self.browse(mail_id)
if mail.state != 'outgoing':
if mail.state != 'exception' and mail.auto_delete:
if mail.state != 'exception' and mail.auto_delete and \
mail.keep_days < 0:
mail.sudo().unlink()
continue
# TDE note: remove me when model_id field is present on mail.message - done here to avoid doing it multiple times in the sub method

View File

@ -176,6 +176,13 @@ class MailTemplate(models.Model):
help="You may attach files to this template, to be added to all "
"emails created from this template")
auto_delete = fields.Boolean('Auto Delete', default=True, help="Permanently delete this email after sending it, to save space")
keep_days = fields.Integer('Keep days', default=-1,
help="This value defines the no. of days "
"the emails should be recorded "
"in the system: \n -1 = Email will be deleted "
"immediately once it is send \n greater than 0 = Email "
"will be deleted after "
"the no. of days are met.")
# Fake fields used to implement the placeholder assistant
model_object_field = fields.Many2one('ir.model.fields', string="Field",
@ -201,6 +208,14 @@ class MailTemplate(models.Model):
else:
self.model = False
@api.onchange('mail_server_id')
def onchange_mail_server_id(self):
if self.mail_server_id and self.mail_server_id.keep_days > 0 \
and self.keep_days < 0:
self.keep_days = self.mail_server_id.keep_days
else:
self.keep_days = -1
def build_expression(self, field_name, sub_field_name, null_value):
"""Returns a placeholder expression for use in a template field,
based on the values provided in the placeholder assistant.
@ -493,6 +508,7 @@ class MailTemplate(models.Model):
values.update(
mail_server_id=template.mail_server_id.id or False,
auto_delete=template.auto_delete,
keep_days=template.keep_days,
model=template.model,
res_id=res_id or False,
attachment_ids=[attach.id for attach in template.attachment_ids],

View File

@ -105,6 +105,7 @@ class Partner(models.Model):
'mail_message_id': message.id,
'mail_server_id': message.mail_server_id.id,
'auto_delete': self._context.get('mail_auto_delete', True),
'keep_days': self._context.get('mail_keep_days', -1),
'references': references,
}
mail_values.update(custom_values)

Binary file not shown.

Before

Width:  |  Height:  |  Size: 556 B

After

Width:  |  Height:  |  Size: 3.2 KiB

View File

@ -37,6 +37,8 @@
<group>
<group string="Status">
<field name="auto_delete"/>
<field name="keep_days"/>
<field name="delete_date"/>
<field name="notification"/>
<field name="message_type"/>
<field name="mail_server_id"/>

View File

@ -67,6 +67,7 @@
<field name="lang"/>
<field name="mail_server_id"/>
<field name="auto_delete"/>
<field name="keep_days"/>
<field name="report_template" domain="[('model','=',model)]"/>
<field name="report_name" attrs="{'invisible':[('report_template','=',False)]}"/>
</group>

View File

@ -117,6 +117,13 @@ class MailComposer(models.TransientModel):
# mass mode options
notify = fields.Boolean('Notify followers', help='Notify followers of the document (mass post only)')
auto_delete = fields.Boolean('Delete Emails', help='Delete sent emails (mass mailing only)')
keep_days = fields.Integer('Keep days', default=-1,
help="This value defines the no. of days "
"the emails should be recorded "
"in the system: \n -1 = Email will be deleted "
"immediately once it is send \n greater than 0 = Email "
"will be deleted after "
"the no. of days are met.")
auto_delete_message = fields.Boolean('Delete Message Copy', help='Do not keep a copy of the email in the document communication history (mass mailing only)')
template_id = fields.Many2one(
'mail.template', 'Use template', index=True,
@ -220,7 +227,8 @@ class MailComposer(models.TransientModel):
# template user_signature is added when generating body_html
# mass mailing: use template auto_delete value -> note, for emails mass mailing only
Mail = Mail.with_context(mail_notify_user_signature=False)
ActiveModel = ActiveModel.with_context(mail_notify_user_signature=False, mail_auto_delete=wizard.template_id.auto_delete)
ActiveModel = ActiveModel.with_context(mail_notify_user_signature=False, mail_auto_delete=wizard.template_id.auto_delete,
mail_keep_days=wizard.template_id.keep_days)
if not hasattr(ActiveModel, 'message_post'):
ActiveModel = self.env['mail.thread'].with_context(thread_model=wizard.model)
if wizard.composition_mode == 'mass_post':
@ -305,6 +313,8 @@ class MailComposer(models.TransientModel):
# auto deletion of mail_mail
if self.auto_delete or self.template_id.auto_delete:
mail_values['auto_delete'] = True
mail_values['keep_days'] = \
self.keep_days or self.template_id.keep_days
# rendered values using template
email_dict = rendered_values[res_id]
mail_values['partner_ids'] += email_dict.pop('partner_ids', [])

View File

@ -53,7 +53,9 @@ class ir_cron(models.Model):
cron_name = fields.Char('Name', related='ir_actions_server_id.name', store=True)
user_id = fields.Many2one('res.users', string='Scheduler User', default=lambda self: self.env.user, required=True)
active = fields.Boolean(default=True)
fail = fields.Boolean('Failer Log', default=True)
interval_number = fields.Integer(default=1, help="Repeat every x.")
total_fail = fields.Integer('Total Fail')
interval_type = fields.Selection([('minutes', 'Minutes'),
('hours', 'Hours'),
('days', 'Days'),
@ -76,14 +78,24 @@ class ir_cron(models.Model):
return True
@api.model
def _handle_callback_exception(self, cron_name, server_action_id, job_id, job_exception):
def _handle_callback_exception(self, cron_name, server_action_id, job_id, job_exception, cron_cr):
""" Method called when an exception is raised by a job.
Simply logs the exception and rollback the transaction. """
self._cr.rollback()
cron_id = self.browse(job_id)
if cron_id.fail:
self.env['ir.cronjob.logs'].create(
{'cron_status': 'fail',
'name': cron_id.name + ' - ' + str(datetime.now().date()),
'start_date': datetime.now(),
'log': str(job_exception)})
query = """UPDATE ir_cron set total_fail=%s where id=%s""" % (
(cron_id.total_fail or 0) + 1, cron_id.id)
cron_cr.execute(query)
@api.model
def _callback(self, cron_name, server_action_id, job_id):
def _callback(self, cron_name, server_action_id, job_id, cron_cr):
""" Run the method associated to a given job. It takes care of logging
and exception handling. Note that the user running the server action
is the user calling this method. """
@ -107,7 +119,7 @@ class ir_cron(models.Model):
self.pool.reset_changes()
_logger.exception("Call from cron %s for server action #%s failed in Job #%s",
cron_name, server_action_id, job_id)
self._handle_callback_exception(cron_name, server_action_id, job_id, e)
self._handle_callback_exception(cron_name, server_action_id, job_id, e, cron_cr)
@classmethod
def _process_job(cls, job_cr, job, cron_cr):
@ -134,7 +146,7 @@ class ir_cron(models.Model):
if numbercall > 0:
numbercall -= 1
if not ok or job['doall']:
cron._callback(job['cron_name'], job['ir_actions_server_id'], job['id'])
cron._callback(job['cron_name'], job['ir_actions_server_id'], job['id'], cron_cr)
if numbercall:
nextcall += _intervalTypes[job['interval_type']](job['interval_number'])
ok = True
@ -309,3 +321,15 @@ class ir_cron(models.Model):
def toggle(self, model, domain):
active = bool(self.env[model].search_count(domain))
return self.try_write({'active': active})
class ScheduledLogs(models.Model):
_name = 'ir.cronjob.logs'
name = fields.Char("Name", readonly=True, track_visibility='always')
object_name = fields.Char(string="Object", readonly=True, track_visibility='always')
start_date = fields.Datetime("Start Date", readonly=True)
cron_id = fields.Many2one("ir.cron", "Cron", readonly=True, track_visibility='always')
cron_status = fields.Selection([('fail', 'Fail'), ('success', 'Success')],
'Status', readonly=True)
log = fields.Text("Logs", readonly=True, track_visibility='always')

View File

@ -32,6 +32,10 @@
<field name="priority"/>
<field name="doall"/>
</group>
<group>
<field name="fail"/>
<field name="total_fail"/>
</group>
</xpath>
</field>
</record>
@ -86,4 +90,53 @@
</record>
<menuitem id="menu_ir_cron_act" action="ir_cron_act" parent="base.menu_automation"/>
<record id="cronlogs_form_view" model="ir.ui.view">
<field name="name">ir.cronjob.logs.form</field>
<field name="model">ir.cronjob.logs</field>
<field name="mode">primary</field>
<field name="arch" type="xml">
<form string="Logs">
<sheet string="Logs">
<group>
<group>
<field name="name"/>
</group>
<group>
<field name="start_date"/>
<field name="cron_status"/>
</group>
</group>
<notebook>
<page string="Error Log">
<field name="log"/>
</page>
</notebook>
</sheet>
</form>
</field>
</record>
<record model="ir.ui.view" id="cronjob_tree_view">
<field name="name">ir.cronjob.logs.tree</field>
<field name="model">ir.cronjob.logs</field>
<field name="arch" type="xml">
<tree string="Logs">
<field name="name"/>
<field name="start_date"/>
<field name="cron_status"/>
</tree>
</field>
</record>
<record id="ir_cronjob_act_logs" model="ir.actions.act_window">
<field name="name">Scheduled Logs</field>
<field name="res_model">ir.cronjob.logs</field>
<field name="view_type">form</field>
<field name="view_mode">form,tree</field>
<field name="view_id" ref="cronjob_tree_view"/>
</record>
<menuitem id="menu_ir_cronjob_logs" action="ir_cronjob_act_logs" parent="base.menu_automation"/>
</flectra>

View File

@ -149,6 +149,7 @@ class IrMailServer(models.Model):
sequence = fields.Integer(string='Priority', default=10, help="When no specific mail server is requested for a mail, the highest priority one "
"is used. Default priority is 10 (smaller number = higher priority)")
active = fields.Boolean(default=True)
keep_days = fields.Integer('Keep days', default=-1)
@api.multi
def name_get(self):

View File

@ -14,6 +14,7 @@
<field name="smtp_host"/>
<field name="smtp_port"/>
<field name="smtp_debug" groups="base.group_no_one"/>
<field name="keep_days"/>
</group>
<group string="Security and Authentication" colspan="4">
<field name="smtp_encryption"/>

View File

@ -1,100 +1,101 @@
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
"access_ir_attachment_all","ir_attachment all","model_ir_attachment",,1,0,0,0
"access_ir_attachment_group_user","ir_attachment group_user","model_ir_attachment","group_user",1,1,1,1
"access_ir_attachment_portal","ir.attachment.portal","model_ir_attachment","group_portal",1,0,1,0
"access_ir_cron_group_cron","ir_cron group_cron","model_ir_cron","group_system",1,1,1,1
"access_ir_exports_group_system","ir_exports group_system","model_ir_exports","base.group_user",1,1,1,1
"access_ir_exports_line_group_system","ir_exports_line group_system","model_ir_exports_line","base.group_user",1,1,1,1
"access_ir_model_group_erp_manager","ir_model group_erp_manager","model_ir_model","group_erp_manager",1,1,1,1
"access_ir_model_constraint_group_erp_manager","ir_model_constraint group_erp_manager","model_ir_model_constraint","group_erp_manager",1,1,1,1
"access_ir_model_relation_group_erp_manager","ir_model_relation group_erp_manager","model_ir_model_relation","group_erp_manager",1,1,1,1
"access_ir_model_access_group_erp_manager","ir_model_access_group_erp_manager","model_ir_model_access","group_erp_manager",1,1,1,1
"access_ir_model_data_group_erp_manager","ir_model_data group_erp_manager","model_ir_model_data","group_erp_manager",1,1,1,1
"access_ir_model_fields_group_erp_manager","ir_model_fields group_erp_manager","model_ir_model_fields","group_erp_manager",1,1,1,1
"access_ir_model_user","ir_model_all","model_ir_model",base.group_user,1,0,0,0
"access_ir_model_data_user","ir_model_data user","model_ir_model_data",base.group_user,1,0,1,0
"access_ir_model_fields_user","ir_model_fields all","model_ir_model_fields",base.group_user,1,0,0,0
"access_ir_module_category_group_user","ir_module_category group_user","model_ir_module_category","group_erp_manager",1,0,0,0
"access_ir_module_module_group_user","ir_module_module group_user","model_ir_module_module","group_system",1,1,1,1
"access_ir_module_module_dependency_group_system","ir_module_module_dependency group_system","model_ir_module_module_dependency","group_system",1,1,1,1
"access_ir_module_module_exclusion_group_system","ir_module_module_exclusion group_system","model_ir_module_module_exclusion","group_system",1,1,1,1
"access_ir_property_group_user","ir_property group_user","model_ir_property",,1,0,0,0
"access_ir_property_group_user_manager","ir_property group_manager","model_ir_property","base.group_partner_manager",1,1,1,0
"access_ir_rule_group_erp_manager","ir_rule group_erp_manager","model_ir_rule","group_erp_manager",1,1,1,1
"access_ir_sequence_group_user","ir_sequence group_user","model_ir_sequence","group_user",1,0,0,0
"access_ir_sequence_group_system","ir_sequence group_system","model_ir_sequence","group_system",1,1,1,1
"access_ir_sequence_date_range_group_user","ir_sequence_date_range group_user","model_ir_sequence_date_range","group_user",1,0,0,0
"access_ir_sequence_date_range_group_system","ir_sequence_date_range group_system","model_ir_sequence_date_range","group_system",1,1,1,1
"access_ir_translation_all","ir_translation all","model_ir_translation","group_user",1,1,1,1
"access_ir_translation_group_system","ir_translation group_system","model_ir_translation","group_system",1,1,1,1
"access_ir_ui_menu_group_user","ir_ui_menu group_user","model_ir_ui_menu",base.group_user,1,0,0,0
"access_ir_ui_menu_group_system","ir_ui_menu group_system","model_ir_ui_menu","group_system",1,1,1,1
"access_ir_ui_view_group_user","ir_ui_view group_user","model_ir_ui_view",,1,0,0,0
"access_ir_ui_view_group_system","ir_ui_view group_system","model_ir_ui_view","group_system",1,1,1,1
"access_ir_ui_view_custom_group_user","ir_ui_view_custom_group_user","model_ir_ui_view_custom",,1,1,1,1
"access_ir_default_all","ir_default all","model_ir_default",,1,0,0,0
"access_ir_default_group_user","ir_default group_user","model_ir_default","group_user",1,1,1,1
"access_ir_default_group_system","ir_default group_system","model_ir_default","group_system",1,1,1,1
"access_res_company_group_erp_manager","res_company group_erp_manager","model_res_company","group_erp_manager",1,1,1,1
"access_res_company_group_user","res_company group_user","model_res_company",,1,0,0,0
"access_res_country_group_all","res_country group_user_all","model_res_country",,1,0,0,0
"access_res_country_state_group_all","res_country_state group_user_all","model_res_country_state",,1,0,0,0
"access_res_country_group_group_all","res_country_group group_user_all","model_res_country_group",,1,0,0,0
"access_res_country_group_user","res_country group_user","model_res_country","group_partner_manager",1,1,1,1
"access_res_country_state_group_user","res_country_state group_user","model_res_country_state","group_partner_manager",1,1,1,1
"access_res_country_group_group_user","res_country_group group_user","model_res_country_group","group_partner_manager",1,1,1,1
"access_res_currency_group_all","res_currency group_all","model_res_currency",,1,0,0,0
"access_res_currency_rate_group_all","res_currency_rate group_all","model_res_currency_rate",,1,0,0,0
"access_res_currency_group_system","res_currency group_system","model_res_currency","group_system",1,1,1,1
"access_res_currency_rate_group_system","res_currency_rate group_system","model_res_currency_rate","group_system",1,1,1,1
"access_res_groups_group_erp_manager","res_groups group_erp_manager","model_res_groups","group_erp_manager",1,1,1,1
"access_res_groups_group_user","res_groups group_user","model_res_groups",group_user,1,0,0,0
"access_res_lang_group_all","res_lang group_all","model_res_lang",,1,0,0,0
"access_res_lang_group_user","res_lang group_user","model_res_lang","group_system",1,1,1,1
"access_res_partner_public","res_partner group_public","model_res_partner","group_public",1,0,0,0
"access_res_partner_portal","res_partner group_portal","model_res_partner","group_portal",1,0,0,0
"access_res_partner_group_partner_manager","res_partner group_partner_manager","model_res_partner","group_partner_manager",1,1,1,1
"access_res_partner_group_user","res_partner group_user","model_res_partner","group_user",1,0,0,0
"access_res_partner_bank_group_user","res_partner_bank group_user","model_res_partner_bank","group_user",1,0,0,0
"access_res_partner_bank_group_partner_manager","res_partner_bank group_partner_manager","model_res_partner_bank","group_partner_manager",1,1,1,1
"access_res_partner_category_group_user","res_partner_category group_user","model_res_partner_category","group_user",1,0,0,0
"access_res_partner_category_group_partner_manager","res_partner_category group_partner_manager","model_res_partner_category","group_partner_manager",1,1,1,1
"access_res_partner_industry_group_user","res_partner_industry group_user","model_res_partner_industry","group_user",1,0,0,0
"access_res_partner_industry_group_system","res_partner_industry group_system","model_res_partner_industry","group_system",1,1,1,1
"access_res_partner_title_group_user","res_partner_title group_user","model_res_partner_title","group_partner_manager",1,1,1,1
"access_res_partner_title_group_partner_manager","res_partner_title group_partner_manager","model_res_partner_title",,1,0,0,0
"access_res_request_link_group_system","res_request_link group_system","model_res_request_link","group_system",1,1,1,1
"access_res_request_link_group_user","res_request_link group_user","model_res_request_link",,1,0,0,0
"access_res_users_all","res_users all","model_res_users",,1,0,0,0
"access_res_users_group_erp_manager","res_users group_erp_manager","model_res_users","group_erp_manager",1,1,1,1
"access_res_users_log_all","res_users_log_all","model_res_users_log",,1,0,1,0
"access_ir_actions_all","ir_actions_all","model_ir_actions_actions",,1,0,0,0
"access_ir_actions_group_system","ir_actions_group_system","model_ir_actions_actions","group_system",1,1,1,1
"access_ir_actions_act_window_all","ir_actions_act_window_all","model_ir_actions_act_window",,1,0,0,0
"access_ir_actions_act_window_system","ir_actions_act_window_system","model_ir_actions_act_window","group_system",1,1,1,1
"access_ir_actions_act_window_close_all","ir_actions_act_window_close_all","model_ir_actions_act_window_close",,1,0,0,0
"access_ir_actions_act_window_close_group_system","ir_actions_act_window_close_group_system","model_ir_actions_act_window_close","group_system",1,1,1,1
"access_ir_actions_report_all","ir_actions_report","model_ir_actions_report",,1,0,0,0
"access_ir_actions_report_group_system","ir_actions_report_group_system","model_ir_actions_report","group_system",1,1,1,1
"access_ir_actions_todo_group_system","ir_actions_todo group system","model_ir_actions_todo","group_system",1,1,1,1
"access_ir_actions_act_window_view_all","ir_actions_act_window_view_all","model_ir_actions_act_window_view",,1,0,0,0
"access_ir_actions_act_window_view_group_system","ir_actions_act_window_view_group_system","model_ir_actions_act_window_view","group_system",1,1,1,1
"access_ir_actions_act_url_all","ir_actions_act_url_all","model_ir_actions_act_url",,1,0,0,0
"access_ir_actions_act_url_group_system","ir_actions_act_url_group_system","model_ir_actions_act_url","group_system",1,1,1,1
"access_ir_server_object_lines_all","ir_server_object_lines_all","model_ir_server_object_lines",,1,0,0,0
"access_ir_server_object_lines_group_system","ir_server_object_lines_group_system","model_ir_server_object_lines","group_system",1,1,1,1
"access_ir_actions_server_all","ir_actions_server_all","model_ir_actions_server",,1,0,0,0
"access_ir_actions_server_group_system","ir_actions_server_group_system","model_ir_actions_server","group_system",1,1,1,1
"access_res_bank_group_system","res_bank_group_system","model_res_bank","group_system",1,1,1,1
"access_res_bank_group_partner_manager","res_bank_group_partner_manager","model_res_bank","group_partner_manager",1,1,1,1
"access_res_bank_user","res_bank user","model_res_bank","group_user",1,0,0,0
"access_ir_filter_erp_manager","ir_filters all","model_ir_filters","group_erp_manager",1,1,1,1
"access_ir_filter_user","ir_filters all","model_ir_filters","group_user",1,1,1,1
"access_ir_filter_portal","ir_filters all","model_ir_filters","group_portal",1,1,1,1
"access_ir_filter_public","ir_filters all","model_ir_filters","group_public",1,1,1,1
"access_ir_config_parameter_system","ir_config_parameter_system","model_ir_config_parameter","group_system",1,1,1,1
"access_ir_mail_server","ir_mail_server","model_ir_mail_server","group_system",1,1,1,1
"access_ir_actions_client","ir_actions_client all","model_ir_actions_client",,1,0,0,0
"access_ir_logging","ir_logging admin","model_ir_logging","group_erp_manager",1,1,1,1
"paperformat_access_portal","ir_actions_report_paperformat group_portal","model_report_paperformat",,1,0,0,0
"paperformat_access_employee","ir_actions_report_paperformat group_hr_user","model_report_paperformat",,1,0,1,0
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
access_ir_attachment_all,ir_attachment all,model_ir_attachment,,1,0,0,0
access_ir_attachment_group_user,ir_attachment group_user,model_ir_attachment,group_user,1,1,1,1
access_ir_attachment_portal,ir.attachment.portal,model_ir_attachment,group_portal,1,0,1,0
access_ir_cron_group_cron,ir_cron group_cron,model_ir_cron,group_system,1,1,1,1
access_ir_exports_group_system,ir_exports group_system,model_ir_exports,base.group_user,1,1,1,1
access_ir_exports_line_group_system,ir_exports_line group_system,model_ir_exports_line,base.group_user,1,1,1,1
access_ir_model_group_erp_manager,ir_model group_erp_manager,model_ir_model,group_erp_manager,1,1,1,1
access_ir_model_constraint_group_erp_manager,ir_model_constraint group_erp_manager,model_ir_model_constraint,group_erp_manager,1,1,1,1
access_ir_model_relation_group_erp_manager,ir_model_relation group_erp_manager,model_ir_model_relation,group_erp_manager,1,1,1,1
access_ir_model_access_group_erp_manager,ir_model_access_group_erp_manager,model_ir_model_access,group_erp_manager,1,1,1,1
access_ir_model_data_group_erp_manager,ir_model_data group_erp_manager,model_ir_model_data,group_erp_manager,1,1,1,1
access_ir_model_fields_group_erp_manager,ir_model_fields group_erp_manager,model_ir_model_fields,group_erp_manager,1,1,1,1
access_ir_model_user,ir_model_all,model_ir_model,base.group_user,1,0,0,0
access_ir_model_data_user,ir_model_data user,model_ir_model_data,base.group_user,1,0,1,0
access_ir_model_fields_user,ir_model_fields all,model_ir_model_fields,base.group_user,1,0,0,0
access_ir_module_category_group_user,ir_module_category group_user,model_ir_module_category,group_erp_manager,1,0,0,0
access_ir_module_module_group_user,ir_module_module group_user,model_ir_module_module,group_system,1,1,1,1
access_ir_module_module_dependency_group_system,ir_module_module_dependency group_system,model_ir_module_module_dependency,group_system,1,1,1,1
access_ir_module_module_exclusion_group_system,ir_module_module_exclusion group_system,model_ir_module_module_exclusion,group_system,1,1,1,1
access_ir_property_group_user,ir_property group_user,model_ir_property,,1,0,0,0
access_ir_property_group_user_manager,ir_property group_manager,model_ir_property,base.group_partner_manager,1,1,1,0
access_ir_rule_group_erp_manager,ir_rule group_erp_manager,model_ir_rule,group_erp_manager,1,1,1,1
access_ir_sequence_group_user,ir_sequence group_user,model_ir_sequence,group_user,1,0,0,0
access_ir_sequence_group_system,ir_sequence group_system,model_ir_sequence,group_system,1,1,1,1
access_ir_sequence_date_range_group_user,ir_sequence_date_range group_user,model_ir_sequence_date_range,group_user,1,0,0,0
access_ir_sequence_date_range_group_system,ir_sequence_date_range group_system,model_ir_sequence_date_range,group_system,1,1,1,1
access_ir_translation_all,ir_translation all,model_ir_translation,group_user,1,1,1,1
access_ir_translation_group_system,ir_translation group_system,model_ir_translation,group_system,1,1,1,1
access_ir_ui_menu_group_user,ir_ui_menu group_user,model_ir_ui_menu,base.group_user,1,0,0,0
access_ir_ui_menu_group_system,ir_ui_menu group_system,model_ir_ui_menu,group_system,1,1,1,1
access_ir_ui_view_group_user,ir_ui_view group_user,model_ir_ui_view,,1,0,0,0
access_ir_ui_view_group_system,ir_ui_view group_system,model_ir_ui_view,group_system,1,1,1,1
access_ir_ui_view_custom_group_user,ir_ui_view_custom_group_user,model_ir_ui_view_custom,,1,1,1,1
access_ir_default_all,ir_default all,model_ir_default,,1,0,0,0
access_ir_default_group_user,ir_default group_user,model_ir_default,group_user,1,1,1,1
access_ir_default_group_system,ir_default group_system,model_ir_default,group_system,1,1,1,1
access_res_company_group_erp_manager,res_company group_erp_manager,model_res_company,group_erp_manager,1,1,1,1
access_res_company_group_user,res_company group_user,model_res_company,,1,0,0,0
access_res_country_group_all,res_country group_user_all,model_res_country,,1,0,0,0
access_res_country_state_group_all,res_country_state group_user_all,model_res_country_state,,1,0,0,0
access_res_country_group_group_all,res_country_group group_user_all,model_res_country_group,,1,0,0,0
access_res_country_group_user,res_country group_user,model_res_country,group_partner_manager,1,1,1,1
access_res_country_state_group_user,res_country_state group_user,model_res_country_state,group_partner_manager,1,1,1,1
access_res_country_group_group_user,res_country_group group_user,model_res_country_group,group_partner_manager,1,1,1,1
access_res_currency_group_all,res_currency group_all,model_res_currency,,1,0,0,0
access_res_currency_rate_group_all,res_currency_rate group_all,model_res_currency_rate,,1,0,0,0
access_res_currency_group_system,res_currency group_system,model_res_currency,group_system,1,1,1,1
access_res_currency_rate_group_system,res_currency_rate group_system,model_res_currency_rate,group_system,1,1,1,1
access_res_groups_group_erp_manager,res_groups group_erp_manager,model_res_groups,group_erp_manager,1,1,1,1
access_res_groups_group_user,res_groups group_user,model_res_groups,group_user,1,0,0,0
access_res_lang_group_all,res_lang group_all,model_res_lang,,1,0,0,0
access_res_lang_group_user,res_lang group_user,model_res_lang,group_system,1,1,1,1
access_res_partner_public,res_partner group_public,model_res_partner,group_public,1,0,0,0
access_res_partner_portal,res_partner group_portal,model_res_partner,group_portal,1,0,0,0
access_res_partner_group_partner_manager,res_partner group_partner_manager,model_res_partner,group_partner_manager,1,1,1,1
access_res_partner_group_user,res_partner group_user,model_res_partner,group_user,1,0,0,0
access_res_partner_bank_group_user,res_partner_bank group_user,model_res_partner_bank,group_user,1,0,0,0
access_res_partner_bank_group_partner_manager,res_partner_bank group_partner_manager,model_res_partner_bank,group_partner_manager,1,1,1,1
access_res_partner_category_group_user,res_partner_category group_user,model_res_partner_category,group_user,1,0,0,0
access_res_partner_category_group_partner_manager,res_partner_category group_partner_manager,model_res_partner_category,group_partner_manager,1,1,1,1
access_res_partner_industry_group_user,res_partner_industry group_user,model_res_partner_industry,group_user,1,0,0,0
access_res_partner_industry_group_system,res_partner_industry group_system,model_res_partner_industry,group_system,1,1,1,1
access_res_partner_title_group_user,res_partner_title group_user,model_res_partner_title,group_partner_manager,1,1,1,1
access_res_partner_title_group_partner_manager,res_partner_title group_partner_manager,model_res_partner_title,,1,0,0,0
access_res_request_link_group_system,res_request_link group_system,model_res_request_link,group_system,1,1,1,1
access_res_request_link_group_user,res_request_link group_user,model_res_request_link,,1,0,0,0
access_res_users_all,res_users all,model_res_users,,1,0,0,0
access_res_users_group_erp_manager,res_users group_erp_manager,model_res_users,group_erp_manager,1,1,1,1
access_res_users_log_all,res_users_log_all,model_res_users_log,,1,0,1,0
access_ir_actions_all,ir_actions_all,model_ir_actions_actions,,1,0,0,0
access_ir_actions_group_system,ir_actions_group_system,model_ir_actions_actions,group_system,1,1,1,1
access_ir_actions_act_window_all,ir_actions_act_window_all,model_ir_actions_act_window,,1,0,0,0
access_ir_actions_act_window_system,ir_actions_act_window_system,model_ir_actions_act_window,group_system,1,1,1,1
access_ir_actions_act_window_close_all,ir_actions_act_window_close_all,model_ir_actions_act_window_close,,1,0,0,0
access_ir_actions_act_window_close_group_system,ir_actions_act_window_close_group_system,model_ir_actions_act_window_close,group_system,1,1,1,1
access_ir_actions_report_all,ir_actions_report,model_ir_actions_report,,1,0,0,0
access_ir_actions_report_group_system,ir_actions_report_group_system,model_ir_actions_report,group_system,1,1,1,1
access_ir_actions_todo_group_system,ir_actions_todo group system,model_ir_actions_todo,group_system,1,1,1,1
access_ir_actions_act_window_view_all,ir_actions_act_window_view_all,model_ir_actions_act_window_view,,1,0,0,0
access_ir_actions_act_window_view_group_system,ir_actions_act_window_view_group_system,model_ir_actions_act_window_view,group_system,1,1,1,1
access_ir_actions_act_url_all,ir_actions_act_url_all,model_ir_actions_act_url,,1,0,0,0
access_ir_actions_act_url_group_system,ir_actions_act_url_group_system,model_ir_actions_act_url,group_system,1,1,1,1
access_ir_server_object_lines_all,ir_server_object_lines_all,model_ir_server_object_lines,,1,0,0,0
access_ir_server_object_lines_group_system,ir_server_object_lines_group_system,model_ir_server_object_lines,group_system,1,1,1,1
access_ir_actions_server_all,ir_actions_server_all,model_ir_actions_server,,1,0,0,0
access_ir_actions_server_group_system,ir_actions_server_group_system,model_ir_actions_server,group_system,1,1,1,1
access_res_bank_group_system,res_bank_group_system,model_res_bank,group_system,1,1,1,1
access_res_bank_group_partner_manager,res_bank_group_partner_manager,model_res_bank,group_partner_manager,1,1,1,1
access_res_bank_user,res_bank user,model_res_bank,group_user,1,0,0,0
access_ir_filter_erp_manager,ir_filters all,model_ir_filters,group_erp_manager,1,1,1,1
access_ir_filter_user,ir_filters all,model_ir_filters,group_user,1,1,1,1
access_ir_filter_portal,ir_filters all,model_ir_filters,group_portal,1,1,1,1
access_ir_filter_public,ir_filters all,model_ir_filters,group_public,1,1,1,1
access_ir_config_parameter_system,ir_config_parameter_system,model_ir_config_parameter,group_system,1,1,1,1
access_ir_mail_server,ir_mail_server,model_ir_mail_server,group_system,1,1,1,1
access_ir_actions_client,ir_actions_client all,model_ir_actions_client,,1,0,0,0
access_ir_logging,ir_logging admin,model_ir_logging,group_erp_manager,1,1,1,1
paperformat_access_portal,ir_actions_report_paperformat group_portal,model_report_paperformat,,1,0,0,0
paperformat_access_employee,ir_actions_report_paperformat group_hr_user,model_report_paperformat,,1,0,1,0
access_ir_cronjob_logs,access_ir_cronjob_logs,model_ir_cronjob_logs,group_system,1,1,1,1

1 id name model_id:id group_id:id perm_read perm_write perm_create perm_unlink
2 access_ir_attachment_all ir_attachment all model_ir_attachment 1 0 0 0
3 access_ir_attachment_group_user ir_attachment group_user model_ir_attachment group_user 1 1 1 1
4 access_ir_attachment_portal ir.attachment.portal model_ir_attachment group_portal 1 0 1 0
5 access_ir_cron_group_cron ir_cron group_cron model_ir_cron group_system 1 1 1 1
6 access_ir_exports_group_system ir_exports group_system model_ir_exports base.group_user 1 1 1 1
7 access_ir_exports_line_group_system ir_exports_line group_system model_ir_exports_line base.group_user 1 1 1 1
8 access_ir_model_group_erp_manager ir_model group_erp_manager model_ir_model group_erp_manager 1 1 1 1
9 access_ir_model_constraint_group_erp_manager ir_model_constraint group_erp_manager model_ir_model_constraint group_erp_manager 1 1 1 1
10 access_ir_model_relation_group_erp_manager ir_model_relation group_erp_manager model_ir_model_relation group_erp_manager 1 1 1 1
11 access_ir_model_access_group_erp_manager ir_model_access_group_erp_manager model_ir_model_access group_erp_manager 1 1 1 1
12 access_ir_model_data_group_erp_manager ir_model_data group_erp_manager model_ir_model_data group_erp_manager 1 1 1 1
13 access_ir_model_fields_group_erp_manager ir_model_fields group_erp_manager model_ir_model_fields group_erp_manager 1 1 1 1
14 access_ir_model_user ir_model_all model_ir_model base.group_user 1 0 0 0
15 access_ir_model_data_user ir_model_data user model_ir_model_data base.group_user 1 0 1 0
16 access_ir_model_fields_user ir_model_fields all model_ir_model_fields base.group_user 1 0 0 0
17 access_ir_module_category_group_user ir_module_category group_user model_ir_module_category group_erp_manager 1 0 0 0
18 access_ir_module_module_group_user ir_module_module group_user model_ir_module_module group_system 1 1 1 1
19 access_ir_module_module_dependency_group_system ir_module_module_dependency group_system model_ir_module_module_dependency group_system 1 1 1 1
20 access_ir_module_module_exclusion_group_system ir_module_module_exclusion group_system model_ir_module_module_exclusion group_system 1 1 1 1
21 access_ir_property_group_user ir_property group_user model_ir_property 1 0 0 0
22 access_ir_property_group_user_manager ir_property group_manager model_ir_property base.group_partner_manager 1 1 1 0
23 access_ir_rule_group_erp_manager ir_rule group_erp_manager model_ir_rule group_erp_manager 1 1 1 1
24 access_ir_sequence_group_user ir_sequence group_user model_ir_sequence group_user 1 0 0 0
25 access_ir_sequence_group_system ir_sequence group_system model_ir_sequence group_system 1 1 1 1
26 access_ir_sequence_date_range_group_user ir_sequence_date_range group_user model_ir_sequence_date_range group_user 1 0 0 0
27 access_ir_sequence_date_range_group_system ir_sequence_date_range group_system model_ir_sequence_date_range group_system 1 1 1 1
28 access_ir_translation_all ir_translation all model_ir_translation group_user 1 1 1 1
29 access_ir_translation_group_system ir_translation group_system model_ir_translation group_system 1 1 1 1
30 access_ir_ui_menu_group_user ir_ui_menu group_user model_ir_ui_menu base.group_user 1 0 0 0
31 access_ir_ui_menu_group_system ir_ui_menu group_system model_ir_ui_menu group_system 1 1 1 1
32 access_ir_ui_view_group_user ir_ui_view group_user model_ir_ui_view 1 0 0 0
33 access_ir_ui_view_group_system ir_ui_view group_system model_ir_ui_view group_system 1 1 1 1
34 access_ir_ui_view_custom_group_user ir_ui_view_custom_group_user model_ir_ui_view_custom 1 1 1 1
35 access_ir_default_all ir_default all model_ir_default 1 0 0 0
36 access_ir_default_group_user ir_default group_user model_ir_default group_user 1 1 1 1
37 access_ir_default_group_system ir_default group_system model_ir_default group_system 1 1 1 1
38 access_res_company_group_erp_manager res_company group_erp_manager model_res_company group_erp_manager 1 1 1 1
39 access_res_company_group_user res_company group_user model_res_company 1 0 0 0
40 access_res_country_group_all res_country group_user_all model_res_country 1 0 0 0
41 access_res_country_state_group_all res_country_state group_user_all model_res_country_state 1 0 0 0
42 access_res_country_group_group_all res_country_group group_user_all model_res_country_group 1 0 0 0
43 access_res_country_group_user res_country group_user model_res_country group_partner_manager 1 1 1 1
44 access_res_country_state_group_user res_country_state group_user model_res_country_state group_partner_manager 1 1 1 1
45 access_res_country_group_group_user res_country_group group_user model_res_country_group group_partner_manager 1 1 1 1
46 access_res_currency_group_all res_currency group_all model_res_currency 1 0 0 0
47 access_res_currency_rate_group_all res_currency_rate group_all model_res_currency_rate 1 0 0 0
48 access_res_currency_group_system res_currency group_system model_res_currency group_system 1 1 1 1
49 access_res_currency_rate_group_system res_currency_rate group_system model_res_currency_rate group_system 1 1 1 1
50 access_res_groups_group_erp_manager res_groups group_erp_manager model_res_groups group_erp_manager 1 1 1 1
51 access_res_groups_group_user res_groups group_user model_res_groups group_user 1 0 0 0
52 access_res_lang_group_all res_lang group_all model_res_lang 1 0 0 0
53 access_res_lang_group_user res_lang group_user model_res_lang group_system 1 1 1 1
54 access_res_partner_public res_partner group_public model_res_partner group_public 1 0 0 0
55 access_res_partner_portal res_partner group_portal model_res_partner group_portal 1 0 0 0
56 access_res_partner_group_partner_manager res_partner group_partner_manager model_res_partner group_partner_manager 1 1 1 1
57 access_res_partner_group_user res_partner group_user model_res_partner group_user 1 0 0 0
58 access_res_partner_bank_group_user res_partner_bank group_user model_res_partner_bank group_user 1 0 0 0
59 access_res_partner_bank_group_partner_manager res_partner_bank group_partner_manager model_res_partner_bank group_partner_manager 1 1 1 1
60 access_res_partner_category_group_user res_partner_category group_user model_res_partner_category group_user 1 0 0 0
61 access_res_partner_category_group_partner_manager res_partner_category group_partner_manager model_res_partner_category group_partner_manager 1 1 1 1
62 access_res_partner_industry_group_user res_partner_industry group_user model_res_partner_industry group_user 1 0 0 0
63 access_res_partner_industry_group_system res_partner_industry group_system model_res_partner_industry group_system 1 1 1 1
64 access_res_partner_title_group_user res_partner_title group_user model_res_partner_title group_partner_manager 1 1 1 1
65 access_res_partner_title_group_partner_manager res_partner_title group_partner_manager model_res_partner_title 1 0 0 0
66 access_res_request_link_group_system res_request_link group_system model_res_request_link group_system 1 1 1 1
67 access_res_request_link_group_user res_request_link group_user model_res_request_link 1 0 0 0
68 access_res_users_all res_users all model_res_users 1 0 0 0
69 access_res_users_group_erp_manager res_users group_erp_manager model_res_users group_erp_manager 1 1 1 1
70 access_res_users_log_all res_users_log_all model_res_users_log 1 0 1 0
71 access_ir_actions_all ir_actions_all model_ir_actions_actions 1 0 0 0
72 access_ir_actions_group_system ir_actions_group_system model_ir_actions_actions group_system 1 1 1 1
73 access_ir_actions_act_window_all ir_actions_act_window_all model_ir_actions_act_window 1 0 0 0
74 access_ir_actions_act_window_system ir_actions_act_window_system model_ir_actions_act_window group_system 1 1 1 1
75 access_ir_actions_act_window_close_all ir_actions_act_window_close_all model_ir_actions_act_window_close 1 0 0 0
76 access_ir_actions_act_window_close_group_system ir_actions_act_window_close_group_system model_ir_actions_act_window_close group_system 1 1 1 1
77 access_ir_actions_report_all ir_actions_report model_ir_actions_report 1 0 0 0
78 access_ir_actions_report_group_system ir_actions_report_group_system model_ir_actions_report group_system 1 1 1 1
79 access_ir_actions_todo_group_system ir_actions_todo group system model_ir_actions_todo group_system 1 1 1 1
80 access_ir_actions_act_window_view_all ir_actions_act_window_view_all model_ir_actions_act_window_view 1 0 0 0
81 access_ir_actions_act_window_view_group_system ir_actions_act_window_view_group_system model_ir_actions_act_window_view group_system 1 1 1 1
82 access_ir_actions_act_url_all ir_actions_act_url_all model_ir_actions_act_url 1 0 0 0
83 access_ir_actions_act_url_group_system ir_actions_act_url_group_system model_ir_actions_act_url group_system 1 1 1 1
84 access_ir_server_object_lines_all ir_server_object_lines_all model_ir_server_object_lines 1 0 0 0
85 access_ir_server_object_lines_group_system ir_server_object_lines_group_system model_ir_server_object_lines group_system 1 1 1 1
86 access_ir_actions_server_all ir_actions_server_all model_ir_actions_server 1 0 0 0
87 access_ir_actions_server_group_system ir_actions_server_group_system model_ir_actions_server group_system 1 1 1 1
88 access_res_bank_group_system res_bank_group_system model_res_bank group_system 1 1 1 1
89 access_res_bank_group_partner_manager res_bank_group_partner_manager model_res_bank group_partner_manager 1 1 1 1
90 access_res_bank_user res_bank user model_res_bank group_user 1 0 0 0
91 access_ir_filter_erp_manager ir_filters all model_ir_filters group_erp_manager 1 1 1 1
92 access_ir_filter_user ir_filters all model_ir_filters group_user 1 1 1 1
93 access_ir_filter_portal ir_filters all model_ir_filters group_portal 1 1 1 1
94 access_ir_filter_public ir_filters all model_ir_filters group_public 1 1 1 1
95 access_ir_config_parameter_system ir_config_parameter_system model_ir_config_parameter group_system 1 1 1 1
96 access_ir_mail_server ir_mail_server model_ir_mail_server group_system 1 1 1 1
97 access_ir_actions_client ir_actions_client all model_ir_actions_client 1 0 0 0
98 access_ir_logging ir_logging admin model_ir_logging group_erp_manager 1 1 1 1
99 paperformat_access_portal ir_actions_report_paperformat group_portal model_report_paperformat 1 0 0 0
100 paperformat_access_employee ir_actions_report_paperformat group_hr_user model_report_paperformat 1 0 1 0
101 access_ir_cronjob_logs access_ir_cronjob_logs model_ir_cronjob_logs group_system 1 1 1 1