public function createModel($config)
    {
        $repoParts = [
            '_path_model_',
        ];

        foreach ($repoParts as $repoPart) {
            $this->fileService->mkdir($config[$repoPart], 0777, true);
        }

        $model = $this->fileService->get($config['template_source'].'/Model.txt');
        $model = $this->modelService->configTheModel($config, $model);

        foreach ($config as $key => $value) {
            $model = str_replace($key, $value, $model);
        }

        $model = $this->putIfNotExists($config['_path_model_'].'/'.$config['_camel_case_'].'.php', $model);

        return $model;
    }
public function createModel($config)
    {
        $repoParts = [
            '_path_model_',
        ];

        foreach ($repoParts as $repoPart) {
            $this->fileService->mkdir($config[$repoPart], 0777, true);
        }

        $model = $this->fileService->get($config['template_source'].'/Model.txt');
        $model = $this->modelService->configTheModel($config, $model);

        foreach ($config as $key => $value) {
            $model = str_replace($key, $value, $model);
        }

        $model = $this->putIfNotExists($config['_path_model_'].'/'.$config['_camel_case_'].'.php', $model);

        return $model;
    }
public function createModel ( $ config ) { $ repoParts = [ '_path_model_' , ] ; foreach ( $ repoParts as $ repoPart ) { $ this -> fileService -> mkdir ( $ config [ $ repoPart ] , 0777 , true ) ; } $ model = $ this -> fileService -> get ( $ config [ 'template_source' ] . '/Model.txt' ) ; $ model = $ this -> modelService -> configTheModel ( $ config , $ model ) ; foreach ( $ config as $ key => $ value ) { $ model = str_replace ( $ key , $ value , $ model ) ; } $ model = $ this -> putIfNotExists ( $ config [ '_path_model_' ] . '/' . $ config [ '_camel_case_' ] . '.php' , $ model ) ; return $ model ; }
Create the model.

@param array $config

@return bool
Create the model .