GithubHelp home page GithubHelp logo

constituency-mapper's Introduction

Constituency Mapper

Constituency Mapper is a Flask-based application designed to manage and visualize constituency data using a MySQL database and Overpass API. The application allows users to mark roads as visited and track leafletters.

Key Features

  • Interactive Map and Database Integration: Visualize and manage constituency data, including roads and their visited status.
  • Leafletter Management: Track activities of leafletters visiting various roads.

Key Functionality

1. Display Constituencies and Roads: The root route (/) displays a table of roads within a specified constituency. Users can mark roads as visited.

2. Display Map: The /map route displays an interactive map of the constituency, showing the roads and their statuses.

Getting Started

Prerequisites

  • Python 3.12

  • MySQL server

  • Poetry

Installation Steps

1. Clone the Repository:

git clone https://github.com/KouroshSimpkins/Constituency-Mapper.git
cd constituency-mapper

2. Install Dependencies:

Ensure you have Poetry installed, then run:

poetry install

3. Set Up MySQL Database:

Ensure your MySQL server is running on localhost.

4. Initialize the Database:

Start the Flask application.

flask -m app run

Then, open a browser and navigate to http://localhost:4000/initdb to initialize the database.

Usage

  • Access the application by navigating to http://localhost:4000 in your web browser.
  • Use the default route to view and update the roads' visited status.
  • Use the /map route to view the interactive map.

Authors

constituency-mapper's People

Contributors

kouroshsimpkins avatar erdincmutlu avatar hannah-o-rourke avatar riku-mito avatar tristanspill avatar

Stargazers

 avatar

Watchers

 avatar

constituency-mapper's Issues

Lightweight Documentation

We Need Documentation!

Would like something a bit more detailed for the README.md, that can outline some key functionality within the code, as well as explaining what the key final outcome is. Improving the documentation will help when bringing new team-members on board, especially as I am not able to attend every single CampaignLab event in person anymore.

It would also be useful to explain how the development environment is set up, in fact I believe that is of the highest importance, to ensure that all developers are working with a database that is always the same shape. For this, there is a function called generate_constituency_database which builds the database, as long as a mysql server is detected on localhost.

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.