[gen] Master-slave fields: slave values can now ajax-change when the user modifies master values.

This commit is contained in:
Gaetan Delannay 2014-03-03 18:54:21 +01:00
parent f7172be6ee
commit b8ceb66a49
15 changed files with 253 additions and 74 deletions

View file

@ -211,7 +211,8 @@ def writeCookie(login, password, request):
# ------------------------------------------------------------------------------
def initMasterValue(v):
'''Standardizes p_v as a list of strings.'''
'''Standardizes p_v as a list of strings, excepted if p_v is a method.'''
if callable(v): return v
if not isinstance(v, bool) and not v: res = []
elif type(v) not in sutils.sequenceTypes: res = [v]
else: res = v