1
0
Fork 0
mirror of https://github.com/yweber/lodel2.git synced 2026-08-05 11:58:37 +02:00

fieldtypes: add ftype class attribute

This commit is contained in:
ArnAud 2015-10-16 17:00:10 +02:00
commit fdf8afc236
4 changed files with 8 additions and 0 deletions

View file

@ -6,6 +6,8 @@ class EmFieldType(GenericFieldType):
help = 'A basic boolean field'
ftype='char'
## @brief A char field
# @brief max_length int : The maximum length of this field
def __init__(self, **kwargs):

View file

@ -6,6 +6,8 @@ class EmFieldType(GenericFieldType):
help = 'A datetime field. Take two boolean options now_on_update and now_on_create'
ftype='datetime'
## @brief A datetime field
# @param now_on_update bool : If true the date is set to NOW on update
# @param now_on_create bool : If true the date is set to NEW on creation

View file

@ -6,6 +6,8 @@ class EmFieldType(GenericFieldType):
help = 'A file field. With one options upload_path'
ftype='char'
## @brief A char field
# @brief max_length int : The maximum length of this field
def __init__(self, upload_path=None, **kwargs):

View file

@ -6,6 +6,8 @@ class EmFieldType(GenericFieldType):
help = 'A text field (big string)'
ftype='text'
def __init__(self, **kwargs):
super(EmFieldType, self).__init__(ftype='text',**kwargs)