FazendaEntity
extends Entity
in package
Table of Contents
Constants
- auditlog = ['exclude_fields' => ['DataHora'], 'object_rel' => 'idFazenda']
- Allowed keys: 'exclude_fields': <...> 'object_rel': <...>
- const_values = []
- database = \config\Config::DB_DEFAULT
- db_table = 'cad_fazendas'
- pk_field = 'idFazenda'
- sanitize = []
- security = ['select' => 'src\models\FazendaSecurity::securitySelect']
- Allowed keys: 'select': <...> 'update': <...> 'delete': <...> 'insert': <...>
- tracking = true
- validations = ['tipo' => ['required' => 'O campo Tipo é requerido.'], 'nomeFazenda' => ['required' => 'O campo Nome é requerido.'], 'valorFazenda' => ['required' => 'O campo Valor Real é requerido.'], 'areaHa' => ['required' => 'O campo Área(Ha) é requerido.'], 'areaUtilHa' => ['required' => 'O campo Área Útil(Ha) é requerido.'], 'valorMatricula' => ['required' => 'O campo Valor Matrícula é requerido.'], 'valorITR' => ['required' => 'O campo Valor ITR é requerido.']]
- Estrutura = ['key' => ['keyRule' => 'Rule message']]
Properties
- $anexoMatricula : mixed
- $areaAlq : mixed
- $areaHa : mixed
- $areaUtilHa : mixed
- $codigoINTSYS : mixed
- $codigoINTSYSCONTABIL : mixed
- $codigoMultbovinos : mixed
- $custoAquisicao : mixed
- $dataAquisicao : mixed
- $dataFinalizaArrend : mixed
- $DataHora : mixed
- $dataInicioArrend : mixed
- $dataVenda : mixed
- $idContasPagar : mixed
- $idFazenda : mixed
- $idFazendaRelacao : mixed
- $idUsuario : mixed
- $idVariavelControle : mixed
- $inscricaoEstadual : mixed
- $lat : mixed
- $lng : mixed
- $matricula : mixed
- $metros2 : mixed
- $nomeFazenda : mixed
- $obs : mixed
- $ordem : mixed
- $tipo : mixed
- $tipoPluviometro : mixed
- $totalAnexo : mixed
- $valorFazenda : mixed
- $valorITR : mixed
- $valorMatricula : mixed
- $valorVenda : mixed
Methods
- __construct() : mixed
- delete() : mixed
- delete_where() : mixed
- getAnexoMatricula() : mixed
- Get the value of anexoMatricula
- getAreaAlq() : mixed
- Get the value of areaAlq
- getAreaHa() : mixed
- Get the value of areaHa
- getAreaUtilHa() : mixed
- Get the value of areaUtilHa
- getAuditlog() : mixed
- getCodigoINTSYS() : mixed
- Get the value of codigoINTSYS
- getCodigoINTSYSCONTABIL() : mixed
- Get the value of codigoINTSYSCONTABIL
- getCodigoMultbovinos() : mixed
- Get the value of codigoMultbovinos
- getConst() : mixed
- getConstObj() : mixed
- getCustoAquisicao() : mixed
- Get the value of custoAquisicao
- getDataAquisicao() : mixed
- Get the value of dataAquisicao
- getDatabase() : mixed
- getDataFinalizaArrend() : mixed
- Get the value of dataFinalizaArrend
- getDataHora() : mixed
- Get the value of DataHora
- getDataInicioArrend() : mixed
- Get the value of dataInicioArrend
- getDataVenda() : mixed
- Get the value of dataVenda
- getDBDriver() : mixed
- getDBTable() : mixed
- getIdContasPagar() : mixed
- Get the value of idContasPagar
- getIdFazenda() : mixed
- Get the value of idFazenda
- getIdFazendaRelacao() : mixed
- Get the value of idFazendaRelacao
- getIdUsuario() : mixed
- Get the value of idUsuario
- getIdVariavelControle() : mixed
- Get the value of idVariavelControle
- getInscricaoEstadual() : mixed
- Get the value of inscricaoEstadual
- getLat() : mixed
- Get the value of lat
- getLng() : mixed
- Get the value of lng
- getMatricula() : mixed
- Get the value of matricula
- getMetros2() : mixed
- Get the value of metros2
- getNomeFazenda() : mixed
- Get the value of nomeFazenda
- getObs() : mixed
- Get the value of obs
- getOrdem() : mixed
- Get the value of ordem
- getTable() : mixed
- getTipo() : mixed
- Get the value of tipo
- getTipoPluviometro() : mixed
- Get the value of tipoPluviometro
- getTotalAnexo() : mixed
- Get the value of totalAnexo
- getValorFazenda() : mixed
- Get the value of valorFazenda
- getValorITR() : mixed
- Get the value of valorITR
- getValorMatricula() : mixed
- Get the value of valorMatricula
- getValorVenda() : mixed
- Get the value of valorVenda
- hasField() : mixed
- insert() : null|Entity
- insert_or_select() : null|Entity
- Funcao que insere ou seleciona se existe
- insert_or_update() : array<string|int, mixed>
- Funcao que insere ou atualiza uma entidade no banco de dados
- securityDelete() : bool
- securityInsert() : bool
- securitySelect() : array<string|int, mixed>
- securityUpdate() : bool
- setAnexoMatricula() : self
- Set the value of anexoMatricula
- setAreaAlq() : self
- Set the value of areaAlq
- setAreaHa() : self
- Set the value of areaHa
- setAreaUtilHa() : self
- Set the value of areaUtilHa
- setCodigoINTSYS() : self
- Set the value of codigoINTSYS
- setCodigoINTSYSCONTABIL() : self
- Set the value of codigoINTSYSCONTABIL
- setCodigoMultbovinos() : self
- Set the value of codigoMultbovinos
- setCustoAquisicao() : self
- Set the value of custoAquisicao
- setDataAquisicao() : self
- Set the value of dataAquisicao
- setDataFinalizaArrend() : self
- Set the value of dataFinalizaArrend
- setDataHora() : self
- Set the value of DataHora
- setDataInicioArrend() : self
- Set the value of dataInicioArrend
- setDataVenda() : self
- Set the value of dataVenda
- setIdContasPagar() : self
- Set the value of idContasPagar
- setIdFazenda() : self
- Set the value of idFazenda
- setIdFazendaRelacao() : self
- Set the value of idFazendaRelacao
- setIdUsuario() : self
- Set the value of idUsuario
- setIdVariavelControle() : self
- Set the value of idVariavelControle
- setInscricaoEstadual() : self
- Set the value of inscricaoEstadual
- setLat() : self
- Set the value of lat
- setLng() : self
- Set the value of lng
- setMatricula() : self
- Set the value of matricula
- setMetros2() : self
- Set the value of metros2
- setNomeFazenda() : self
- Set the value of nomeFazenda
- setObs() : self
- Set the value of obs
- setOrdem() : self
- Set the value of ordem
- setTipo() : self
- Set the value of tipo
- setTipoPluviometro() : self
- Set the value of tipoPluviometro
- setTotalAnexo() : self
- Set the value of totalAnexo
- setValorFazenda() : self
- Set the value of valorFazenda
- setValorITR() : self
- Set the value of valorITR
- setValorMatricula() : self
- Set the value of valorMatricula
- setValorVenda() : self
- Set the value of valorVenda
- update() : mixed
- A função update pode atualizar uma Entity já instanciada, desde que a chave primária esteja setada, ou pode atualizar uma Entity vazia informando o valor da chave primária no segundo parâmetro (pk_value)
- validateFields() : bool
- where() : Collection
- Rudimentary ORM functions
Constants
auditlog
Allowed keys: 'exclude_fields': <...> 'object_rel': <...>
public
mixed
auditlog
= ['exclude_fields' => ['DataHora'], 'object_rel' => 'idFazenda']
const_values
public
mixed
const_values
= []
database
public
mixed
database
= \config\Config::DB_DEFAULT
db_table
public
mixed
db_table
= 'cad_fazendas'
pk_field
public
mixed
pk_field
= 'idFazenda'
sanitize
public
mixed
sanitize
= []
security
Allowed keys: 'select': <...> 'update': <...> 'delete': <...> 'insert': <...>
public
mixed
security
= ['select' => 'src\models\FazendaSecurity::securitySelect']
tracking
public
mixed
tracking
= true
validations
Estrutura = ['key' => ['keyRule' => 'Rule message']]
public
mixed
validations
= ['tipo' => ['required' => 'O campo Tipo é requerido.'], 'nomeFazenda' => ['required' => 'O campo Nome é requerido.'], 'valorFazenda' => ['required' => 'O campo Valor Real é requerido.'], 'areaHa' => ['required' => 'O campo Área(Ha) é requerido.'], 'areaUtilHa' => ['required' => 'O campo Área Útil(Ha) é requerido.'], 'valorMatricula' => ['required' => 'O campo Valor Matrícula é requerido.'], 'valorITR' => ['required' => 'O campo Valor ITR é requerido.']]
Properties
$anexoMatricula
private
mixed
$anexoMatricula
$areaAlq
private
mixed
$areaAlq
$areaHa
private
mixed
$areaHa
$areaUtilHa
private
mixed
$areaUtilHa
$codigoINTSYS
private
mixed
$codigoINTSYS
$codigoINTSYSCONTABIL
private
mixed
$codigoINTSYSCONTABIL
$codigoMultbovinos
private
mixed
$codigoMultbovinos
$custoAquisicao
private
mixed
$custoAquisicao
$dataAquisicao
private
mixed
$dataAquisicao
$dataFinalizaArrend
private
mixed
$dataFinalizaArrend
$DataHora
private
mixed
$DataHora
$dataInicioArrend
private
mixed
$dataInicioArrend
$dataVenda
private
mixed
$dataVenda
$idContasPagar
private
mixed
$idContasPagar
$idFazenda
private
mixed
$idFazenda
$idFazendaRelacao
private
mixed
$idFazendaRelacao
$idUsuario
private
mixed
$idUsuario
$idVariavelControle
private
mixed
$idVariavelControle
$inscricaoEstadual
private
mixed
$inscricaoEstadual
$lat
private
mixed
$lat
$lng
private
mixed
$lng
$matricula
private
mixed
$matricula
$metros2
private
mixed
$metros2
$nomeFazenda
private
mixed
$nomeFazenda
$obs
private
mixed
$obs
$ordem
private
mixed
$ordem
$tipo
private
mixed
$tipo
$tipoPluviometro
private
mixed
$tipoPluviometro
$totalAnexo
private
mixed
$totalAnexo
$valorFazenda
private
mixed
$valorFazenda
$valorITR
private
mixed
$valorITR
$valorMatricula
private
mixed
$valorMatricula
$valorVenda
private
mixed
$valorVenda
Methods
__construct()
public
__construct([array<string|int, mixed> $values = [] ]) : mixed
Parameters
- $values : array<string|int, mixed> = []
delete()
public
delete(mixed $motivo) : mixed
Parameters
- $motivo : mixed
delete_where()
public
static delete_where(mixed $motivo[, mixed $where = [] ]) : mixed
Parameters
- $motivo : mixed
- $where : mixed = []
getAnexoMatricula()
Get the value of anexoMatricula
public
getAnexoMatricula() : mixed
getAreaAlq()
Get the value of areaAlq
public
getAreaAlq() : mixed
getAreaHa()
Get the value of areaHa
public
getAreaHa() : mixed
getAreaUtilHa()
Get the value of areaUtilHa
public
getAreaUtilHa() : mixed
getAuditlog()
public
getAuditlog([string|null $key = null ]) : mixed
Parameters
- $key : string|null = null
getCodigoINTSYS()
Get the value of codigoINTSYS
public
getCodigoINTSYS() : mixed
getCodigoINTSYSCONTABIL()
Get the value of codigoINTSYSCONTABIL
public
getCodigoINTSYSCONTABIL() : mixed
getCodigoMultbovinos()
Get the value of codigoMultbovinos
public
getCodigoMultbovinos() : mixed
getConst()
public
static getConst(string $field[, mixed $const_value = null ]) : mixed
Parameters
- $field : string
- $const_value : mixed = null
getConstObj()
public
static getConstObj(string $field[, mixed $const_value = null ]) : mixed
Parameters
- $field : string
- $const_value : mixed = null
getCustoAquisicao()
Get the value of custoAquisicao
public
getCustoAquisicao() : mixed
getDataAquisicao()
Get the value of dataAquisicao
public
getDataAquisicao() : mixed
getDatabase()
public
getDatabase() : mixed
getDataFinalizaArrend()
Get the value of dataFinalizaArrend
public
getDataFinalizaArrend() : mixed
getDataHora()
Get the value of DataHora
public
getDataHora() : mixed
getDataInicioArrend()
Get the value of dataInicioArrend
public
getDataInicioArrend() : mixed
getDataVenda()
Get the value of dataVenda
public
getDataVenda() : mixed
getDBDriver()
public
static getDBDriver() : mixed
getDBTable()
public
static getDBTable() : mixed
getIdContasPagar()
Get the value of idContasPagar
public
getIdContasPagar() : mixed
getIdFazenda()
Get the value of idFazenda
public
getIdFazenda() : mixed
getIdFazendaRelacao()
Get the value of idFazendaRelacao
public
getIdFazendaRelacao() : mixed
getIdUsuario()
Get the value of idUsuario
public
getIdUsuario() : mixed
getIdVariavelControle()
Get the value of idVariavelControle
public
getIdVariavelControle() : mixed
getInscricaoEstadual()
Get the value of inscricaoEstadual
public
getInscricaoEstadual() : mixed
getLat()
Get the value of lat
public
getLat() : mixed
getLng()
Get the value of lng
public
getLng() : mixed
getMatricula()
Get the value of matricula
public
getMatricula() : mixed
getMetros2()
Get the value of metros2
public
getMetros2() : mixed
getNomeFazenda()
Get the value of nomeFazenda
public
getNomeFazenda() : mixed
getObs()
Get the value of obs
public
getObs() : mixed
getOrdem()
Get the value of ordem
public
getOrdem() : mixed
getTable()
public
getTable() : mixed
getTipo()
Get the value of tipo
public
getTipo() : mixed
getTipoPluviometro()
Get the value of tipoPluviometro
public
getTipoPluviometro() : mixed
getTotalAnexo()
Get the value of totalAnexo
public
getTotalAnexo() : mixed
getValorFazenda()
Get the value of valorFazenda
public
getValorFazenda() : mixed
getValorITR()
Get the value of valorITR
public
getValorITR() : mixed
getValorMatricula()
Get the value of valorMatricula
public
getValorMatricula() : mixed
getValorVenda()
Get the value of valorVenda
public
getValorVenda() : mixed
hasField()
public
static hasField(mixed $field) : mixed
Parameters
- $field : mixed
insert()
public
insert() : null|Entity
Return values
null|Entityinsert_or_select()
Funcao que insere ou seleciona se existe
public
insert_or_select([mixed $where = [] ]) : null|Entity
Parameters
- $where : mixed = []
Return values
null|Entityinsert_or_update()
Funcao que insere ou atualiza uma entidade no banco de dados
public
insert_or_update([mixed $where = [] ][, mixed $update_fields = ['*'] ]) : array<string|int, mixed>
Parameters
- $where : mixed = []
- $update_fields : mixed = ['*']
Return values
array<string|int, mixed>securityDelete()
public
securityDelete(mixed $table, mixed $where) : bool
Parameters
- $table : mixed
- $where : mixed
Return values
boolsecurityInsert()
public
securityInsert(mixed $fields) : bool
Parameters
- $fields : mixed
Return values
bool —return 'true' if the security function didn't find any security issue and 'false' otherwise
securitySelect()
public
securitySelect(mixed $table, mixed $fields, mixed $where) : array<string|int, mixed>
Parameters
- $table : mixed
- $fields : mixed
- $where : mixed
Return values
array<string|int, mixed> —return an array with information to be appended in the SQL select
securityUpdate()
public
securityUpdate(mixed $fields, mixed $where) : bool
Parameters
- $fields : mixed
- $where : mixed
Return values
bool —return 'true' if the security function didn't find any security issue and 'false' otherwise
setAnexoMatricula()
Set the value of anexoMatricula
public
setAnexoMatricula(mixed $anexoMatricula) : self
Parameters
- $anexoMatricula : mixed
Return values
selfsetAreaAlq()
Set the value of areaAlq
public
setAreaAlq(mixed $areaAlq) : self
Parameters
- $areaAlq : mixed
Return values
selfsetAreaHa()
Set the value of areaHa
public
setAreaHa(mixed $areaHa) : self
Parameters
- $areaHa : mixed
Return values
selfsetAreaUtilHa()
Set the value of areaUtilHa
public
setAreaUtilHa(mixed $areaUtilHa) : self
Parameters
- $areaUtilHa : mixed
Return values
selfsetCodigoINTSYS()
Set the value of codigoINTSYS
public
setCodigoINTSYS(mixed $codigoINTSYS) : self
Parameters
- $codigoINTSYS : mixed
Return values
selfsetCodigoINTSYSCONTABIL()
Set the value of codigoINTSYSCONTABIL
public
setCodigoINTSYSCONTABIL(mixed $codigoINTSYSCONTABIL) : self
Parameters
- $codigoINTSYSCONTABIL : mixed
Return values
selfsetCodigoMultbovinos()
Set the value of codigoMultbovinos
public
setCodigoMultbovinos(mixed $codigoMultbovinos) : self
Parameters
- $codigoMultbovinos : mixed
Return values
selfsetCustoAquisicao()
Set the value of custoAquisicao
public
setCustoAquisicao(mixed $custoAquisicao) : self
Parameters
- $custoAquisicao : mixed
Return values
selfsetDataAquisicao()
Set the value of dataAquisicao
public
setDataAquisicao(mixed $dataAquisicao) : self
Parameters
- $dataAquisicao : mixed
Return values
selfsetDataFinalizaArrend()
Set the value of dataFinalizaArrend
public
setDataFinalizaArrend(mixed $dataFinalizaArrend) : self
Parameters
- $dataFinalizaArrend : mixed
Return values
selfsetDataHora()
Set the value of DataHora
public
setDataHora(mixed $DataHora) : self
Parameters
- $DataHora : mixed
Return values
selfsetDataInicioArrend()
Set the value of dataInicioArrend
public
setDataInicioArrend(mixed $dataInicioArrend) : self
Parameters
- $dataInicioArrend : mixed
Return values
selfsetDataVenda()
Set the value of dataVenda
public
setDataVenda(mixed $dataVenda) : self
Parameters
- $dataVenda : mixed
Return values
selfsetIdContasPagar()
Set the value of idContasPagar
public
setIdContasPagar(mixed $idContasPagar) : self
Parameters
- $idContasPagar : mixed
Return values
selfsetIdFazenda()
Set the value of idFazenda
public
setIdFazenda(mixed $idFazenda) : self
Parameters
- $idFazenda : mixed
Return values
selfsetIdFazendaRelacao()
Set the value of idFazendaRelacao
public
setIdFazendaRelacao(mixed $idFazendaRelacao) : self
Parameters
- $idFazendaRelacao : mixed
Return values
selfsetIdUsuario()
Set the value of idUsuario
public
setIdUsuario(mixed $idUsuario) : self
Parameters
- $idUsuario : mixed
Return values
selfsetIdVariavelControle()
Set the value of idVariavelControle
public
setIdVariavelControle(mixed $idVariavelControle) : self
Parameters
- $idVariavelControle : mixed
Return values
selfsetInscricaoEstadual()
Set the value of inscricaoEstadual
public
setInscricaoEstadual(mixed $inscricaoEstadual) : self
Parameters
- $inscricaoEstadual : mixed
Return values
selfsetLat()
Set the value of lat
public
setLat(mixed $lat) : self
Parameters
- $lat : mixed
Return values
selfsetLng()
Set the value of lng
public
setLng(mixed $lng) : self
Parameters
- $lng : mixed
Return values
selfsetMatricula()
Set the value of matricula
public
setMatricula(mixed $matricula) : self
Parameters
- $matricula : mixed
Return values
selfsetMetros2()
Set the value of metros2
public
setMetros2(mixed $metros2) : self
Parameters
- $metros2 : mixed
Return values
selfsetNomeFazenda()
Set the value of nomeFazenda
public
setNomeFazenda(mixed $nomeFazenda) : self
Parameters
- $nomeFazenda : mixed
Return values
selfsetObs()
Set the value of obs
public
setObs(mixed $obs) : self
Parameters
- $obs : mixed
Return values
selfsetOrdem()
Set the value of ordem
public
setOrdem(mixed $ordem) : self
Parameters
- $ordem : mixed
Return values
selfsetTipo()
Set the value of tipo
public
setTipo(mixed $tipo) : self
Parameters
- $tipo : mixed
Return values
selfsetTipoPluviometro()
Set the value of tipoPluviometro
public
setTipoPluviometro(mixed $tipoPluviometro) : self
Parameters
- $tipoPluviometro : mixed
Return values
selfsetTotalAnexo()
Set the value of totalAnexo
public
setTotalAnexo(mixed $totalAnexo) : self
Parameters
- $totalAnexo : mixed
Return values
selfsetValorFazenda()
Set the value of valorFazenda
public
setValorFazenda(mixed $valorFazenda) : self
Parameters
- $valorFazenda : mixed
Return values
selfsetValorITR()
Set the value of valorITR
public
setValorITR(mixed $valorITR) : self
Parameters
- $valorITR : mixed
Return values
selfsetValorMatricula()
Set the value of valorMatricula
public
setValorMatricula(mixed $valorMatricula) : self
Parameters
- $valorMatricula : mixed
Return values
selfsetValorVenda()
Set the value of valorVenda
public
setValorVenda(mixed $valorVenda) : self
Parameters
- $valorVenda : mixed
Return values
selfupdate()
A função update pode atualizar uma Entity já instanciada, desde que a chave primária esteja setada, ou pode atualizar uma Entity vazia informando o valor da chave primária no segundo parâmetro (pk_value)
public
update(array<string|int, mixed> $values[, mixed $pk_value = null ]) : mixed
Parameters
- $values : array<string|int, mixed>
- $pk_value : mixed = null
validateFields()
public
validateFields([array<string|int, mixed> $fields = [] ]) : bool
Parameters
- $fields : array<string|int, mixed> = []
Return values
boolwhere()
Rudimentary ORM functions
public
static where([mixed $where = [] ][, mixed $select = '*' ]) : Collection
Parameters
- $where : mixed = []
- $select : mixed = '*'