rehaul initial building/floor/room generation script
suggested specs:
two input files:
buildings and floors, buildings and rooms
as you iterate through the first file, create building on string, create a floor related to that building on number
for the second file, on string, find the associated building, then match the subsequent rooms to the building's floor based on the starting digits of the room number
I'll leave it up to you whether you want to create a json file or directly i/o with the database
example stuff to look at:
the models in question https://git.gmu.edu/srct/roomlist/blob/master/roomlist/housing/models.py
input example https://git.gmu.edu/srct/roomlist/blob/master/roomlist/housing/room-numbers
json generation https://git.gmu.edu/srct/roomlist/blob/master/roomlist/housing/room-numbers.py
final json output https://git.gmu.edu/srct/roomlist/blob/master/roomlist/housing/initial_data.json
or alternatively, writing to the database: https://git.gmu.edu/srct/roomlist/blob/master/roomlist/accounts/demo_users.py
json is basically just a big ol' dictionary
outside docs:
Django on fixtures: https://docs.djangoproject.com/en/1.8/howto/initial-data/#providing-initial-data-with-fixtures
python file input and output: https://docs.python.org/2/tutorial/inputoutput.html
parsing json with python: https://docs.python.org/2/library/json.html