Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create "map" card #17

Open
nathanmsmith opened this issue Nov 13, 2022 · 1 comment
Open

Create "map" card #17

nathanmsmith opened this issue Nov 13, 2022 · 1 comment
Assignees
Labels
enhancement New feature or request rails scraper

Comments

@nathanmsmith
Copy link
Member

With classes going back in person, let's create a "map" card that says which classroom a section is is and shows it on the map. That way, hopefully students don't make the same mistake I did once in confusing PAB (Physics and Astronomy) with PUB (Public Affairs).

Inspo: https://nathansmith.io/exploring-enrollment/classroom-utilization

We probably want a dropdown of current sections, the map can be done with leaflet + React?

We'll want to create a database for buildings and rooms to support this. A building has many rooms. A section can have many rooms (not sure if we want to create that relation yet though, as the registrar rooms don't always correspond to official room names)

I scraped buildings and rooms previously:

https://github.com/nathunsmitty/ucla-registrar-scraper/blob/master/scrape-buildings-and-rooms/script.py
https://github.com/nathunsmitty/ucla-registrar-scraper/blob/master/database/patch0013.sql

@lzhou0714 lzhou0714 self-assigned this Feb 10, 2023
@nathanmsmith
Copy link
Member Author

Breaking this down into steps:

  1. Find the URLs and endpoints that we want to scrape.
  2. Write a small scraper in either Ruby or Go
  • Ruby: lib/scrapers/
  • Go: lambdas
  • Goal: get data into format we can save in database
  1. Save the data into the database
  • Figure out what data we have and what we want to save
  • Create Rails models
  • Update the scrapers to actually save our scraped data into the database
  1. Figure out how the new data relates to the current data
  • Write model migrations as needed
  1. Create a frontend component to be the map
  • Write a frontend component
  • Plumb through data from Rails backend to frontend

@nathanmsmith nathanmsmith added enhancement New feature or request scraper rails labels Mar 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request rails scraper
Projects
None yet
Development

No branches or pull requests

2 participants