diff --git a/composer.json b/composer.json index df8ff45..ae3ad7b 100644 --- a/composer.json +++ b/composer.json @@ -14,9 +14,9 @@ ], "require": { "php": ">=5.3.0", - "illuminate/support": "4.*", - "illuminate/view": "4.*", - "illuminate/config": "4.*" + "illuminate/support": "~5.0", + "illuminate/view": "~5.0", + "illuminate/config": "~5.0" }, "require-dev": { "phpunit/phpunit": "3.7.*", diff --git a/src/Chumper/Datatable/DatatableServiceProvider.php b/src/Chumper/Datatable/DatatableServiceProvider.php index b7c8968..673e396 100644 --- a/src/Chumper/Datatable/DatatableServiceProvider.php +++ b/src/Chumper/Datatable/DatatableServiceProvider.php @@ -12,9 +12,18 @@ class DatatableServiceProvider extends ServiceProvider { */ protected $defer = false; + /** + * Bootstrap the application events. + * + * @return void + */ public function boot() { - $this->package('chumper/datatable'); + $this->publishes([ + __DIR__.'/../../config/config.php' => config_path('packages/chumper_datatable.php'), + ]); + + $this->loadViewsFrom(__DIR__.'/../../', 'Chumper'); } /** @@ -40,4 +49,4 @@ public function provides() return array('datatable'); } -} \ No newline at end of file +} diff --git a/src/Chumper/Datatable/Engines/BaseEngine.php b/src/Chumper/Datatable/Engines/BaseEngine.php index ef030a5..b2554f1 100644 --- a/src/Chumper/Datatable/Engines/BaseEngine.php +++ b/src/Chumper/Datatable/Engines/BaseEngine.php @@ -127,7 +127,7 @@ abstract class BaseEngine { function __construct() { $this->columns = new Collection(); - $this->config = Config::get('datatable::engine'); + $this->config = Config::get('chumper_datatable.engine'); $this->setExactWordSearch( $this->config['exactWordSearch'] ); return $this; } diff --git a/src/Chumper/Datatable/Table.php b/src/Chumper/Datatable/Table.php index 651d34d..c5514fe 100644 --- a/src/Chumper/Datatable/Table.php +++ b/src/Chumper/Datatable/Table.php @@ -80,7 +80,7 @@ class Table { function __construct() { - $this->config = Config::get('datatable::table'); + $this->config = Config::get('packages.chumper_datatable.table'); $this->setId( $this->config['id'] ); $this->setClass( $this->config['class'] ); diff --git a/src/config/config.php b/src/config/config.php index 9212bab..4b4ea30 100644 --- a/src/config/config.php +++ b/src/config/config.php @@ -93,7 +93,7 @@ | */ - 'table_view' => 'datatable::template', + 'table_view' => 'Chumper::views.template', /* @@ -106,7 +106,7 @@ | */ - 'script_view' => 'datatable::javascript', + 'script_view' => 'Chumper::views.javascript', ), diff --git a/src/views/javascript.blade.php b/src/views/javascript.blade.php index ec23629..7c2df24 100644 --- a/src/views/javascript.blade.php +++ b/src/views/javascript.blade.php @@ -1,14 +1,14 @@