Pivot table for PHP PivotData Microservice Documentation
Doesn't matter what framework you use (Laravel, Yii, Symphony), with PivotData microservice pivot tables may be easily added to any PHP application with the following steps:
- Deploy PivotData microservice to your server (Linux is ok!) and configure your data sources in
- For canned reports: use microservice's web API from your web pages or PHP code
curl_execor guzzle library)
- For web pivot tables builder: integrate HTML/JS code from
index.html(shipped in PivotData microservice package)
What is next:
- secure access to microservice web API with JSON Web Token. JWT can be easily generated with
$token = [ "user" => $currentUserId, "iss" => $jwtIssuer, "exp" => strtotime("+10 year") ]; $pvtDataServiceJwt = JWT::encode($token, $jwtIssuerSigningKeyStr);
- provide cubes config dynamically with an URL that is served by your main PHP app.
In this way you can implement access control individually for each user (see
integration\Php\htdocs\get-cube-schema-by-jwt.phpfrom integration example).
Complete source code of PHP pivot table integration you can found in PivotData microservice trial pack.