Community mailing list archives
Re: Strange error with record rules!!by
Is there any way to overcome this problem?
Dear Abu,I tried what you described on a new database, and I found what you said!Unfortunately, it seems a bug!On Thu, May 7, 2015 at 11:48 AM, Abu Helal <email@example.com> wrote:
Here is my scenario from scratch on a blank database:
Installing these applications;
In the warehouse settings, check these options
Generate procurement in real time
Manage multiple locations and warehouses
Manage advanced routes for your warehouse
Edit the warehouse to be 2-steps in, and 3-steps out.
Create four groups, one for each location.
Define the record rules for each group, on the stock.move object...
['&', ('location_id', 'ilike', 'Output'), '&', ('location_dest_id','ilike', 'Customers'), ('picking_type_id', 'ilike', 'Delivery Orders')]
Create a store person for each location, and in his appropriate group.
Check... :(Is there anything wrong in this simple configuration?On Thu, May 7, 2015 at 9:46 AM, Abu Helal <firstname.lastname@example.org> wrote:I use the advanced routes in my warehouse locations.It is a single warehouse with 2-input and 3-output structure, with advanced routes between them.On Thu, May 7, 2015 at 9:05 AM, Martin Trigaux <email@example.com> wrote:
So it looks like you have a chained move (e.g. in a different warehouse) on which you don't have the access rights.
Your record rule is probably a bit too strict.
On 06/05/15 20:34, Abu Helal wrote:<blockquote cite="mid:CABTM-pPuF-m53ZaZDqgz1E=LA_Ashhg2UnMw1xU2MMDwDn9deQ@mail.gmail.com" type="cite">
File "/opt/odoo/odoo-server/addons/stock/stock.py", line 1963, in writeold_move_date = datetime.strptime(move.move_dest_id.date_expected, DEFAULT_SERVER_DATETIME_FORMAT)File "/opt/odoo/odoo-server/openerp/fields.py", line 810, in __get__return record._cache[self]File "/opt/odoo/odoo-server/openerp/models.py", line 5913, in __getitem__return value.get() if isinstance(value, SpecialValue) else valueFile "/opt/odoo/odoo-server/openerp/fields.py", line 55, in getraise self.exceptionAccessError: ('AccessError', u'The requested operation cannot be completed due to security restrictions. Please contact your system administrator.\n\n(Document type: stock.move, Operation: read)')2015-05-06 18:27:23,034 1564 INFO whm werkzeug: 192.168.159.1 - - [06/May/2015 18:27:23] "POST /web/dataset/call_button HTTP/1.1" 200 -
On Wed, May 6, 2015 at 7:17 PM, Rami Talat <firstname.lastname@example.org> wrote:
Dear Abu,Try to check log file for further info...
On Wed, May 6, 2015 at 7:03 PM, Abu Helal <email@example.com> wrote:
Dear community,Hi.I tried to organize our company's warehouses and locations to the desired structure from our company's point of view to locations such that, (Input, Stock, Packing, and Output).Then I defined a separate record rule for each location, to differentiate between each location moves and the others. Foe a while, everything was going well, but surprisingly, it get a strange error for the storekeeper ...
"AccessErrorThe requested operation cannot be completed due to security restrictions. Please contact your system administrator.
(Document type: stock.move, Operation: read) "
From the first glance I expected that the record rule missed the read permission, but that was wrong. The record rules have the four permissions set!
Can anyone help?Regards,Abu
-- Martin Trigaux Odoo (Formerly OpenERP) Chaussée de Namur, 40 1367 Grand-Rosière Tel: +32 81 81 37 00 http://odoo.com