Field objects (to define table fields) support default values
try something like
db...default = list()
or
Field("", ... , default=list())
I haven't used it but I guess that on record creation this should
create an empty list field value.
On 5 ene, 19:37, Tsvi Mostovicz wrote:
> I managed to fin
I managed to find the culprit. The function before it had a mismatched
parentheses. So it would continue reading this function and fail on
compilation. Thanks for all your replies. The append works, although
if this is a new user and no list has been defined yet it won't. So I
check if it returns
And if the auth_user field is of type list:, seems that even it
is ok to do simply:
auth.user.mylistfield.append(object)
without explicit db query or update
On 4 ene, 18:42, Alan Etkin wrote:
> If you are doing post-registration process, you might want to use
> auth.settings.register_onaccept:
If you are doing post-registration process, you might want to use
auth.settings.register_onaccept:
register_onaccept is a list of functions or a single function or
lambda that receive a form argument
form.vars.id contains the id of the new auth_user record.
For appending to a sequence stored in
Are you having trouble with the line:
auth.user.my_budgets.append(session.table_token)
Or with return? I only ask because the above line assumes that the current
user object has a list by the name of my_budgets. Is this list created
somewhere else in the code? Also, because the user may not act
5 matches
Mail list logo