On 14/05/10 19:53 +0100, Sharoon Thomas wrote:
> Hello Cedk,
>
> I think it should be possible to specify custom arguments/context in the
> definition of ir.trigger itself.
>
> For example:
>
> The ir.trigger could have a char field for context and when the function is
> called the values in context should be updated.
>
> Suppose that the context in ir.trigger record is: '{ 'foo':'bar' }'
>
> Then the function context in addition to the normal context values should
> have {'lang':....., 'foo':'bar',.....}I think we should avoid as much as possible the usage of context especialy in the base functionality. As the trigger action function has the trigger_id, you could store information on ir.trigger. So poweremail could extend ir.trigger to add a many2one to reports. This field could be invisible when action_model is not the poweremail one. I find this more error-prone. -- Cédric Krier B2CK SPRL Rue de Rotterdam, 4 4000 Liège Belgium Tel: +32 472 54 46 59 Email/Jabber: [email protected] Website: http://www.b2ck.com/
pgp26iGPdSewp.pgp
Description: PGP signature
