Coder Social home page Coder Social logo

bike-share's People

Contributors

case-eee avatar cpowell23 avatar ethanbennett avatar mollybrown avatar s-espinosa avatar tmikeschu avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

bike-share's Issues

I3 - Add methods to station model for dashboard calculations AND tests in Station model.

  • Total count of stations: Station.count
  • Average bikes available per station (based on docks): Station.average(:dock_count)
  • Most bikes available at a station: Station.maximum(:dock_count)
  • Station(s) where the most bikes are available:
  • Fewest bikes available at a station: Station.minimum(:dock_count)
  • Station(s) where the fewest bikes are available:
  • Most recently installed station: Station.order(:installation_date).first
  • Oldest station: Station.order(:installation_date).last

ALSO add testing to station model

Add DatabaseCleaner gem and strategy to project

You'll want to set up the DatabaseCleaner gem in order to have a clean database each time you run tests. Follow the instructions for setting up the gem. Due to a bug in the most recent version of the gem, you'll need to use this line when you set the strategy in your test helper file:

DatabaseCleaner.strategy = :truncation

I4 - Create Trip model

Remember to add validations for each Trip attribute (presence: true):

  • Duration
  • Start Date
  • Start Station
  • End Date
  • End Station
  • Bike ID
  • Subscription Type
  • Zip Code

I4 - Create view: trips index

When a user visits the /trips path, they should only see the first thirty trips taken organized by date. On that page, there should also be a button to see the next thirty trips.

Once a user visits a second page, there should be buttons to move both forward and backward in time.

Users should be able to delete a trip from this view.

I3 - Create view: station dashboard

Display the following information:

  • Total count of stations.
  • Average bikes available per station (based on docks).
  • Most bikes available at a station.
  • Station(s) where the most bikes are available.
  • Fewest bikes available at a station.
  • Station(s) where the fewest bikes are available.
  • Most recently installed station.
  • Oldest station.

Add analysis methods for trips dashboard

Create a trips dashbord route. When you visit /trips-dashboard users should be shown a page with the following information:
Average duration of a ride.
Longest ride.
Shortest ride.
Station with the most rides as a starting place.
Station with the most rides as an ending place.
Month by Month breakdown of number of rides with subtotals for each year.
Most ridden bike with total number of rides for that bike.
Least ridden bike with total number of rides for that bike.
User subscription type breakout with both count and percentage.
Single date with the highest number of trips with a count of those trips.
Single date with the lowest number of trips with a count of those trips.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.