当前位置: 首页>>代码示例>>PHP>>正文


PHP GeneratorCommand::fire方法代码示例

本文整理汇总了PHP中Illuminate\Console\GeneratorCommand::fire方法的典型用法代码示例。如果您正苦于以下问题:PHP GeneratorCommand::fire方法的具体用法?PHP GeneratorCommand::fire怎么用?PHP GeneratorCommand::fire使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Illuminate\Console\GeneratorCommand的用法示例。


在下文中一共展示了GeneratorCommand::fire方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: fire

 /**
  * Execute the console command.
  *
  * @return void
  */
 public function fire()
 {
     parent::fire();
     if (!$this->option('plain')) {
         $this->createView();
     }
 }
开发者ID:ngangchill,项目名称:laravel-widgets,代码行数:12,代码来源:WidgetMakeCommand.php

示例2: fire

 /**
  * Execute the command.
  *
  * @return void
  */
 public function fire()
 {
     parent::fire();
     if ($this->option('handler')) {
         $this->call('handler:command', ['name' => $this->argument('name') . 'Handler', '--command' => $this->parseName($this->argument('name'))]);
     }
 }
开发者ID:ngitimfoyo,项目名称:Nyari-AppPHP,代码行数:12,代码来源:CommandMakeCommand.php

示例3: fire

 /**
  * Override the parent `fire` method so we can create our implementation as well
  */
 public function fire()
 {
     parent::fire();
     if ($this->option('which') == 'contract') {
         $this->call('parse:repository', ['name' => $this->argument('name'), '--which' => 'implementation']);
     }
 }
开发者ID:khangaikh,项目名称:golocal,代码行数:10,代码来源:RepositoryMakeCommand.php

示例4: fire

 /**
  * Execute the console command.
  *
  * @return void
  */
 public function fire()
 {
     if (!$this->option('event')) {
         return $this->error('Missing required option: --event');
     }
     parent::fire();
 }
开发者ID:manhvu1212,项目名称:videoplatform,代码行数:12,代码来源:ListenerMakeCommand.php

示例5: fire

 /**
  * Execute the console command.
  *
  * @return void
  */
 public function fire()
 {
     if (parent::fire() !== false && $this->option('translated')) {
         $name = $this->getNameInput();
         $this->type = 'Admin model translation class';
         $this->call('administr:model', ['name' => "{$name}Translation"]);
     }
 }
开发者ID:administrcms,项目名称:localization,代码行数:13,代码来源:MakeAdminModel.php

示例6: fire

 /**
  * Execute the console command.
  *
  * @return void
  */
 public function fire()
 {
     parent::fire();
     if (!$this->option('no-migration')) {
         $table = str_plural(snake_case(class_basename($this->argument('name'))));
         $this->call('make:migration', ['name' => "create_{$table}_table", '--create' => $table]);
     }
 }
开发者ID:HarveyCheng,项目名称:myblog,代码行数:13,代码来源:ModelMakeCommand.php

示例7: handle

 /**
  * Execute the console command.
  *
  * @return void
  */
 public function handle()
 {
     if (!$this->modelExists()) {
         $this->error('Model does not exists !');
         return false;
     }
     $this->type = $this->parseName($this->getNameInput());
     parent::fire();
 }
开发者ID:z-song,项目名称:laravel-admin,代码行数:14,代码来源:MakeCommand.php

示例8: fire

 /**
  * Execute the console command.
  *
  * @return void
  */
 public function fire()
 {
     if (parent::fire() === false) {
         return;
     }
     if ($this->option('markdown')) {
         $this->writeMarkdownTemplate();
     }
 }
开发者ID:jarnovanleeuwen,项目名称:framework,代码行数:14,代码来源:NotificationMakeCommand.php

示例9: fire

 /**
  * Execute the console command.
  *
  * @return void
  */
 public function fire()
 {
     if (parent::fire() !== false) {
         if ($this->option('migration')) {
             $table = Str::plural(Str::snake(class_basename($this->argument('name'))));
             $this->call('make:migration', ['name' => "create_{$table}_table", '--create' => $table]);
         }
     }
 }
