2017 © Pedro Peláez
 

yii2-extension yii2-versioning

Extensions for Yii2 for data versioning and watching

image

amilna/yii2-versioning

Extensions for Yii2 for data versioning and watching

  • Wednesday, November 25, 2015
  • by aaiyo
  • Repository
  • 5 Watchers
  • 7 Stars
  • 115 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 7 Forks
  • 3 Open issues
  • 1 Versions
  • 2 % Grown

The README.md

Data Versioning and CRUD Watching

Extensions for Yii2 for data versioning and CRUD watching. You can manage data version history that edited by user and manage user/group access at record level., (*1)

Installation

The preferred way to install this extension is through composer., (*2)

Since this package do not have stable release on packagist, you should use these settings in your composer.json file :, (*3)

"minimum-stability": "dev",
"prefer-stable": true,

After, either run, (*4)

php composer.phar require --prefer-dist amilna/yii2-versioning "dev-master"

or add, (*5)

"amilna/yii2-versioning": "dev-master"

to the require section of your composer.json file., (*6)

run migration for database, (*7)

./yii migrate --migrationPath=@amilna/versioning/migrations

add in bootstrap section of main config, (*8)

    'bootstrap' => [
        ...
        'amilna\versioning\components\Versioning',
        ...
        ],   

add in modules section of main config, (*9)

    'gridview' =>  [
        'class' => 'kartik\grid\Module',
    ],
    'versioning' => [
        'class' => 'amilna\versioning\Module',
        'userClass' =>  'dektrium\user\models\User',//'common\models\User',            
        'defaults' => ["create"=>"create","view"=>"view"],
        //'onroutes' => ['yes/product','blog/post/update'], /* example to apply versioning on certain routes only */
        //'onmodels' => ['amilna\blog\models\BlogCatPos'], /* example to apply versioning on certain models only */
    ]

Usage

Once the extension is installed, check the url: [your application base url]/index.php/versioning, (*10)

Try it with edit some active record model an see the version that automatically created., (*11)

To use notification widget (it will inform you what has changed), just put in your view, (*12)

    <?php
        echo amilna\versioning\widgets\Notification::widget();              
    ?>

The Versions

25/11 2015

dev-master

9999999-dev

Extensions for Yii2 for data versioning and watching

  Sources   Download

BSD-3-Clause

The Requires

 

by Satrio Arditama

extension yii2 crud data versioning notif