Skip to content

Commit

Permalink
Modifications in service provider
Browse files Browse the repository at this point in the history
  • Loading branch information
aginev-fos committed Jun 25, 2015
1 parent 9941a04 commit bd7bd16
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions src/DatagridServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ public function boot() {

$this->publishes([
__DIR__ . '/Views' => base_path('resources/views/vendor/datagrid'),
]);
base_path('vendor/aginev/datagrid/src/Views') => base_path('resources/views/vendor/datagrid'),
], 'views');
}

/**
Expand All @@ -26,10 +27,15 @@ public function boot() {
* @return void
*/
public function register() {
$this->app->register('Illuminate\Html\HtmlServiceProvider');
// Register the HtmlServiceProvider
App::register('Illuminate\Html\HtmlServiceProvider');

AliasLoader::getInstance()->alias("Form", 'Illuminate\Html\FormFacade');
AliasLoader::getInstance()->alias("Html", 'Illuminate\Html\HtmlFacade');
AliasLoader::getInstance()->alias("Datagrid", 'Aginev\Datagrid\Datagrid');
// Add aliases to Form/Html Facade
$loader = AliasLoader::getInstance();
$loader->alias('Form', 'Illuminate\Html\FormFacade');
$loader->alias('HTML', 'Illuminate\Html\HtmlFacade');

// Add alias for datagrid
$loader->alias('Datagrid', 'Aginev\Datagrid\Datagrid');
}
}

0 comments on commit bd7bd16

Please sign in to comment.