@@ -20,7 +20,7 @@ |
||
| 20 | 20 | */ |
| 21 | 21 | public function attachments() |
| 22 | 22 | { |
| 23 | - return $this->morphToMany( Attachment::class, 'attachable' )->orderBy('is_main', 'desc'); |
|
| 23 | + return $this->morphToMany(Attachment::class, 'attachable')->orderBy('is_main', 'desc'); |
|
| 24 | 24 | } |
| 25 | 25 | |
| 26 | 26 | public function getAttachment() { |
@@ -19,6 +19,6 @@ |
||
| 19 | 19 | |
| 20 | 20 | public function attachments() |
| 21 | 21 | { |
| 22 | - return $this->morphToMany( Attachment::class, 'attachable' )->orderBy('is_main', 'desc'); |
|
| 22 | + return $this->morphToMany(Attachment::class, 'attachable')->orderBy('is_main', 'desc'); |
|
| 23 | 23 | } |
| 24 | 24 | } |
@@ -37,13 +37,13 @@ discard block |
||
| 37 | 37 | // - first the published views (in case they have any changes) |
| 38 | 38 | $this->loadViewsFrom(resource_path('views/vendor/back-project/base'), 'back-project'); |
| 39 | 39 | // - then the stock views that come with the package, in case a published view might be missing |
| 40 | - $this->loadViewsFrom(__DIR__ . '/../resources/views', 'back-project'); |
|
| 40 | + $this->loadViewsFrom(__DIR__.'/../resources/views', 'back-project'); |
|
| 41 | 41 | // Load Translations |
| 42 | - $this->loadTranslationsFrom(__DIR__ . '/../resources/lang', 'back-project'); |
|
| 42 | + $this->loadTranslationsFrom(__DIR__.'/../resources/lang', 'back-project'); |
|
| 43 | 43 | |
| 44 | 44 | // use the vendor configuration file as fallback |
| 45 | 45 | $this->mergeConfigFrom( |
| 46 | - __DIR__ . '/../config/config.php', 'back-project' |
|
| 46 | + __DIR__.'/../config/config.php', 'back-project' |
|
| 47 | 47 | ); |
| 48 | 48 | |
| 49 | 49 | $this->routes($router); |
@@ -67,15 +67,15 @@ discard block |
||
| 67 | 67 | return new BackProject($app); |
| 68 | 68 | });*/ |
| 69 | 69 | |
| 70 | - $this->app->singleton('attachments-manager', function ($app) { |
|
| 70 | + $this->app->singleton('attachments-manager', function($app) { |
|
| 71 | 71 | return new MediaManager(); |
| 72 | 72 | }); |
| 73 | 73 | |
| 74 | - $this->app->singleton('back-project', function ($app) { |
|
| 74 | + $this->app->singleton('back-project', function($app) { |
|
| 75 | 75 | return new BackProject(); |
| 76 | 76 | }); |
| 77 | 77 | |
| 78 | - $this->app->singleton('slug-generator', function ($app) { |
|
| 78 | + $this->app->singleton('slug-generator', function($app) { |
|
| 79 | 79 | return new SlugGenerator(); |
| 80 | 80 | }); |
| 81 | 81 | |
@@ -113,15 +113,15 @@ discard block |
||
| 113 | 113 | public function publishFiles() |
| 114 | 114 | { |
| 115 | 115 | // publish config file |
| 116 | - $this->publishes([__DIR__ . '/../config/config.php' => config_path() . '/back-project.php'], 'config'); |
|
| 116 | + $this->publishes([__DIR__.'/../config/config.php' => config_path().'/back-project.php'], 'config'); |
|
| 117 | 117 | // publish lang files |
| 118 | - $this->publishes([__DIR__ . '/../resources/lang' => resource_path('lang/vendor/back-project')], 'lang'); |
|
| 118 | + $this->publishes([__DIR__.'/../resources/lang' => resource_path('lang/vendor/back-project')], 'lang'); |
|
| 119 | 119 | // publish public BackProject assets |
| 120 | - $this->publishes([__DIR__ . '/../public' => public_path('vendor/back-project')], 'public'); |
|
| 120 | + $this->publishes([__DIR__.'/../public' => public_path('vendor/back-project')], 'public'); |
|
| 121 | 121 | // publish views |
| 122 | - $this->publishes([__DIR__ . '/../resources/views' => resource_path('views/vendor/back-project')], 'views'); |
|
| 122 | + $this->publishes([__DIR__.'/../resources/views' => resource_path('views/vendor/back-project')], 'views'); |
|
| 123 | 123 | // publish error views |
| 124 | - $this->publishes([__DIR__ . '/../resources/error_views' => resource_path('views/errors')], 'errors'); |
|
| 124 | + $this->publishes([__DIR__.'/../resources/error_views' => resource_path('views/errors')], 'errors'); |
|
| 125 | 125 | // publish public AdminLTE assets |
| 126 | 126 | $this->publishes(['vendor/almasaeed2010/adminlte/bootstrap' => public_path('vendor/adminlte/bootstrap')], 'adminlte'); |
| 127 | 127 | $this->publishes(['vendor/almasaeed2010/adminlte/dist' => public_path('vendor/adminlte/dist')], 'adminlte'); |
@@ -136,7 +136,7 @@ discard block |
||
| 136 | 136 | //$router->aliasMiddleware('guest', \Afrittella\BackProject\Http\Middleware\RedirectIfAuthenticated::class); |
| 137 | 137 | $router->aliasMiddleware('role', \Afrittella\BackProject\Http\Middleware\Role::class); |
| 138 | 138 | |
| 139 | - $this->loadRoutesFrom(__DIR__ . '/../routes/web.php'); |
|
| 139 | + $this->loadRoutesFrom(__DIR__.'/../routes/web.php'); |
|
| 140 | 140 | } |
| 141 | 141 | |
| 142 | 142 | public function handleMigrations() |
@@ -146,8 +146,8 @@ discard block |
||
| 146 | 146 | $timestamp = date('Y_m_d_His', time()); |
| 147 | 147 | |
| 148 | 148 | $this->publishes([ |
| 149 | - __DIR__ . '/../database/migrations/' . $file . '.php' => |
|
| 150 | - database_path('migrations/' . $timestamp . '_' . $file . '.php') |
|
| 149 | + __DIR__.'/../database/migrations/'.$file.'.php' => |
|
| 150 | + database_path('migrations/'.$timestamp.'_'.$file.'.php') |
|
| 151 | 151 | ], 'migrations'); |
| 152 | 152 | } |
| 153 | 153 | } |
@@ -187,7 +187,7 @@ discard block |
||
| 187 | 187 | public function loadHelpers() |
| 188 | 188 | { |
| 189 | 189 | foreach ($this->helpers as $helper): |
| 190 | - $file = __DIR__ . '/Helpers/' . $helper . '.php'; |
|
| 190 | + $file = __DIR__.'/Helpers/'.$helper.'.php'; |
|
| 191 | 191 | |
| 192 | 192 | if (file_exists($file)) { |
| 193 | 193 | require_once($file); |