Construtoras de visualização sobre criar, remover e atualizar elementos. Fontes para renderização de construtoras desenvolvidas.
Esse commit está contido em:
@@ -159,6 +159,15 @@ class Mimoza extends Module implements Module_Interface
|
||||
$this->getFramework()->mkFile("project/application/models/{$name}.php", $dbtable);
|
||||
$form = $this->getProject()->buildForm($entity);
|
||||
$this->getFramework()->mkFile("project/application/forms/{$name}.php", $form);
|
||||
|
||||
$directory = "project/application/views/scripts/{$entity->name}";
|
||||
$this->getFramework()->mkDir($directory);
|
||||
$create = $this->getProject()->buildViewCreate($entity);
|
||||
$this->getFramework()->mkFile($directory . "/create.phtml", $create);
|
||||
$delete = $this->getProject()->buildViewDelete($entity);
|
||||
$this->getFramework()->mkFile($directory . "/delete.phtml", $delete);
|
||||
$update = $this->getProject()->buildViewUpdate($entity);
|
||||
$this->getFramework()->mkFile($directory . "/update.phtml", $update);
|
||||
return $this;
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
|
||||
Mimoza_Loader::loadClass('Mimoza_Builder');
|
||||
|
||||
/**
|
||||
* Construtor da Camada de Visualização
|
||||
* Ação para Criar um Novo Elemento
|
||||
* @author Wanderson Henrique Camargo Rosa
|
||||
*/
|
||||
class Builder_ViewCreate extends Mimoza_Builder
|
||||
{
|
||||
public function build($element)
|
||||
{
|
||||
return $this->render('viewcreate.phtml');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
|
||||
Mimoza_Loader::loadClass('Mimoza_Builder');
|
||||
|
||||
/**
|
||||
* Construtor da Camada de Visualização
|
||||
* Ação para Remover um Elemento
|
||||
* @author Wanderson Henrique Camargo Rosa
|
||||
*/
|
||||
class Builder_ViewDelete extends Mimoza_Builder
|
||||
{
|
||||
public function build($element)
|
||||
{
|
||||
return $this->render('viewdelete.phtml');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
|
||||
Mimoza_Loader::loadClass('Mimoza_Builder');
|
||||
|
||||
/**
|
||||
* Construtor da Camada de Visualização
|
||||
* Ação para Atualizar um Elemento
|
||||
* @author Wanderson Henrique Camargo Rosa
|
||||
*/
|
||||
class Builder_ViewUpdate extends Mimoza_Builder
|
||||
{
|
||||
public function build($element)
|
||||
{
|
||||
return $this->render('viewupdate.phtml');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
[php] echo $this->form [/php]
|
||||
@@ -0,0 +1 @@
|
||||
[php] echo $this->form [/php]
|
||||
@@ -0,0 +1 @@
|
||||
[php] echo $this->form [/php]
|
||||
Referência em uma Nova Issue
Bloquear um usuário