Skip to content
This repository was archived by the owner on Aug 10, 2018. It is now read-only.

Conversation

@ckucera3
Copy link

@ckucera3 ckucera3 commented Dec 6, 2015

Added Database and Database Queries

I added a mongodb database. The URL in the code is for a database that I have running in the cloud server of https://mongolab.com. The app assumes that the database used has a collection called courses which contains documents of the following structure:

{
  "subject": "ACCT",
  "number": "2101",
  "description": "Short description.",
  "name": "Accounting I"
}

To access this data from the database, use the same queries used for the static info, with the following change to the route:

/api/db/course/...

For example, api/db/course/ACCT/2101

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should probably be done as configuration either as an env variable or in a file that isn't committed. Note that there are bots that watch github for this kind of thing in order to hijack accounts.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants