public function actionGenerateAll()
    {
        $foundTemplates = $this->findTemplatesFiles();

        if (!$foundTemplates) {
            $this->notifyNoTemplatesFound();
            return static::EXIT_CODE_NORMAL;
        }

        if (!$this->confirmGeneration($foundTemplates)) {
            return static::EXIT_CODE_NORMAL;
        }

        $templatePath = Yii::getAlias($this->templatePath);
        $fixtureDataPath = Yii::getAlias($this->fixtureDataPath);

        FileHelper::createDirectory($fixtureDataPath);

        $generatedTemplates = [];

        foreach ($foundTemplates as $templateName) {
            $this->generateFixtureFile($templateName, $templatePath, $fixtureDataPath);            
            $generatedTemplates[] = $templateName;
        }

        $this->notifyTemplatesGenerated($generatedTemplates);
    }
public function actionGenerateAll()
    {
        $foundTemplates = $this->findTemplatesFiles();

        if (!$foundTemplates) {
            $this->notifyNoTemplatesFound();
            return static::EXIT_CODE_NORMAL;
        }

        if (!$this->confirmGeneration($foundTemplates)) {
            return static::EXIT_CODE_NORMAL;
        }

        $templatePath = Yii::getAlias($this->templatePath);
        $fixtureDataPath = Yii::getAlias($this->fixtureDataPath);

        FileHelper::createDirectory($fixtureDataPath);

        $generatedTemplates = [];

        foreach ($foundTemplates as $templateName) {
            $this->generateFixtureFile($templateName, $templatePath, $fixtureDataPath);            
            $generatedTemplates[] = $templateName;
        }

        $this->notifyTemplatesGenerated($generatedTemplates);
    }
public function actionGenerateAll ( ) { $ foundTemplates = $ this -> findTemplatesFiles ( ) ; if ( ! $ foundTemplates ) { $ this -> notifyNoTemplatesFound ( ) ; return static :: EXIT_CODE_NORMAL ; } if ( ! $ this -> confirmGeneration ( $ foundTemplates ) ) { return static :: EXIT_CODE_NORMAL ; } $ templatePath = Yii :: getAlias ( $ this -> templatePath ) ; $ fixtureDataPath = Yii :: getAlias ( $ this -> fixtureDataPath ) ; FileHelper :: createDirectory ( $ fixtureDataPath ) ; $ generatedTemplates = [ ] ; foreach ( $ foundTemplates as $ templateName ) { $ this -> generateFixtureFile ( $ templateName , $ templatePath , $ fixtureDataPath ) ; $ generatedTemplates [ ] = $ templateName ; } $ this -> notifyTemplatesGenerated ( $ generatedTemplates ) ; }
Generates all fixtures template path that can be found.
Generates all fixtures template path that can be found .