Skip to content

Commit

Permalink
🔤 #280 PHP 8.2 formatando TGrid
Browse files Browse the repository at this point in the history
  • Loading branch information
bjverde committed Feb 20, 2023
1 parent 6f1520e commit ee954f0
Showing 1 changed file with 3 additions and 16 deletions.
19 changes: 3 additions & 16 deletions base/classes/webform/TGrid.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -1323,35 +1323,28 @@ public function generateFileExcel() {
$excel->setAttribute('title',htmlentities('Erro ao salvar os dados para exportação',ENT_COMPAT,ENCODINGS));
}
}

//------------------------------------------------------------------------------------
public function getColumns()
{
return $this->columns;
}

//------------------------------------------------------------------------------------
public function getColumn( $strColumnName )
{
$strColumnName = strtolower( $strColumnName );

if ( isset( $this->columns[ $strColumnName ] ) )
{
$strColumnName = strtolower( $strColumnName );
if ( isset( $this->columns[ $strColumnName ] ) ){
return $this->columns[ $strColumnName ];
}
return null;
}

//------------------------------------------------------------------------------------
public function getColumnCount()
{
if ( is_array( $this->getColumns() ) )
{
if ( is_array( $this->getColumns() ) ){
return ( int ) count( $this->columns );
}
return 0;
}

//------------------------------------------------------------------------------------
/**
* Coluna normal para o grid
Expand Down Expand Up @@ -1398,30 +1391,25 @@ public function addHiddenField( $strFieldName, $strId = null )
$strId = is_null( $strId ) ? strtolower( $strFieldName ) : $strId;
$this->hiddenField[ $strFieldName ] = $strId;
}

//------------------------------------------------------------------------------------
public function getHiddenField()
{
return $this->hiddenField;
}

//------------------------------------------------------------------------------------
protected function addActionColumn( $strTitle = null )
{
$this->columns[ $strTitle ] = new TActionColumn( $strTitle );
}

//------------------------------------------------------------------------------------
public function setTitle( $strValue = null )
{
$this->title = $strValue;
}

public function getTitle()
{
return $this->title;
}

//------------------------------------------------------------------------------------
public function setData( $mixValue = null ){
if ( is_array( $mixValue ) ) {
Expand All @@ -1432,7 +1420,6 @@ public function setData( $mixValue = null ){
}
$this->data = $mixValue;
}

//---------------------------------------------------------------------------------------
/**
* Retorna o array de dados do gride
Expand Down

0 comments on commit ee954f0

Please sign in to comment.