legislei.controllers.dto module¶
-
class
legislei.controllers.dto.CustomPresence(default=None, attribute=None, title=None, description=None, required=None, readonly=None, example=None, mask=None, **kwargs)[código fonte]¶ Bases:
flask_restplus.fields.Raw-
format(value)[código fonte]¶ Formats a field’s value. No-op by default - field classes that modify how the value of existing object keys should be presented should override this and apply the appropriate formatting.
Parâmetros: value – The value to format Levanta: MarshallingError – In case of formatting problem Ex:
class TitleCase(Raw): def format(self, value): return unicode(value).title()
-
-
class
legislei.controllers.dto.MongoDateTime(dt_format='iso8601', **kwargs)[código fonte]¶ Bases:
flask_restplus.fields.DateTime-
format(value)[código fonte]¶ Formats a field’s value. No-op by default - field classes that modify how the value of existing object keys should be presented should override this and apply the appropriate formatting.
Parâmetros: value – The value to format Levanta: MarshallingError – In case of formatting problem Ex:
class TitleCase(Raw): def format(self, value): return unicode(value).title()
-
-
class
legislei.controllers.dto.MongoId(*args, **kwargs)[código fonte]¶ Bases:
flask_restplus.fields.String-
format(value)[código fonte]¶ Formats a field’s value. No-op by default - field classes that modify how the value of existing object keys should be presented should override this and apply the appropriate formatting.
Parâmetros: value – The value to format Levanta: MarshallingError – In case of formatting problem Ex:
class TitleCase(Raw): def format(self, value): return unicode(value).title()
-
-
class
legislei.controllers.dto.MongoRaw(default=None, attribute=None, title=None, description=None, required=None, readonly=None, example=None, mask=None, **kwargs)[código fonte]¶ Bases:
flask_restplus.fields.Raw-
format(value)[código fonte]¶ Formats a field’s value. No-op by default - field classes that modify how the value of existing object keys should be presented should override this and apply the appropriate formatting.
Parâmetros: value – The value to format Levanta: MarshallingError – In case of formatting problem Ex:
class TitleCase(Raw): def format(self, value): return unicode(value).title()
-