Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
production
building-knowledge-centre
building-dao
Commits
332ced8a
Commit
332ced8a
authored
Oct 22, 2019
by
Marc-Andre Santune
Browse files
define __setitem__ method
parent
4db8f648
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
0 deletions
+3
-0
building_dao/building_generic.py
building_dao/building_generic.py
+3
-0
No files found.
building_dao/building_generic.py
View file @
332ced8a
...
@@ -38,6 +38,9 @@ class BuildingGeneric:
...
@@ -38,6 +38,9 @@ class BuildingGeneric:
def
__getitem__
(
self
,
item
):
def
__getitem__
(
self
,
item
):
return
self
.
_building
.
get
(
item
)
return
self
.
_building
.
get
(
item
)
def
__setitem__
(
self
,
key
,
item
):
self
.
_building
[
key
]
=
item
# ----------------- Building level ---------------------
# ----------------- Building level ---------------------
def
post_building
(
self
,
payload
)
->
None
:
def
post_building
(
self
,
payload
)
->
None
:
"""Post a new building"""
"""Post a new building"""
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment