summaryrefslogtreecommitdiff
path: root/web-server/opendc/api/v2/simulations/endpoint.py
diff options
context:
space:
mode:
authorGeorgios Andreadis <info@gandreadis.com>2020-07-01 14:02:06 +0200
committerFabian Mastenbroek <mail.fabianm@gmail.com>2020-08-24 19:47:20 +0200
commit85901acea556c69891b13ab7299cd62445292c7a (patch)
tree3daffa1a9600df8471a78db719b7964b0bc5c9ef /web-server/opendc/api/v2/simulations/endpoint.py
parentde8f12d74faef5fa3f9e38d1340948cab2d06ea3 (diff)
Fix simulation interface
Diffstat (limited to 'web-server/opendc/api/v2/simulations/endpoint.py')
-rw-r--r--web-server/opendc/api/v2/simulations/endpoint.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/web-server/opendc/api/v2/simulations/endpoint.py b/web-server/opendc/api/v2/simulations/endpoint.py
index c978fad7..bcdea650 100644
--- a/web-server/opendc/api/v2/simulations/endpoint.py
+++ b/web-server/opendc/api/v2/simulations/endpoint.py
@@ -15,7 +15,7 @@ def POST(request):
topology = Topology({'name': 'Default topology', 'rooms': []})
topology.insert()
- simulation = Simulation({'simulation': request.params_body['simulation']})
+ simulation = Simulation(request.params_body['simulation'])
simulation.set_property('datetimeCreated', Database.datetime_to_string(datetime.now()))
simulation.set_property('datetimeLastEdited', Database.datetime_to_string(datetime.now()))
simulation.set_property('topologyIds', [topology.get_id()])