Skip to content

Commit

Permalink
Merge pull request #30 from pratiksh404/analysis-BMmlKA
Browse files Browse the repository at this point in the history
Apply fixes from StyleCI
  • Loading branch information
pratiksh404 authored Feb 27, 2022
2 parents 8f932ec + d784c08 commit 3cebb01
Showing 1 changed file with 13 additions and 13 deletions.
26 changes: 13 additions & 13 deletions src/Console/Commands/InstallAdmineticCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ public function handle()

private function addAdminServiceProvider()
{
$adminServiceProviderTemplate = file_get_contents(__DIR__ . '/../../Console/Commands/AdminStubs/AdminServiceProvider.stub');
$adminServiceProviderTemplate = file_get_contents(__DIR__.'/../../Console/Commands/AdminStubs/AdminServiceProvider.stub');
$adminServiceProviderfile = app_path('Providers/AdminServiceProvider.php');
file_put_contents($adminServiceProviderfile, $adminServiceProviderTemplate);
if (file_exists($adminServiceProviderfile)) {
Expand All @@ -84,9 +84,9 @@ private function addAdminServiceProvider()

private function addMyMenu()
{
$modelTemplate = file_get_contents(__DIR__ . '/../../Console/Commands/AdminStubs/MyMenu.stub');
$modelTemplate = file_get_contents(__DIR__.'/../../Console/Commands/AdminStubs/MyMenu.stub');

if (!file_exists($path = app_path('Services'))) {
if (! file_exists($path = app_path('Services'))) {
mkdir($path, 0777, true);
}

Expand All @@ -101,16 +101,16 @@ private function addMyMenu()

private function addMyDashboard()
{
$myDashboardTemplate = file_get_contents(__DIR__ . '/../../Console/Commands/AdminStubs/MyDashboard.stub');
$myDashboardIndexTemplate = file_get_contents(__DIR__ . '/../../Console/Commands/AdminStubs/DashboardIndex.stub');
$myDashboardTemplate = file_get_contents(__DIR__.'/../../Console/Commands/AdminStubs/MyDashboard.stub');
$myDashboardIndexTemplate = file_get_contents(__DIR__.'/../../Console/Commands/AdminStubs/DashboardIndex.stub');

if (!file_exists($path = app_path('Services'))) {
if (! file_exists($path = app_path('Services'))) {
mkdir($path, 0777, true);
}
if (!file_exists($path = resource_path('views/admin/dashboard'))) {
if (! file_exists($path = resource_path('views/admin/dashboard'))) {
mkdir($path, 0777, true);
}
if (!file_exists($path = resource_path('views/admin/layouts/modules/dashboard'))) {
if (! file_exists($path = resource_path('views/admin/layouts/modules/dashboard'))) {
mkdir($path, 0777, true);
}
$myDashboardIndexfile = resource_path('views/admin/dashboard/index.blade.php');
Expand Down Expand Up @@ -139,9 +139,9 @@ private function addMyDashboard()

protected function addHeader()
{
$myHeaderTemplate = file_get_contents(__DIR__ . '/../../Console/Commands/AdminStubs/HeaderView.stub');
$myHeaderTemplate = file_get_contents(__DIR__.'/../../Console/Commands/AdminStubs/HeaderView.stub');

if (!file_exists($path = resource_path('views/admin/layouts/components'))) {
if (! file_exists($path = resource_path('views/admin/layouts/components'))) {
mkdir($path, 0777, true);
}

Expand All @@ -156,9 +156,9 @@ protected function addHeader()

protected function addFooter()
{
$myFooterTemplate = file_get_contents(__DIR__ . '/../../Console/Commands/AdminStubs/FooterView.stub');
$myFooterTemplate = file_get_contents(__DIR__.'/../../Console/Commands/AdminStubs/FooterView.stub');

if (!file_exists($path = resource_path('views/admin/layouts/components'))) {
if (! file_exists($path = resource_path('views/admin/layouts/components'))) {
mkdir($path, 0777, true);
}

Expand All @@ -173,6 +173,6 @@ protected function addFooter()

protected static function getStub($type)
{
return file_get_contents(__DIR__ . "/../../Console/Commands/AdminStubs/$type.stub");
return file_get_contents(__DIR__."/../../Console/Commands/AdminStubs/$type.stub");
}
}

0 comments on commit 3cebb01

Please sign in to comment.