On 15/12/13 19:33 -0800, Josias Pérez wrote:
> Hi,
>
> I only want to know how record rule work. For example, I have added to
> party.party and company.employee "type" field ('a', 'b' and 'global).
>
> With the follow rule ['OR', [( 'type' , 'in', ['global','a','b'] if
> user.employee.type == 'global' else [] )], [ ('type', '=',
> user.employee.type )] ] hide parties that doesnt belong to employee of the
> same type, and only show parties for employee types (global show all). On which Model does the rule apply? > The question is: when a employee type 'a' for example, want to create a > sale, tryton client say "You can read records that doesn't exists". Probably the employe can not read the party of the company. > How > control inherits in records to another models to prevent that message? I don't understand the question. Any way, record rules are very complex to manage, you should really have a good point to use them. And I really don't see why you should add such rule to party because party reflect the external world which is readable by everyone. -- Cédric Krier - B2CK SPRL Email/Jabber: [email protected] Tel: +32 472 54 46 59 Website: http://www.b2ck.com/
pgp4oFvnbN_26.pgp
Description: PGP signature
