Skip to content

Commit

Permalink
🔨 #101 criando metodos
Browse files Browse the repository at this point in the history
  • Loading branch information
bjverde committed Jun 29, 2023
1 parent 17883af commit 3763474
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
1 change: 1 addition & 0 deletions app/control/controllers/TCreateFormList.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,7 @@ public function show($print = false)
$this->addLine(ESP.'protected $adianti_target_container;');
$this->addLine(ESP.'protected $datagrid; //Listing');
$this->addLine(ESP.'protected $pageNavigation;');
$this->addLine(ESP.'public $datagrid_form;');
$this->addBlankLine();
if( $this->getTableType() == TableInfo::TB_TYPE_TABLE ){
$this->addLine(ESP.'// trait com onReload, onSearch, onDelete, onClear, onEdit, show');
Expand Down
16 changes: 16 additions & 0 deletions app/lib/widget/FormDin5/webform/TFormDinGrid.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ class TFormDinGrid
private $listColumn = array();
private $dataGrid;
private $bootstrapGrid;
private $objDatagrid_form;

protected $idGrid;
protected $title;
Expand Down Expand Up @@ -250,6 +251,21 @@ private function setDataGrid($dataGrid){
}
$this->dataGrid = $dataGrid;
}
//---------------------------------------------------------------
private function getObjDatagrid_form(){
return $this->objDatagrid_form;
}
private function setObjDatagrid_form($objDatagrid_form){
if( !is_object($objDatagrid_form) ){
throw new InvalidArgumentException(TFormDinMessage::ERROR_FD5_OBJ_ADI);
}
$this->objDatagrid_form = $objDatagrid_form;
}
public function creatObjDatagrid_form(){
$datagrid_form = new TForm('datagrid_'.$this->getId());
$datagrid_form->onsubmit = 'return false';
$this->setObjDatagrid_form($datagrid_form);
}
/**
* Define o lado que ação irá aparecer. O Default é 'left'
* Os valores possíveis são: left, right, esquerda, direita
Expand Down

0 comments on commit 3763474

Please sign in to comment.