wikiworldorder/survlooporg

SurvLoop is a Laravel-based engine for designing a database and creating a mobile-friendly user interface to fill it.

v0.2.1 2019-04-25 22:19 UTC

This package is auto-updated.

Last update: 2020-01-10 21:32:55 UTC


README

Laravel SurvLoop License

SurvLoop, atop Laravel. SurvLoop is a Laravel-based engine for designing a database and creating a mobile-friendly user interface to fill it.

Table of Contents

Requirements

Getting Started

Install a copy of SurvLoop.org with Laradock

First, install Docker on Mac, Windows, or an online server. Then grab a copy of Laravel (last tested with v5.8.3)...

$ git clone https://github.com/laravel/laravel.git survlooporg
$ cd survlooporg

Next, install and boot up Laradock (last tested with v7.14).

$ git submodule add https://github.com/Laradock/laradock.git
$ cd laradock
$ cp env-example .env
$ docker-compose up -d nginx mysql phpmyadmin redis workspace

After Docker finishes booting up your containers, enter the mysql container with the root password, "root". This seems to fix things for the latest version of MYSQL.

$ docker-compose exec mysql bash
# mysql --user=root --password=root default
mysql> ALTER USER 'default'@'%' IDENTIFIED WITH mysql_native_password BY 'secret';
mysql> exit;
$ exit

At this point, you can optionally browse to http://localhost:8080 for PhpMyAdmin.

Server: mysql
Username: default
Password: secret

Finally, enter Laradock's workspace container and install SurvLoop.org.

$ docker-compose exec workspace bash
# cp .env.example .env
# nano .env

Edit these few lines in Laravel's environment file:

DB_HOST=mysql
DB_DATABASE=default
DB_USERNAME=default

And continue the install...

# composer install
# php artisan key:generate
# php artisan make:auth
# composer require wikiworldorder/survlooporg
# echo "0" | php artisan vendor:publish --force
# composer dump-autoload
# php artisan optimize
# sed -i 's/App\\User::class/App\\Models\\User::class/g' config/auth.php
# php artisan migrate
# php artisan optimize
# composer dump-autoload
# php artisan db:seed --class=SurvLoopSeeder
# php artisan db:seed --class=SurvLoopOrgSeeder

And if all has gone well, you'll be asked to create a master admin user account when you browse to http://localhost/. If it loads, but looks janky (without CSS), reload the page once... and hopefully it looks like a fresh install.

Install a copy of SurvLoop.org without Laradock

  • Use Composer to install Laravel with default user authentication, one required package:
$ composer global require "laravel/installer"
$ composer create-project laravel/laravel survlooporg "5.8.*"
$ cd survlooporg
$ php artisan key:generate
$ php artisan make:auth
$ composer require wikiworldorder/survlooporg
$ sed -i 's/App\\User::class/App\\Models\\User::class/g' config/auth.php
  • Update composer, publish the package migrations, etc...
$ echo "0" | php artisan vendor:publish --force
$ php artisan migrate
$ composer dump-autoload
$ php artisan db:seed --class=SurvLoopSeeder
$ php artisan db:seed --class=SurvLoopOrgSeeder
  • For now, to apply database design changes to the same installation you are working in, depending on your server, you might also need something like this...
$ chown -R www-data:33 app/Models
$ chown -R www-data:33 database
  • Load in the browser to create super admin account and get started.

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 .

More can be found at https://survloop.org/package-files-folders-classes.

Roadmap

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

  • Complete statistics on various SurvLoop installations
  • Code commenting, learning and implementing more community standards.

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.