Open pythononwheels opened 5 years ago
Something like:
if getattr(self.__class__,'_use_pow_schema_attrs', False):
self.basic_schema = {
"_uuid" : { "type" : "string", "default" : str(uuid.uuid4()) },
#"eid" : { "type" : "string" },
"created_at" : { "type" : "datetime" },
"last_updated" : { "type" : "datetime" },
}
else:
self.basic_schema = {}
## And then merge the two dicts schema & basic_schema.
currently available for SQL Models to use SQL refelction: see here
Toggle using the pow schema extensions (id, created_at, last_updated)
_use_pow_schema_attrs = False