I made a model A with lots of fields. It has a Many2one relationship with a minimal model B. B has only one name = fields.Char(...)
field.
Now I have a transient model C which is a wizard where its fields correspond to the fields of model A. So that when the user inputs some data on the wizard or selects one of the predefined values of minimal model B, it creates a record of model C and saves the data.
This works just fine as long as I only use the wizard with one user. Since I have to be able to use it with as many users I want, I have tested it with two users and now the strange thing happens:
Lets say I have multiple predefined records of model B, I'll name them B1, B2 etc. If User 1 uses the wizard and selects B1 and create a record of model A everything works. If User 2 does the same with B2 everything works. But if User 2 wants to use the wizard and selected B1 following error occurs:
Access denied
For this kind of document, you may only access records you created yourself.
(Document type: [modulename.wizard_model_C])
The same thing happens if User 1 wants to use the wizard with model B2 selected. I have no clue what is wrong. This is what I tried:
- deleting all record rules -> nothing changed
- making all access rules to global and 1,1,1,1 -> nothing changed
I would be happy about some hints where the problem could be located. Is model B to blame? Or is it the Many2one relationship of the wizard model C?