Download the PHP package akvo/akvo-flow-php-sdk without Composer
On this page you can find all versions of the php package akvo/akvo-flow-php-sdk. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package akvo-flow-php-sdk
Akvo Flow PHP SDK
This package generates Database Migrations and ORM Models.
Easily to use for developing custom website based on Akvo Flow data.
Report Bug
·
Request Feature
·
Request Consultancy
System requirements
You must have the following tools on the command line of your host operating system:
Prerequisites
To quickly install Composer in the current directory, run the following script in your terminal.
-
Install Composer
- Create new Laravel Project
Installation
Create your new Laravel project then add the package to composer.json
.
or you can also directly run the composer command:
Usage
Setup .env file
In your project simply add the following environment variables to start using Akvo Flow API
More details:
Running Commands
To view a list of all available Akvo Flow commands, you may use the list command with php artisan
- Laravel Artisan.
akvo:migrate
, Migrate DB Schema to store Akvo Flow contents.akvo:seed
, Seed Database with Akvo Flow data via Akvo Flow REST APIakvo:seed --only-surveys
, Seed surveys without it's datapoints.
Database Schema
Once you run php artisan akvo:migrate
you will see several tables migrated to your Database.
Eloquent ORM
The Eloquent ORM included with the package provides a simple ActiveRecord implementation for working with your Akvo Flow database. Each database table has a corresponding "Model" which is used to interact with the table. You can load all the Akvo Flow Models directly to your Controller.
If you wish to extend different Schema to Models, you could also extend them into your Model directory (Laravel 7+).
Before:
Extend App\Model
, adding new object named short:
Results:
Rollback
To roll back the latest migration operation, you may have to run php artisan migrate:reset
or you could also re-run php artisan akvo:migrate
.
About Akvo
Akvo is a not-for-profit internet and software developer, headquartered in Amsterdam, Netherlands. The foundation specializes primarily in building and operating data collection and visualization systems to be used in international development and aid activity.
Akvo Flow
Akvo Flow is a tool for collecting, evaluating and displaying of geographically referenced data. It is composed of an android mobile app and an online web-based platform. This repository contains code for the web-based platform that comprises a backend engine and a dashboard user interface. Alongside the dashboard and mobile apps, is a data import and export component.
Akvo Tech Consultancy
Akvo offers data consultancy and a digital platform, to support our partner's design their projects with building something on-top, the solutions are built with robust products like Akvo’s as the core workhorse, and then a layer of customisations which goes sufficiently close to aligning with the partner requirements.