You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace App\Console\Commands;
|
|
|
|
|
|
|
|
use App\Console\Commands\Vuex;
|
|
|
|
use App\Services\MorphModelFinder;
|
|
|
|
use Illuminate\Console\Command;
|
|
|
|
|
|
|
|
class VuexBuild extends Command
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* The name and signature of the console command.
|
|
|
|
*
|
|
|
|
* @var string
|
|
|
|
*/
|
|
|
|
protected $signature = 'make:vuex {module} {store-module} {--category} {--replace}';
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
* The console command description.
|
|
|
|
*
|
|
|
|
* @var string
|
|
|
|
*/
|
|
|
|
protected $description = 'Create a vuex modules module store-module --category --replace';
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @var MorphModelFinder
|
|
|
|
*/
|
|
|
|
private $morphModelFinder;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Create a new command instance.
|
|
|
|
*
|
|
|
|
* @param MorphModelFinder $morphModelFinder
|
|
|
|
*/
|
|
|
|
public function __construct(MorphModelFinder $morphModelFinder)
|
|
|
|
{
|
|
|
|
parent::__construct();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Execute the console command.
|
|
|
|
*
|
|
|
|
* @return void
|
|
|
|
*/
|
|
|
|
public function handle(): void
|
|
|
|
{
|
|
|
|
Vuex::initialize($this->arguments(), $this->options())->createAllFiles();
|
|
|
|
|
|
|
|
$this->info('modules Store Created');
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|