Reputation: 396
Error:
odoo.models: Access Denied by ACLs for operation: read, uid: 4, model: product.template, fields: activity_ids You do not have enough rights to access the fields "activity_ids" on Product Template (product.template). Please contact your system administrator."
Even when I wrote this in model.access
, I still have the same issue:
mail.access_mail_activity,access.mail.activity,mail.model_mail_activity,,1,1,1,1
Upvotes: 1
Views: 3270
Reputation: 91
The activity_ids
field at product.template
is related to the object called mail.activity
. In order to check what has happened to the access right on that field, you can try to temporary disable all security rules attached to the object:
mail.activity
model then open it.Access Rights
tab, print screen to remember existing rule, then uncheck all the rules.Record Rules
tab and do the same as point 4.Upvotes: 0
Reputation: 14768
Did you somehow create an activity on the product template for a user, who has no read rights to that product template?
Or does the user trying to access activity_ids
on this specific product template not have those rights?
The access rights of activities are bound to the access rights of the related document itself. Take a look at this
def _filter_access_rules_remaining(self, valid, operation, filter_access_rules_method):
""" Return the subset of ``self`` for which ``operation`` is allowed.
A custom implementation is done on activities as this document has some
access rules and is based on related document for activities that are
not covered by those rules.
Access on activities are the following :
* create: (``mail_post_access`` or write) right on related documents;
* read: read rights on related documents;
* write: access rule OR
(``mail_post_access`` or write) rights on related documents);
* unlink: access rule OR
(``mail_post_access`` or write) rights on related documents);
"""
That topic is very complex, but i hope this still helps.
Additional info: Something similar was done with attachments (ir.attachment), but it's implemented in another way.
Upvotes: 1