Fixed marshmallow stuff
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
9b3d176eed
commit
782728e661
@ -1,14 +1,14 @@
|
||||
#!/usr/bin/env python3
|
||||
from typing import Optional
|
||||
from marshmallow import fields
|
||||
from marshmallow_sqlalchemy import ModelSchema
|
||||
from marshmallow_sqlalchemy import SQLAlchemyAutoSchema
|
||||
from marshmallow_enum import EnumField
|
||||
from model import AIModel, AIModelType
|
||||
|
||||
from .svmdetails_schema import SVMDetailsSchema
|
||||
|
||||
|
||||
class AIModelSchema(ModelSchema):
|
||||
class AIModelSchema(SQLAlchemyAutoSchema):
|
||||
|
||||
_svm_details_schema = SVMDetailsSchema(many=False, exclude=["aimodel"])
|
||||
|
||||
@ -29,3 +29,6 @@ class AIModelSchema(ModelSchema):
|
||||
|
||||
class Meta:
|
||||
model = AIModel
|
||||
include_relationships = True
|
||||
load_instance = True
|
||||
include_fk = True
|
||||
|
@ -1,10 +1,13 @@
|
||||
#!/usr/bin/env python3
|
||||
from marshmallow import fields
|
||||
from marshmallow_sqlalchemy import ModelSchema
|
||||
from marshmallow_sqlalchemy import SQLAlchemyAutoSchema
|
||||
from model import SVMDetails
|
||||
|
||||
|
||||
class SVMDetailsSchema(ModelSchema):
|
||||
class SVMDetailsSchema(SQLAlchemyAutoSchema):
|
||||
|
||||
class Meta:
|
||||
model = SVMDetails
|
||||
include_relationships = True
|
||||
load_instance = True
|
||||
include_fk = True
|
||||
|
@ -6,7 +6,7 @@ Flask-Classful
|
||||
Flask-SQLAlchemy
|
||||
SQLAlchemy-Utils
|
||||
SQLAlchemy
|
||||
marshmallow-sqlalchemy
|
||||
marshmallow-sqlalchemy~=0.26.1
|
||||
marshmallow-enum
|
||||
psycopg2-binary
|
||||
minio~=6.0.0
|
||||
|
Loading…
Reference in New Issue
Block a user