2017 © Pedro Peláez
 

yii-extension yii-swivel

A Yii plugin to provide easy access and integration with zumba/swivel

image

dhluther/yii-swivel

A Yii plugin to provide easy access and integration with zumba/swivel

  • Sunday, March 20, 2016
  • by DanaLuther
  • Repository
  • 1 Watchers
  • 2 Stars
  • 118 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 3 Versions
  • 5 % Grown

The README.md

Yii Extension for Zumba Swivel

This plugin provides the necessary elements for using Swivel in a Yii 1.1+ Application., (*1)

This plugin is based on the zumba/swivel-cake plugin., (*2)

Configuration for Yii Component:

By default, the component is assumed to be under the /protected/vendors/ directory, if your composer.json is under the protected folder. If you need to change that location, simply update the extensionAlias in the configuration array., (*3)

 'swivel' => [ 
    'class'=>'SwivelComponent' 
 ],

```php 'swivel' => [ 'class'=>'SwivelComponent', 'extensionAlias'=>'application.extensions.swivel', ],, (*4)


### Access from the application ```php // If the user has the feature behavior bucket enabled, use the testFeature.New.Something behavior, // else use the default Yii::app()->swivel->forFeature( 'testFeature' ) ->addBehavior('New.Something', [$this,'doSomethingB'], $args) ->defaultBehavior([$this, 'doSomethingA'], $args ) ->execute(); // If the user has the feature behavior bucket enabled, use the first callable, // else use the second callable (default) Yii::app()->swivel->invoke('testFeature.New.Something', [$this,'doSomethingB'],[$this, 'doSomethingA']);

Make sure that your bootstrap file is set to properly include the composer autoloader. This extension assumes that your vendor directory is under the protected folder, so if that is not the case, please make sure you adjust the paths accordingly in the require and configuration options., (*5)

In the index.php bootstrap:, (*6)

require(__DIR__ . '/protected/vendor/autoload.php');

The Swivel Libraries

https://github.com/zumba/swivel, (*7)

https://github.com/zumba/swivel-cake, (*8)

The Versions

20/03 2016

dev-master

9999999-dev https://github.com/DanaLuther/yii-swivel

A Yii plugin to provide easy access and integration with zumba/swivel

  Sources   Download

MIT

The Requires

 

component extension helper yii behavior swivel

19/03 2016

1.0.1

1.0.1.0 https://github.com/DanaLuther/yii-swivel

A Yii plugin to provide easy access and integration with zumba/swivel

  Sources   Download

MIT

The Requires

 

component extension helper yii behavior swivel

18/03 2016

1.0.0

1.0.0.0 https://github.com/DanaLuther/yii-swivel

A Yii plugin to provide easy access and integration with zumba/swivel

  Sources   Download

MIT

The Requires

 

component extension helper yii behavior swivel