Re: [web2py] Re: Custom functions in Model

2010-02-17 Thread Thadeus Burgess
You might have to do both, if there is a way to determine if the script is being called, then use compute, and if it is a form submission use the onvalidation of the form. -Thadeus On Wed, Feb 17, 2010 at 6:31 AM, JAY wrote: > Hi, > > yes i think it is an requirement... > because in my scena

[web2py] Re: Custom functions in Model

2010-02-17 Thread JAY
Hi, yes i think it is an requirement... because in my scenario the input for the first field is entered either by user via the form or by an script which only inserts this single value and the other field vlaues should be automatic generated by the functions in my Model. But may i be wrong? and t

[web2py] Re: Custom functions in Model

2010-02-17 Thread selecta
> I have a table with 2 fields: > db.define_table("table1", >     Field("field1", "string"), >     Field("field2", "string")) > > field1 is required so there should be two options: > 1. the user enters something in field1 and field2 > 2. the user enters something in field1 and leaves field2 blank