Skip to content

smallfurrr/kopi-tracker

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 

Repository files navigation

kopi-tracker

You are working at a kopi roastery. Create a rails app that tracks kopis.

Each individual kopi has a name and roastedness (roast), and is associtaed with an origin (farm where it comes from).

A kopi farm (origin) has a location, phone number and is associated with many kopis.

further

Migrate your app to track roastedness in a separate table. Use the seed.rb file to put the 7 kinds of roast into the DB.

roasts

Each kopi will have a roast.

A roast will have many kopis.

Using your models will look something like this:

# get all kopis that are dark roast
Roast.find_by(name: "Italian").kopis

further

Change your db model to include an order for a kopi. Change your kopi table to track price per pound. Add an order model. A kopi order has a weight. It is associated with a kopi.

further

For the routes /orders and /orders/:id include the total price of each order. (weight * price per pound)

further

Create a /report route that will display sales data.

In order to have data to display you should add more kopis and orders into your database from a seed file.

/report should display the total sales for that day.

further

Change /report to also display sales by kopi.

further

Change /report to also display sales by origin.

About

[rails][ruby] track coffees and coffee origins

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Ruby 66.2%
  • HTML 30.7%
  • JavaScript 1.6%
  • CSS 1.2%
  • CoffeeScript 0.3%