GithubHelp home page GithubHelp logo

loudmouse / water_tanks Goto Github PK

View Code? Open in Web Editor NEW
3.0 1.0 2.0 9.63 MB

📍Help map historical water tanks in the city of Chicago. Happy mapping!

Home Page: http://www.chicagowatertanks.com

Ruby 63.93% JavaScript 2.60% CSS 15.17% HTML 18.17% CoffeeScript 0.14%

water_tanks's Introduction

Chicago Water Tanks

The city of Chicago was once home to hundreds of water tanks. They are quickly disappearing from the skyline as they are be taken down across the city. This project is an attempt to map, photograph, and document as many of these water tanks before they're gone forever.

For a live version, visit: Chicago Water Tanks


Getting Started

These instructions will get you a copy of the project up and running on your local machine.


Prerequisites

You'll need Ruby installed on your local machine. We're using:

ruby 2.5.0p0

You'll also need Rails installed on your local machine. We're using:

Rails 5.1.6

You'll also want to create a Google Maps API - its free. You can create one here: Google Maps API Key


Installing

To install and play around with Chicago Water Tanks on your local machine follow these steps:

  1. Visit the repository: Chicago Water Tanks on GitHub

  2. Clone the repository (for more details on this step visit this resource. From your command line, type:

git clone https://github.com/loudmouse/water_tanks.git
  1. Run bundle install to ensure you have the correct gems and versions to begin work. From your command line, type:
bundle install
  1. From your command line, start your rails server by typing:
rails server
  1. Install the database. From your command line, type:
rails db:install
  1. Seed the database with sample data. The sample data includes water tank locations, photos, and two users (1 admin and one non-admin). From your command line, type:
rails db:seed
  1. From your browser, visit: http://localhost:3000/

You should now have a functioning build of Chicago Water Tanks on your local machine to play around with.


Deployment

We're currently deployed to Heroku. You can setup a free Heroku account and deploy your app there as well if you'd like.


Built With

  • Ruby - The programming language used
  • Rails - The framework used
  • Google Maps API - Used to generate maps
  • GMaps4Rails - A gem used for custom markers and overlays; integrates with Google Maps API
  • Geocoder - Ruby gem used to convert a water tank's lat/long location coordinates to addresses and vice versa
  • Chicago Neighborhood KML Overlay - courtesy Chicago Open Data Portal - KML overlay layer used to identify which neighborhood a water tank belongs to
  • RSpec - framework for testing
  • Shoulda Matchers - one liners to test common rails functionality
  • Factory Bot - Ruby library used to build factories for generating fixtures for testing
  • Faker - used to generate fake data for testing
  • SimpleCov - code coverage analysis
  • PostgreSQL - The database used with ActiveRecord
  • Devise - The Ruby Gem used for authentication
  • Rails Admin - Ruby gem provides easy-to-use admin interface for CRUD actions for non-technical users. We can grant admin rights to other users to help us moderate the community contributions.
  • Paperclip - Ruby gem used for attaching images of water tanks
  • AWS SDK for Ruby - used to connect to AWS S3 storage for storing images of water tanks
  • Acts as Votable - Ruby gem used to allow voting of favorite water tank photos
  • Will Paginate - Ruby gem used to paginate the list of water tank locations
  • SCSS (Sassy CSS) - The CSS syntax used for front-end styling
  • Bootstrap - CSS framework used for styling certain sections of the application
  • FriendlyID - a ruby gem used to create human readable slugs/permalinks. For this app we're using it for usernames so instead of navigating to, for example, /users/1 it will now read as /users/loudmouse and provide automatic redirects if you attempt to visit the old link.

Versioning

Chicago Water Tanks is currently at version 1.0.


Authors

See also the list of contributors who participated in this project.


Features

Homepage

This is the homepage where you see the most recently mapped tank, the map of tanks, and a listing of all tanks with pagination.

Chicago Water Tanks - Home


Map a Water Tank

Click 'Add a Water Tank' to map the location of a new water tank and add your photo.

  1. Zoom in and click the map to set a pin - a pin drop does a couple things:
  • It detects the latitudinal and longitudinal coordinates of the pin
  • It converts these coordinates into a human readable address and fills the address field
  • It detects which neighborhood your water tank belongs within and displays this info once you've hit submit
  1. Click 'Upload a Photo' to attach a photo. A photo is required.
  2. Click 'Submit'

Congratulations, you've successfully mapped a water tank and added a photo!

Chicago Water Tanks - Add a Tank


Unlock Your Profile

Once you've created an account you'll gain access to your profile once you've mapped a water tank. From your profile you can:

  • See how many water tanks you've mapped
  • Check how many photos you've contributed
  • See a map with all the water tanks you've mapped

Chicago Water Tanks - Unlock Your Profile

water_tanks's People

Contributors

loudmouse avatar jalletto avatar iorme1 avatar

Stargazers

lihui avatar Karl L. Hughes avatar  avatar

Watchers

 avatar

Forkers

jalletto iorme1

water_tanks's Issues

Add tank on mobile doesn't work

When on a mobile device a user is unable to touch the map and add a tank. Something for us to explore since I imagine most users will be doing this from their phones.

neighborhoods

  • identify a neighborhood when creating a new tank location
  • ability to sort tank locations by neighborhood
  • use KML layer to identify neighborhood
  • hide KML layer from user so it is used more for boundary info

add delete

  • ability to delete a photo - only the photo owner can delete his/her photos
  • ability to delete a tank location (only admin can approve a location delete)
  • ability for user to flag a tank location that no longer exists

sort votes

  • add sorting to votable on tank location show page

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.