| @@ 11-49 (lines=39) @@ | ||
| 8 | use Scaffolder\Compilers\Support\PathParser; |
|
| 9 | use Scaffolder\Support\Directory; |
|
| 10 | ||
| 11 | class ListChooseColumnsCompiler extends AbstractCompiler |
|
| 12 | { |
|
| 13 | protected $cachePrefix = 'list_choose_column_'; |
|
| 14 | protected $stubFilename = 'ChooseColumnsDialog.html' ; |
|
| 15 | ||
| 16 | public function __construct($scaffolderConfig, $modelData = null) |
|
| 17 | { |
|
| 18 | $this->stubsDirectory = __DIR__ . '/../../../../stubs/AngularJs/'; |
|
| 19 | parent::__construct($scaffolderConfig, $modelData); |
|
| 20 | } |
|
| 21 | ||
| 22 | /** |
|
| 23 | * Replace and store the Stub. |
|
| 24 | * |
|
| 25 | * @return string |
|
| 26 | */ |
|
| 27 | public function replaceAndStore() |
|
| 28 | { |
|
| 29 | ||
| 30 | return $this->store(new FileToCompile(false, $this->modelData->modelHash)); |
|
| 31 | ||
| 32 | } |
|
| 33 | ||
| 34 | /** |
|
| 35 | * Get output filename |
|
| 36 | * |
|
| 37 | * |
|
| 38 | * @return $this |
|
| 39 | */ |
|
| 40 | protected function getOutputFilename() |
|
| 41 | { |
|
| 42 | $folder = PathParser::parse($this->scaffolderConfig->generator->paths->pages).$this->modelData->tableName.'/list/' ; |
|
| 43 | ||
| 44 | Directory::createIfNotExists($folder, 0755, true); |
|
| 45 | ||
| 46 | return $folder .$this->modelData->tableName . '_columns.dialog.html'; |
|
| 47 | } |
|
| 48 | ||
| 49 | } |
|
| @@ 11-49 (lines=39) @@ | ||
| 8 | use Scaffolder\Compilers\Support\PathParser; |
|
| 9 | use Scaffolder\Support\Directory; |
|
| 10 | ||
| 11 | class ListDetailCompiler extends AbstractCompiler |
|
| 12 | { |
|
| 13 | protected $cachePrefix = 'list_detail_'; |
|
| 14 | protected $stubFilename = 'DetailDialog.html' ; |
|
| 15 | ||
| 16 | public function __construct($scaffolderConfig, $modelData = null) |
|
| 17 | { |
|
| 18 | $this->stubsDirectory = __DIR__ . '/../../../../stubs/AngularJs/'; |
|
| 19 | parent::__construct($scaffolderConfig, $modelData); |
|
| 20 | } |
|
| 21 | ||
| 22 | /** |
|
| 23 | * Replace and store the Stub. |
|
| 24 | * |
|
| 25 | * @return string |
|
| 26 | */ |
|
| 27 | public function replaceAndStore() |
|
| 28 | { |
|
| 29 | ||
| 30 | return $this->store(new FileToCompile(false, $this->modelData->modelHash)); |
|
| 31 | ||
| 32 | } |
|
| 33 | ||
| 34 | /** |
|
| 35 | * Get output filename |
|
| 36 | * |
|
| 37 | * |
|
| 38 | * @return $this |
|
| 39 | */ |
|
| 40 | protected function getOutputFilename() |
|
| 41 | { |
|
| 42 | $folder = PathParser::parse($this->scaffolderConfig->generator->paths->pages).$this->modelData->tableName.'/list/' ; |
|
| 43 | ||
| 44 | Directory::createIfNotExists($folder, 0755, true); |
|
| 45 | ||
| 46 | return $folder .$this->modelData->tableName . '_details.dialog.html'; |
|
| 47 | } |
|
| 48 | ||
| 49 | } |
|
| @@ 11-49 (lines=39) @@ | ||
| 8 | use Scaffolder\Compilers\Support\PathParser; |
|
| 9 | use Scaffolder\Support\Directory; |
|
| 10 | ||
| 11 | class ListModuleCompiler extends AbstractCompiler |
|
| 12 | { |
|
| 13 | protected $cachePrefix = 'list_module_'; |
|
| 14 | protected $stubFilename = 'ListModule.js' ; |
|
| 15 | ||
| 16 | public function __construct($scaffolderConfig, $modelData = null) |
|
| 17 | { |
|
| 18 | $this->stubsDirectory = __DIR__ . '/../../../../stubs/AngularJs/'; |
|
| 19 | parent::__construct($scaffolderConfig, $modelData); |
|
| 20 | } |
|
| 21 | ||
| 22 | /** |
|
| 23 | * Replace and store the Stub. |
|
| 24 | * |
|
| 25 | * @return string |
|
| 26 | */ |
|
| 27 | public function replaceAndStore() |
|
| 28 | { |
|
| 29 | ||
| 30 | return $this->store(new FileToCompile(false, $this->modelData->modelHash)); |
|
| 31 | ||
| 32 | } |
|
| 33 | ||
| 34 | /** |
|
| 35 | * Get output filename |
|
| 36 | * |
|
| 37 | * |
|
| 38 | * @return $this |
|
| 39 | */ |
|
| 40 | protected function getOutputFilename() |
|
| 41 | { |
|
| 42 | $folder = PathParser::parse($this->scaffolderConfig->generator->paths->pages).$this->modelData->tableName.'/list/' ; |
|
| 43 | ||
| 44 | Directory::createIfNotExists($folder, 0755, true); |
|
| 45 | ||
| 46 | return $folder .$this->modelData->tableName . '_list.module.js'; |
|
| 47 | } |
|
| 48 | ||
| 49 | } |
|
| @@ 11-49 (lines=39) @@ | ||
| 8 | use Scaffolder\Compilers\Support\PathParser; |
|
| 9 | use Scaffolder\Support\Directory; |
|
| 10 | ||
| 11 | class ModuleCompiler extends AbstractCompiler |
|
| 12 | { |
|
| 13 | protected $cachePrefix = 'module_'; |
|
| 14 | protected $stubFilename = 'Module.js' ; |
|
| 15 | ||
| 16 | public function __construct($scaffolderConfig, $modelData = null) |
|
| 17 | { |
|
| 18 | $this->stubsDirectory = __DIR__ . '/../../../../stubs/AngularJs/'; |
|
| 19 | parent::__construct($scaffolderConfig, $modelData); |
|
| 20 | } |
|
| 21 | ||
| 22 | /** |
|
| 23 | * Replace and store the Stub. |
|
| 24 | * |
|
| 25 | * @return string |
|
| 26 | */ |
|
| 27 | public function replaceAndStore() |
|
| 28 | { |
|
| 29 | ||
| 30 | return $this->store(new FileToCompile(false, $this->modelData->modelHash)); |
|
| 31 | ||
| 32 | } |
|
| 33 | ||
| 34 | /** |
|
| 35 | * Get output filename |
|
| 36 | * |
|
| 37 | * |
|
| 38 | * @return $this |
|
| 39 | */ |
|
| 40 | protected function getOutputFilename() |
|
| 41 | { |
|
| 42 | $folder = PathParser::parse($this->scaffolderConfig->generator->paths->pages).$this->modelData->tableName.'/' ; |
|
| 43 | ||
| 44 | Directory::createIfNotExists($folder, 0755, true); |
|
| 45 | ||
| 46 | return $folder . $this->modelData->tableName . '.module.js'; |
|
| 47 | } |
|
| 48 | ||
| 49 | } |
|
| @@ 11-49 (lines=39) @@ | ||
| 8 | use Scaffolder\Compilers\Support\PathParser; |
|
| 9 | use Scaffolder\Support\Directory; |
|
| 10 | ||
| 11 | class RegisterModuleCompiler extends AbstractCompiler |
|
| 12 | { |
|
| 13 | protected $cachePrefix = 'register_module_'; |
|
| 14 | protected $stubFilename = 'RegisterModule.js' ; |
|
| 15 | ||
| 16 | public function __construct($scaffolderConfig, $modelData = null) |
|
| 17 | { |
|
| 18 | $this->stubsDirectory = __DIR__ . '/../../../../stubs/AngularJs/'; |
|
| 19 | parent::__construct($scaffolderConfig, $modelData); |
|
| 20 | } |
|
| 21 | ||
| 22 | /** |
|
| 23 | * Replace and store the Stub. |
|
| 24 | * |
|
| 25 | * @return string |
|
| 26 | */ |
|
| 27 | public function replaceAndStore() |
|
| 28 | { |
|
| 29 | ||
| 30 | return $this->store(new FileToCompile(false, $this->modelData->modelHash)); |
|
| 31 | ||
| 32 | } |
|
| 33 | ||
| 34 | /** |
|
| 35 | * Get output filename |
|
| 36 | * |
|
| 37 | * |
|
| 38 | * @return $this |
|
| 39 | */ |
|
| 40 | protected function getOutputFilename() |
|
| 41 | { |
|
| 42 | $folder = PathParser::parse($this->scaffolderConfig->generator->paths->pages).$this->modelData->tableName.'/register/' ; |
|
| 43 | ||
| 44 | Directory::createIfNotExists($folder, 0755, true); |
|
| 45 | ||
| 46 | return $folder .$this->modelData->tableName . '_register.module.js'; |
|
| 47 | } |
|
| 48 | ||
| 49 | } |
|
| @@ 11-47 (lines=37) @@ | ||
| 8 | use Scaffolder\Compilers\Support\PathParser; |
|
| 9 | use Scaffolder\Support\Directory; |
|
| 10 | ||
| 11 | class ResourceCompiler extends AbstractCompiler |
|
| 12 | { |
|
| 13 | protected $cachePrefix = 'resource_'; |
|
| 14 | protected $stubFilename = 'Resource.js' ; |
|
| 15 | ||
| 16 | public function __construct($scaffolderConfig, $modelData = null) |
|
| 17 | { |
|
| 18 | $this->stubsDirectory = __DIR__ . '/../../../../stubs/AngularJs/'; |
|
| 19 | parent::__construct($scaffolderConfig, $modelData); |
|
| 20 | } |
|
| 21 | ||
| 22 | /** |
|
| 23 | * Replace and store the Stub. |
|
| 24 | * |
|
| 25 | * @return string |
|
| 26 | */ |
|
| 27 | public function replaceAndStore() |
|
| 28 | { |
|
| 29 | return $this->store(new FileToCompile(false, $this->modelData->modelHash)); |
|
| 30 | } |
|
| 31 | ||
| 32 | /** |
|
| 33 | * Get output filename |
|
| 34 | * |
|
| 35 | * |
|
| 36 | * @return $this |
|
| 37 | */ |
|
| 38 | protected function getOutputFilename() |
|
| 39 | { |
|
| 40 | $folder = PathParser::parse($this->scaffolderConfig->generator->paths->pages).$this->modelData->tableName.'/' ; |
|
| 41 | ||
| 42 | Directory::createIfNotExists($folder, 0755, true); |
|
| 43 | ||
| 44 | return $folder . $this->modelData->tableName . '.resource.js'; |
|
| 45 | } |
|
| 46 | ||
| 47 | } |
|