@@ -69,7 +69,7 @@ discard block |
||
69 | 69 | |
70 | 70 | $factoryPath = GenerateConfigReader::read('factory'); |
71 | 71 | |
72 | - return $path . $factoryPath->getPath() . '/' . $this->getFileName(); |
|
72 | + return $path.$factoryPath->getPath().'/'.$this->getFileName(); |
|
73 | 73 | } |
74 | 74 | |
75 | 75 | /** |
@@ -77,7 +77,7 @@ discard block |
||
77 | 77 | */ |
78 | 78 | private function getFileName() |
79 | 79 | { |
80 | - return Str::studly($this->argument('name')) . 'Factory.php'; |
|
80 | + return Str::studly($this->argument('name')).'Factory.php'; |
|
81 | 81 | } |
82 | 82 | |
83 | 83 | /** |
@@ -111,6 +111,6 @@ discard block |
||
111 | 111 | |
112 | 112 | $path = str_replace('/', '\\', $path); |
113 | 113 | |
114 | - return $this->laravel['modules']->config('namespace') . '\\' . $this->laravel['modules']->findOrFail($this->getModuleName()) . '\\' . $path; |
|
114 | + return $this->laravel['modules']->config('namespace').'\\'.$this->laravel['modules']->findOrFail($this->getModuleName()).'\\'.$path; |
|
115 | 115 | } |
116 | 116 | } |
@@ -39,11 +39,11 @@ |
||
39 | 39 | |
40 | 40 | public function getDestinationFilePath() |
41 | 41 | { |
42 | - $path = $this->laravel['modules']->getModulePath($this->getModuleName()); |
|
42 | + $path = $this->laravel['modules']->getModulePath($this->getModuleName()); |
|
43 | 43 | |
44 | 44 | $eventPath = GenerateConfigReader::read('event'); |
45 | 45 | |
46 | - return $path . $eventPath->getPath() . '/' . $this->getFileName() . '.php'; |
|
46 | + return $path.$eventPath->getPath().'/'.$this->getFileName().'.php'; |
|
47 | 47 | } |
48 | 48 | |
49 | 49 | /** |
@@ -80,7 +80,7 @@ |
||
80 | 80 | $testPath = GenerateConfigReader::read('test-unit'); |
81 | 81 | } |
82 | 82 | |
83 | - return $path . $testPath->getPath() . '/' . $this->getFileName() . '.php'; |
|
83 | + return $path.$testPath->getPath().'/'.$this->getFileName().'.php'; |
|
84 | 84 | } |
85 | 85 | |
86 | 86 | /** |
@@ -24,21 +24,21 @@ discard block |
||
24 | 24 | { |
25 | 25 | $module = $this->getModuleModel($name); |
26 | 26 | |
27 | - $this->components->task("Updating Composer.json <fg=cyan;options=bold>{$module->getName()}</> Module", function () use ($module) { |
|
27 | + $this->components->task("Updating Composer.json <fg=cyan;options=bold>{$module->getName()}</> Module", function() use ($module) { |
|
28 | 28 | |
29 | - $composer_path = $module->getPath() . DIRECTORY_SEPARATOR . 'composer.json'; |
|
29 | + $composer_path = $module->getPath().DIRECTORY_SEPARATOR.'composer.json'; |
|
30 | 30 | |
31 | 31 | $composer = json_decode(File::get($composer_path), true); |
32 | 32 | |
33 | 33 | $autoload = data_get($composer, 'autoload.psr-4'); |
34 | 34 | |
35 | - if (! $autoload) { |
|
35 | + if (!$autoload) { |
|
36 | 36 | return; |
37 | 37 | } |
38 | 38 | |
39 | 39 | $key_name_with_app = sprintf('Modules\\%s\\App\\', $module->getStudlyName()); |
40 | 40 | |
41 | - if (! array_key_exists($key_name_with_app, $autoload)) { |
|
41 | + if (!array_key_exists($key_name_with_app, $autoload)) { |
|
42 | 42 | return; |
43 | 43 | } |
44 | 44 | |
@@ -53,7 +53,7 @@ discard block |
||
53 | 53 | }); |
54 | 54 | } |
55 | 55 | |
56 | - public function getInfo(): string|null |
|
56 | + public function getInfo(): string | null |
|
57 | 57 | { |
58 | 58 | return 'Updating Composer.json of modules...'; |
59 | 59 | } |
@@ -22,12 +22,12 @@ |
||
22 | 22 | { |
23 | 23 | $module = $this->getModuleModel($name); |
24 | 24 | |
25 | - $this->components->task("Updating <fg=cyan;options=bold>{$module->getName()}</> Module", function () use ($module) { |
|
25 | + $this->components->task("Updating <fg=cyan;options=bold>{$module->getName()}</> Module", function() use ($module) { |
|
26 | 26 | $this->laravel['modules']->update($module); |
27 | 27 | }); |
28 | 28 | } |
29 | 29 | |
30 | - public function getInfo(): string|null |
|
30 | + public function getInfo(): string | null |
|
31 | 31 | { |
32 | 32 | return 'Updating Module ...'; |
33 | 33 | } |
@@ -33,12 +33,12 @@ |
||
33 | 33 | ? '<fg=red;options=bold>Disabled</>' |
34 | 34 | : '<fg=green;options=bold>Enabled</>'; |
35 | 35 | |
36 | - $this->components->task("Disabling <fg=cyan;options=bold>{$module->getName()}</> Module, old status: $status", function () use ($module) { |
|
36 | + $this->components->task("Disabling <fg=cyan;options=bold>{$module->getName()}</> Module, old status: $status", function() use ($module) { |
|
37 | 37 | $module->disable(); |
38 | 38 | }); |
39 | 39 | } |
40 | 40 | |
41 | - public function getInfo(): string|null |
|
41 | + public function getInfo(): string | null |
|
42 | 42 | { |
43 | 43 | return 'Disabling module ...'; |
44 | 44 | } |
@@ -22,12 +22,12 @@ |
||
22 | 22 | { |
23 | 23 | $module = $this->getModuleModel($name); |
24 | 24 | |
25 | - $this->components->task("Using <fg=cyan;options=bold>{$module->getName()}</> Module", function () use ($module) { |
|
25 | + $this->components->task("Using <fg=cyan;options=bold>{$module->getName()}</> Module", function() use ($module) { |
|
26 | 26 | $this->laravel['modules']->setUsed($module); |
27 | 27 | }); |
28 | 28 | } |
29 | 29 | |
30 | - public function getInfo(): string|null |
|
30 | + public function getInfo(): string | null |
|
31 | 31 | { |
32 | 32 | return 'Using Module ...'; |
33 | 33 | } |
@@ -24,12 +24,12 @@ |
||
24 | 24 | { |
25 | 25 | $module = $this->getModuleModel($name); |
26 | 26 | |
27 | - $this->components->task("Forget Using <fg=cyan;options=bold>{$module->getName()}</> Module", function () use ($module) { |
|
27 | + $this->components->task("Forget Using <fg=cyan;options=bold>{$module->getName()}</> Module", function() use ($module) { |
|
28 | 28 | $this->laravel['modules']->forgetUsed($module); |
29 | 29 | }); |
30 | 30 | } |
31 | 31 | |
32 | - public function getInfo(): string|null |
|
32 | + public function getInfo(): string | null |
|
33 | 33 | { |
34 | 34 | return 'Forget Using Module ...'; |
35 | 35 | } |
@@ -26,12 +26,12 @@ |
||
26 | 26 | ? '<fg=red;options=bold>Disabled</>' |
27 | 27 | : '<fg=green;options=bold>Enabled</>'; |
28 | 28 | |
29 | - $this->components->task("Enabling <fg=cyan;options=bold>{$module->getName()}</> Module, old status: $status", function () use ($module) { |
|
29 | + $this->components->task("Enabling <fg=cyan;options=bold>{$module->getName()}</> Module, old status: $status", function() use ($module) { |
|
30 | 30 | $module->enable(); |
31 | 31 | }); |
32 | 32 | } |
33 | 33 | |
34 | - public function getInfo(): string|null |
|
34 | + public function getInfo(): string | null |
|
35 | 35 | { |
36 | 36 | return 'Disabling module ...'; |
37 | 37 | } |