@@ -41,8 +41,8 @@ |
||
| 41 | 41 | |
| 42 | 42 | protected function getUpdateRules() |
| 43 | 43 | { |
| 44 | - $key = \Request::get($this->model->getKeyName()); |
|
| 45 | - static::$rules_update['initials'] = 'required|unique:roles,initials,' . $key; |
|
| 44 | + $key = \Request::get($this->model->getKeyName()); |
|
| 45 | + static::$rules_update['initials'] = 'required|unique:roles,initials,'.$key; |
|
| 46 | 46 | |
| 47 | 47 | return parent::getUpdateRules(); |
| 48 | 48 | } |
@@ -47,15 +47,15 @@ discard block |
||
| 47 | 47 | { |
| 48 | 48 | $allModels = [ |
| 49 | 49 | [ |
| 50 | - 'path' => app_path() . DIRECTORY_SEPARATOR, |
|
| 50 | + 'path' => app_path().DIRECTORY_SEPARATOR, |
|
| 51 | 51 | 'namespace' => '{{app}}', |
| 52 | 52 | ], |
| 53 | 53 | [ |
| 54 | - 'path' => app_path() . DIRECTORY_SEPARATOR . 'Models' . DIRECTORY_SEPARATOR, |
|
| 54 | + 'path' => app_path().DIRECTORY_SEPARATOR.'Models'.DIRECTORY_SEPARATOR, |
|
| 55 | 55 | 'namespace' => '{{app}}Models\\', |
| 56 | 56 | ], |
| 57 | 57 | [ |
| 58 | - 'path' => __DIR__ . DIRECTORY_SEPARATOR . '..' . DIRECTORY_SEPARATOR . '..' . DIRECTORY_SEPARATOR . '..' . DIRECTORY_SEPARATOR . 'Models' . DIRECTORY_SEPARATOR, |
|
| 58 | + 'path' => __DIR__.DIRECTORY_SEPARATOR.'..'.DIRECTORY_SEPARATOR.'..'.DIRECTORY_SEPARATOR.'..'.DIRECTORY_SEPARATOR.'Models'.DIRECTORY_SEPARATOR, |
|
| 59 | 59 | 'namespace' => 'Distilleries\\Expendable\\Models\\', |
| 60 | 60 | ], |
| 61 | 61 | ]; |
@@ -67,7 +67,7 @@ discard block |
||
| 67 | 67 | foreach ($models as $model) { |
| 68 | 68 | $choice = explode('/', $model); |
| 69 | 69 | $model = preg_replace('/.php/i', '', last($choice)); |
| 70 | - $choices[$config['namespace'] . $model] = $model; |
|
| 70 | + $choices[$config['namespace'].$model] = $model; |
|
| 71 | 71 | } |
| 72 | 72 | } |
| 73 | 73 | |
@@ -16,13 +16,13 @@ |
||
| 16 | 16 | */ |
| 17 | 17 | public function handle($request, Closure $next, $guard = null, $field = null) |
| 18 | 18 | { |
| 19 | - $ipsAuth = env('BASIC_AUTH_IP',''); |
|
| 20 | - $ipsAuth = explode(',',$ipsAuth); |
|
| 19 | + $ipsAuth = env('BASIC_AUTH_IP', ''); |
|
| 20 | + $ipsAuth = explode(',', $ipsAuth); |
|
| 21 | 21 | |
| 22 | 22 | |
| 23 | - if (env('BASIC_AUTH',false) == true) |
|
| 23 | + if (env('BASIC_AUTH', false) == true) |
|
| 24 | 24 | { |
| 25 | - if(empty($ipsAuth) || !in_array($request->ip(),$ipsAuth)) |
|
| 25 | + if (empty($ipsAuth) || !in_array($request->ip(), $ipsAuth)) |
|
| 26 | 26 | { |
| 27 | 27 | return $this->auth->guard($guard)->basic() ?: $next($request); |
| 28 | 28 | } |
@@ -43,7 +43,7 @@ discard block |
||
| 43 | 43 | { |
| 44 | 44 | $translation = new Translation; |
| 45 | 45 | |
| 46 | - return $translation->getTable() . '.' . $translation->getIsoColumn(); |
|
| 46 | + return $translation->getTable().'.'.$translation->getIsoColumn(); |
|
| 47 | 47 | } |
| 48 | 48 | |
| 49 | 49 | /** |
@@ -55,7 +55,7 @@ discard block |
||
| 55 | 55 | { |
| 56 | 56 | $translation = new Translation; |
| 57 | 57 | |
| 58 | - return $translation->getTable() . '.' . $translation->getIdElementColumn(); |
|
| 58 | + return $translation->getTable().'.'.$translation->getIdElementColumn(); |
|
| 59 | 59 | } |
| 60 | 60 | |
| 61 | 61 | /** |
@@ -67,7 +67,7 @@ discard block |
||
| 67 | 67 | { |
| 68 | 68 | $translation = new Translation; |
| 69 | 69 | |
| 70 | - return $translation->getTable() . '.' . $translation->getModelColumn(); |
|
| 70 | + return $translation->getTable().'.'.$translation->getModelColumn(); |
|
| 71 | 71 | } |
| 72 | 72 | |
| 73 | 73 | /** |
@@ -79,7 +79,7 @@ discard block |
||
| 79 | 79 | { |
| 80 | 80 | $translation = new Translation; |
| 81 | 81 | |
| 82 | - return $translation->getTable() . '.' . $translation->getIdSourceColumn(); |
|
| 82 | + return $translation->getTable().'.'.$translation->getIdSourceColumn(); |
|
| 83 | 83 | } |
| 84 | 84 | |
| 85 | 85 | /** |
@@ -102,7 +102,7 @@ discard block |
||
| 102 | 102 | ->where($this->getQualifiedIsoColumn(), '=', $iso)->get(); |
| 103 | 103 | |
| 104 | 104 | if (!$translation->isEmpty()) { |
| 105 | - $translation->each(function($trans){ |
|
| 105 | + $translation->each(function($trans) { |
|
| 106 | 106 | $trans->delete(); |
| 107 | 107 | }); |
| 108 | 108 | } |
@@ -31,7 +31,7 @@ |
||
| 31 | 31 | public function model(array $row) |
| 32 | 32 | { |
| 33 | 33 | $data = []; |
| 34 | - foreach($this->model->getFillable() as $value) |
|
| 34 | + foreach ($this->model->getFillable() as $value) |
|
| 35 | 35 | { |
| 36 | 36 | $data[$value] = $row[$value]; |
| 37 | 37 | } |
@@ -49,7 +49,7 @@ |
||
| 49 | 49 | |
| 50 | 50 | |
| 51 | 51 | $data = $request->all(); |
| 52 | - $filename = $data['range']['start'] . ' ' . $data['range']['end'] . '.' . $data['type']; |
|
| 52 | + $filename = $data['range']['start'].' '.$data['range']['end'].'.'.$data['type']; |
|
| 53 | 53 | |
| 54 | 54 | return (new BaseExport($this->model, $data))->export($filename); |
| 55 | 55 | } |