Re: [tryton-dev] A new design for wizard

2011-08-24 Thread Cédric Krier
On 24/08/11 14:58 -0700, Ian Wilson wrote: > On Wed, Aug 24, 2011 at 1:52 PM, Cédric Krier wrote: > > > On 24/08/11 13:05 -0700, Ian Wilson wrote: > > > On Wed, Aug 24, 2011 at 12:13 PM, Cédric Krier > >wrote: > > > > > > > On 24/08/11 11:34 -0700, Ian Wilson wrote: > > > > > 4. I think also the

Re: [tryton-dev] A new design for wizard

2011-08-24 Thread Ian Wilson
On Wed, Aug 24, 2011 at 1:52 PM, Cédric Krier wrote: > On 24/08/11 13:05 -0700, Ian Wilson wrote: > > On Wed, Aug 24, 2011 at 12:13 PM, Cédric Krier >wrote: > > > > > On 24/08/11 11:34 -0700, Ian Wilson wrote: > > > > I'm not sure if its too soon to bring up these other points so tell > me if >

Re: [tryton-dev] A new design for wizard

2011-08-24 Thread Cédric Krier
On 24/08/11 13:05 -0700, Ian Wilson wrote: > On Wed, Aug 24, 2011 at 12:13 PM, Cédric Krier wrote: > > > On 24/08/11 11:34 -0700, Ian Wilson wrote: > > > I'm not sure if its too soon to bring up these other points so tell me if > > > so: > > > > > > 1. StateAction seems to actually contain the ne

Re: [tryton-dev] A new design for wizard

2011-08-24 Thread Ian Wilson
On Wed, Aug 24, 2011 at 12:13 PM, Cédric Krier wrote: > On 24/08/11 11:34 -0700, Ian Wilson wrote: > > I'm not sure if its too soon to bring up these other points so tell me if > > so: > > > > 1. StateAction seems to actually contain the next state as an attribute > as > > well. > > Oops I made a

Re: [tryton-dev] A new design for wizard

2011-08-24 Thread Cédric Krier
On 24/08/11 11:34 -0700, Ian Wilson wrote: > I'm not sure if its too soon to bring up these other points so tell me if > so: > > 1. StateAction seems to actually contain the next state as an attribute as > well. Oops I made an issue, I made a last minute change StateAction inheriting of StateCho

Re: [tryton-dev] A new design for wizard

2011-08-24 Thread Ian Wilson
On Tue, Aug 23, 2011 at 5:36 AM, Cédric Krier wrote: > On 23/08/11 08:27 -0400, Sharoon Thomas wrote: > > > > On Aug 22, 2011, at 5:15 PM, Cédric Krier wrote: > > > > > > > > class Example(Wizard): > > >start = 'init' > > >end = 'end' > > > > > >init = StateForm('account.invoice', but

Re: [tryton-dev] A new design for wizard

2011-08-23 Thread Cédric Krier
On 23/08/11 08:27 -0400, Sharoon Thomas wrote: > > On Aug 22, 2011, at 5:15 PM, Cédric Krier wrote: > > > > > class Example(Wizard): > >start = 'init' > >end = 'end' > > > >init = StateForm('account.invoice', buttons=[Button('Cancel'), > > Button('ok', 'step2')], > >default

Re: [tryton-dev] A new design for wizard

2011-08-23 Thread Sharoon Thomas
On Aug 22, 2011, at 5:15 PM, Cédric Krier wrote: > > class Example(Wizard): >start = 'init' >end = 'end' > >init = StateForm('account.invoice', buttons=[Button('Cancel'), > Button('ok', 'step2')], >default='default_invoice') >step2 = StateAction('action_step2', 'next_st

Re: [tryton-dev] A new design for wizard

2011-08-23 Thread Oscar Andres Alvarez Montero
Hi, I agree your propose it seem interesting. Oscar Alvarez 2011/8/23 Paul J Stevens > > > On 22-08-11 23:15, Cédric Krier wrote: > > Hi, > > > > For some times, I'm thinking about a better design for wizards. > > The goals are: > > > > - Better self validation by using object instead of

Re: [tryton-dev] A new design for wizard

2011-08-23 Thread Paul J Stevens
On 22-08-11 23:15, Cédric Krier wrote: > Hi, > > For some times, I'm thinking about a better design for wizards. > The goals are: > > - Better self validation by using object instead of dict > - More expressive > - Less magic tricks > > So here is the result, it is just some snipet

[tryton-dev] A new design for wizard

2011-08-22 Thread Cédric Krier
Hi, For some times, I'm thinking about a better design for wizards. The goals are: - Better self validation by using object instead of dict - More expressive - Less magic tricks So here is the result, it is just some snipet code that has no meaning but just show the design principles