Skip to content

Commit

Permalink
Ontologies added to EUON. Fixes issue EUDAT-B2SHARE#96.
Browse files Browse the repository at this point in the history
  • Loading branch information
peskk3am committed Apr 18, 2014
1 parent 8cfdfd7 commit 7737d15
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions simplestore/lib/simplestore_model/HTML5ModelConverter.py
Original file line number Diff line number Diff line change
Expand Up @@ -202,15 +202,16 @@ class SelectFieldWithInput(SelectField):
filtering = ""
other = ""

def __init__(self, other="", filtering="", cardinality="1",
def __init__(self, other="", filtering="", cardinality=1,
data_provide="", data_source="", **field_args):
# make list of tuples for SelectField (only once)
self.cardinality = cardinality
self.other = other
self.filtering = filtering
# make list of tuples for SelectField (only once)
if isinstance(data_source[0], basestring):
field_args['choices'] = [(x,x) for x in data_source]
field_args['choices'].append(('other', other))
if other:
field_args['choices'].append(('other', other))
super(SelectFieldWithInput, self).__init__(**field_args)


Expand Down

0 comments on commit 7737d15

Please sign in to comment.