summaryrefslogtreecommitdiff
path: root/opendc-web
diff options
context:
space:
mode:
Diffstat (limited to 'opendc-web')
-rw-r--r--opendc-web/opendc-web-api/opendc/models/scenario.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/opendc-web/opendc-web-api/opendc/models/scenario.py b/opendc-web/opendc-web-api/opendc/models/scenario.py
index 63160448..47771e06 100644
--- a/opendc-web/opendc-web-api/opendc/models/scenario.py
+++ b/opendc-web/opendc-web-api/opendc/models/scenario.py
@@ -8,6 +8,13 @@ from opendc.models.model import Model
from opendc.models.portfolio import Portfolio
+class SimulationSchema(Schema):
+ """
+ Simulation details.
+ """
+ state = fields.String()
+
+
class TraceSchema(Schema):
"""
Schema for specifying the trace of a scenario.
@@ -42,6 +49,8 @@ class ScenarioSchema(Schema):
trace = fields.Nested(TraceSchema)
topology = fields.Nested(TopologySchema)
operational = fields.Nested(OperationalSchema)
+ simulation = fields.Nested(SimulationSchema, dump_only=True)
+ results = fields.Dict(dump_only=True)
class Scenario(Model):