Open Police is an open-source web app empowering citizens to prepare, file, and track reports of police conduct. The site helps users submit complaints or commendations to appropriate police oversight agencies. By allowing users to publish reports online, we aim to establish better public transparency and oversight of police activity in the U.S..
PHP HTML
Latest commit 5c22bf2 Feb 15, 2017 @wikiworldorder wikiworldorder Loops within pages, Loop sorting
…and countless other fixes, etc.
Permalink
Failed to load latest commit information.
src
LICENSE
README.md
composer.json

README.md

FlexYourRights/OpenPolice

Laravel SurvLoop License

Open Police is an open-source web app empowering citizens to prepare, file, and track reports of police conduct. The site helps users submit complaints or commendations to appropriate police oversight agencies. By allowing users to publish reports online, we aim to establish better public transparency and oversight of police activity in the U.S.. Open Police is built using SurvLoop, atop Laravel. https://openpolicecomplaints.org

Table of Contents

Requirements

Getting Started

Here are instructions if you are new to Laravel, or just want step-by-step instructions on how to install its development environment, Homestead: OpenPoliceComplaints.org/how-to-install-laravel/.

The instructions below include the needed steps to install SurvLoop, as well as the Open Police system.

  • Install Laravel's default user authentication, one required package, and SurvLoop:
$ php artisan make:auth
  • Update composer.json to add requirements and an easier SurvLoop and OpenPolice reference:
$ nano composer.json
...
"require": {
    ...
    "wikiworldorder/survloop": "0.*",
    "flexyourrights/openpolice": "0.*",
    ...
},
...
"autoload": {
    ...
    "psr-4": {
        ...
        "SurvLoop\\": "vendor/wikiworldorder/survloop/src/",
        "OpenPolice\\": "vendor/flexyourrights/openpolice/src/",
    }
    ...
},
...
$ composer update
  • Add the package to your application service providers in config/app.php.
$ nano config/app.php
...
'providers' => [
    ...
    SurvLoop\SurvLoopServiceProvider::class,
    OpenPolice\OpenPoliceServiceProvider::class,
    ...
],
...
'aliases' => [
    ...
    'SurvLoop'   => 'WikiWorldOrder\SurvLoop\SurvLoopFacade',
    ...
],
...
  • Swap out the SurvLoop user model in config/auth.php.
$ nano config/auth.php
...
'model' => App\Models\User::class,
...
  • Update composer, publish the package migrations, etc...
$ php artisan vendor:publish --force
$ php artisan migrate
$ composer dump-autoload
$ php artisan db:seed --class=SurvLoopSeeder
$ php artisan db:seed --class=OpenPoliceSeeder
$ php artisan db:seed --class=OpenPoliceDepartmentSeeder
  • Log into Open Police admin dashboard...
user: open@openpolice.org
password: openpolice

Documentation

Once installed, documentation of this system's database design can be found at /dashboard/db/all . This system's user experience design for data entry can be found at /dashboard/tree/map?all=1&alt=1 .

Roadmap

Here's the TODO list for the next release (1.0). It's my first time building on Laravel, or GitHub. So sorry.

  • Code commenting, learning and implementing more community standards.
  • Correct collection of issues still on my list.
  • Adding unit testing.
  • Basic database design and user experience processes are generated by SurvLoop itself.
  • Finish migrating all queries to use Laravel's process.

Change Logs

Contribution Guidelines

Please help educate me on best practices for sharing code in this community. Please report any issue you find in the issues page.