开发者ID:manhvu1212,项目名称:videoplatform,代码行数:14,代码来源:ModelMakeCommand.php

示例10: fire

 /**
  * Execute the console command.
  *
  * @return void
  */
 public function fire()
 {
     if (parent::fire() !== false) {
         if ($this->option('migration') && $this->table != '') {
             $table = $this->table;
             $this->call('make:migration', ['name' => "create_{$table}_table", '--create' => $table]);
         }
         if ($this->option('repository')) {
             $this->call('make:repository', ['name' => $this->argument('name')]);
         }
     }
 }
开发者ID:vampirekiss,项目名称:lumen-restful-starter-kit,代码行数:17,代码来源:ModelMakeCommand.php

示例11: fire

 /**
  * @return void
  */
 public function fire()
 {
     if (parent::fire() !== false) {
         if ($this->option('migration')) {
             $table = Str::plural(Str::snake(class_basename($this->argument('name'))));
             $this->call('make:migration', ['name' => "create_{$table}_table", '--create' => $table]);
         }
         if ($this->option('controller')) {
             $controller = Str::camel(class_basename($this->argument('name')));
             $this->call('make:controller', ['name' => "{$controller}Controller", '--resource' => true]);
         }
     }
 }
开发者ID:notadd,项目名称:framework,代码行数:16,代码来源:ModelMakeCommand.php

示例12: fire

 public function fire()
 {
     if ($this->compound !== null) {
         if (parent::fire() !== false) {
             if ($this->option($this->compound)) {
                 $name = $this->argument('name');
                 $this->call("hive:{$this->compound}", ['name' => $name]);
             }
         }
     } else {
         parent::fire();
     }
 }
开发者ID:EHLOVader,项目名称:hive,代码行数:13,代码来源:HiveGeneratorCommand.php

示例13: fire

 /**
  * Execute the console command.
  *
  * @return void
  */
 public function fire()
 {
     if (parent::fire() !== false) {
         if ($this->option('model')) {
             $this->call('make:model', ['name' => $this->argument('name')]);
             $table = str_replace('._', '_', Str::plural(Str::snake(class_basename($this->argument('name')))));
             $this->call('make:migration', ['name' => "create_{$table}_table", '--create' => $table]);
         }
         if ($this->option('testcase')) {
             $this->call('make:test', ['name' => $this->argument('name')]);
         }
     }
 }
开发者ID:vampirekiss,项目名称:lumen-restful-starter-kit,代码行数:18,代码来源:ApiMakeCommand.php

示例14: fire

 /**
  * Execute the console command.
  *
  * @return void
  */
 public function fire()
 {
     if (parent::fire() !== false) {
         if (!$this->option('no-routes')) {
             $path = Config::get('generator.path_routes', app_path('Http/routes.php'));
             $path = Config::get('generator.path_routes', app_path('Http/routes.php'));
             $content = $this->files->get($path);
             $name = $this->parseName($this->getNameInput());
             $content .= $this->buildRoute($name);
             $this->files->put($path, $content);
         }
     }
 }
开发者ID:georgeneculai,项目名称:laravel-toolkit,代码行数:18,代码来源:ControllerCommand.php

示例15: fire

 /**
  * Execute the console command.
  *
  * @return void
  */
 public function fire()
 {
     if (parent::fire() !== false) {
         if ($this->option('with-repository')) {
             $this->comment('making repository');
             $this->call('api:new-repository', ['name' => $this->argument('name')]);
         }
         if ($this->option('with-migration')) {
             $this->comment('making migration');
             $name = $this->argument('name');
             $table = str_plural(snake_case($name));
             $this->call('make:migration', ['name' => "create_{$table}_table", '--create' => $table]);
         }
     }
 }
开发者ID:tokenly,项目名称:laravel-api-provider,代码行数:20,代码来源:MakeAPIModelCommand.php


注:本文中的Illuminate\Console\GeneratorCommand::fire方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。