Tweak initial v-bind model value for Buefy form, when is colander.null

This commit is contained in:
Lance Edgar 2019-06-06 15:10:33 -05:00
parent 96c5bd0b69
commit 93a3da2335

View file

@ -96,7 +96,7 @@
% elif isinstance(field.schema.typ, deform.FileData):
field_model_${field.name}: null,
% else:
field_model_${field.name}: ${json.dumps(field.cstruct)|n},
field_model_${field.name}: ${'null' if field.cstruct is colander.null else json.dumps(field.cstruct)|n},
% endif
% endif
% endfor