Added all models to the docs and fixed some command issues

doc_update
Joey Hines 2019-05-11 11:21:00 -05:00
parent 235ed18f7e
commit f1a7cb61e5
4 changed files with 15 additions and 2 deletions

1
.gitignore vendored
View File

@ -2,3 +2,4 @@
__pycache__/* __pycache__/*
/dist/* /dist/*
/GeoffreyApp.egg-info/* /GeoffreyApp.egg-info/*
docs.sh

View File

@ -432,7 +432,7 @@ def info(location_name):
loc_json["items"].append(item.json) loc_json["items"].append(item.json)
elif type(loc) == PublicFarm: elif type(loc) == PublicFarm:
loc_json["resources"] = [] loc_json["resources"] = []
for resource in loc.resources.all(): for resource in loc.resource.all():
loc_json["resources"].append(resource.json) loc_json["resources"].append(resource.json)
return loc_json return loc_json

View File

@ -25,3 +25,14 @@ Models used in Geoffrey
.. autoclass:: GeoffreyApp.models.Tunnel .. autoclass:: GeoffreyApp.models.Tunnel
:members: :members:
.. autoclass:: GeoffreyApp.models.PublicFarm
:members:
.. autoclass:: GeoffreyApp.models.Resource
:members:
.. autoclass:: GeoffreyApp.models.PointOfInterest
:members:
.. autoclass:: GeoffreyApp.models.Market
:members:

View File

@ -319,6 +319,7 @@ class Market(Location):
def json(self): def json(self):
""" """
JSON representation of the market JSON representation of the market
.. code-block:: json .. code-block:: json
{ {