Damdfe
extends DaCommon
in package
Table of Contents
Properties
- $aereo : mixed
- $aFont : array<string|int, mixed>
- $aquav : mixed
- $baseFont : mixed
- $cancelFlag : bool
- $CEP : mixed
- $chaves : mixed
- $chMDFe : mixed
- $ciot : mixed
- $CNPJ : mixed
- $condutor : mixed
- $CPF : mixed
- $creditos : string
- $cStat : mixed
- $cUnid : mixed
- $debugmode : bool
- $decimalPlaces : int
- $dhEmi : mixed
- $dhEvento : mixed
- $dhRecbto : mixed
- $emit : mixed
- $enderEmit : mixed
- $exibirDocumentosVinculados : bool
- Define se vai ou não exibir as chaves de CT-e, NF-e e MDF-e vinculadas a essa MDF-e
- $ferrov : mixed
- $flagDocs : mixed
- $fontePadrao : string
- $formatoChave : mixed
- $hPrint : float
- $id : mixed
- $ide : mixed
- $IE : mixed
- $infAdFisco : mixed
- $infCpl : mixed
- $infMDFe : mixed
- $infModal : mixed
- $infPercurso : mixed
- $logoAlign : string
- $logomarca : string
- $margemInterna : mixed
- $margesq : int
- $marginf : int
- $margsup : int
- $maxH : float
- $maxW : float
- $mdfeProc : mixed
- $mod : mixed
- $nMDF : mixed
- $nProt : mixed
- $nro : mixed
- $numdepec : string
- $orientacao : string
- $papel : string|array<string|int, mixed>
- $pdf : Pdf
- $powered : bool
- $qCarga : mixed
- $qCT : mixed
- $qCTe : mixed
- $qMDFe : mixed
- $qNF : mixed
- $qNFe : mixed
- $qrCodMDFe : mixed
- $quantidadeChavesLayout : mixed
- $RNTRC : mixed
- $rodo : mixed
- $serie : mixed
- $tot : mixed
- $tpAmb : mixed
- $tpEmis : mixed
- $UF : mixed
- $UFFim : mixed
- $UFIni : mixed
- $valePed : mixed
- $veicReboque : mixed
- $veicTracao : mixed
- $wPrint : float
- $xBairro : mixed
- $xIni : float
- $xLgr : mixed
- $xml : mixed
- $xMun : mixed
- $xNome : mixed
- $yIni : float
- $dom : mixed
Methods
- __construct() : mixed
- __construct
- buildMDFe() : mixed
- buildMDFe
- creditsIntegratorFooter() : void
- Add the credits to the integrator in the footer message
- debugMode() : bool
- Ativa ou desativa o modo debug
- depecNumber() : void
- Numero DPEC
- logoParameters() : void
- Set logo e sua posição
- printParameters() : void
- Define parametros de impressão
- render() : string
- Renderiza o pdf e retorna como raw
- setCancelFlag() : mixed
- Atribui uma sinalização de cancelamento externa
- setDefaultDecimalPlaces() : mixed
- Seta o numero de casas decimais a serem usadas como padrão
- setDefaultFont() : mixed
- Seta a fonte padrão é times
- setExibirDocumentosVinculados() : void
- toDateTime() : DateTime|false
- Converte data da NFe YYYY-mm-ddThh:mm:ss-03:00 para \DateTime
- toTimestamp() : int
- Converte data da NFe YYYY-mm-ddThh:mm:ss-03:00 para timestamp unix
- addPage() : mixed
- adjustImage() : string
- Ajusta a imagem do logo
- formatField() : string
- Função de formatação de strings onde o cerquilha # é um coringa que será substituido por digitos contidos em campo.
- getTagDate() : string
- Recupera e reformata a data do padrão da NFe para dd/mm/aaaa
- getTagValue() : string
- Extrai o valor do node DOM
- modulo11() : int
- camcula digito de controle modulo 11
- monta() : mixed
- Metodo de montagem do PDF
- qrCodeDamdfe() : mixed
- statusMDFe() : array<string|int, mixed>
- Verifica o status da MDFe
- tipoPag() : mixed
- ymdTodmy() : string
- Converte datas no formato YMD (ex. 2009-11-02) para o formato brasileiro 02/11/2009)
- bodyMDFe() : void
- bodyMDFe
- footerMDFe() : mixed
- footerMDFe
- headerMDFePaisagem() : string
- headerMDFePaisagem
- headerMDFeRetrato() : string
- headerMDFeRetrato
- loadDoc() : mixed
Properties
$aereo
protected
mixed
$aereo
$aFont
protected
array<string|int, mixed>
$aFont
= ['font' => 'times', 'size' => 8, 'style' => '']
$aquav
protected
mixed
$aquav
$baseFont
protected
mixed
$baseFont
= array('font' => 'arial', 'size' => 8, 'style' => '')
$cancelFlag
protected
bool
$cancelFlag
= false
$CEP
protected
mixed
$CEP
$chaves
protected
mixed
$chaves
= []
$chMDFe
protected
mixed
$chMDFe
$ciot
protected
mixed
$ciot
$CNPJ
protected
mixed
$CNPJ
$condutor
protected
mixed
$condutor
$CPF
protected
mixed
$CPF
$creditos
protected
string
$creditos
$cStat
protected
mixed
$cStat
$cUnid
protected
mixed
$cUnid
$debugmode
protected
bool
$debugmode
$decimalPlaces
protected
int
$decimalPlaces
$dhEmi
protected
mixed
$dhEmi
$dhEvento
protected
mixed
$dhEvento
$dhRecbto
protected
mixed
$dhRecbto
$emit
protected
mixed
$emit
$enderEmit
protected
mixed
$enderEmit
$exibirDocumentosVinculados
Define se vai ou não exibir as chaves de CT-e, NF-e e MDF-e vinculadas a essa MDF-e
protected
bool
$exibirDocumentosVinculados
= true
$ferrov
protected
mixed
$ferrov
$flagDocs
protected
mixed
$flagDocs
= false
$fontePadrao
protected
string
$fontePadrao
= 'times'
$formatoChave
protected
mixed
$formatoChave
= "#### #### #### #### #### #### #### #### #### #### ####"
$hPrint
protected
float
$hPrint
$id
protected
mixed
$id
$ide
protected
mixed
$ide
$IE
protected
mixed
$IE
$infAdFisco
protected
mixed
$infAdFisco
$infCpl
protected
mixed
$infCpl
$infMDFe
protected
mixed
$infMDFe
$infModal
protected
mixed
$infModal
$infPercurso
protected
mixed
$infPercurso
$logoAlign
protected
string
$logoAlign
= 'L'
$logomarca
protected
string
$logomarca
$margemInterna
protected
mixed
$margemInterna
= 2
$margesq
protected
int
$margesq
= 2
$marginf
protected
int
$marginf
= 2
$margsup
protected
int
$margsup
= 2
$maxH
protected
float
$maxH
$maxW
protected
float
$maxW
$mdfeProc
protected
mixed
$mdfeProc
$mod
protected
mixed
$mod
$nMDF
protected
mixed
$nMDF
$nProt
protected
mixed
$nProt
$nro
protected
mixed
$nro
$numdepec
protected
string
$numdepec
$orientacao
protected
string
$orientacao
$papel
protected
string|array<string|int, mixed>
$papel
= 'A4'
protected
Pdf
$pdf
$powered
protected
bool
$powered
= true
$qCarga
protected
mixed
$qCarga
$qCT
protected
mixed
$qCT
$qCTe
protected
mixed
$qCTe
$qMDFe
protected
mixed
$qMDFe
$qNF
protected
mixed
$qNF
$qNFe
protected
mixed
$qNFe
$qrCodMDFe
protected
mixed
$qrCodMDFe
$quantidadeChavesLayout
protected
mixed
$quantidadeChavesLayout
= 20
$RNTRC
protected
mixed
$RNTRC
$rodo
protected
mixed
$rodo
$serie
protected
mixed
$serie
$tot
protected
mixed
$tot
$tpAmb
protected
mixed
$tpAmb
$tpEmis
protected
mixed
$tpEmis
$UF
protected
mixed
$UF
$UFFim
protected
mixed
$UFFim
$UFIni
protected
mixed
$UFIni
$valePed
protected
mixed
$valePed
$veicReboque
protected
mixed
$veicReboque
$veicTracao
protected
mixed
$veicTracao
$wPrint
protected
float
$wPrint
$xBairro
protected
mixed
$xBairro
$xIni
protected
float
$xIni
$xLgr
protected
mixed
$xLgr
$xml
protected
mixed
$xml
$xMun
protected
mixed
$xMun
$xNome
protected
mixed
$xNome
$yIni
protected
float
$yIni
$dom
private
mixed
$dom
Methods
__construct()
__construct
public
__construct(string $xml) : mixed
Parameters
- $xml : string
-
Arquivo XML da MDFe
buildMDFe()
buildMDFe
public
buildMDFe() : mixed
creditsIntegratorFooter()
Add the credits to the integrator in the footer message
public
creditsIntegratorFooter([string $message = '' ][, bool $powered = true ]) : void
Parameters
- $message : string = ''
-
Mensagem do integrador a ser impressa no rodapé das paginas
- $powered : bool = true
debugMode()
Ativa ou desativa o modo debug
public
debugMode([bool $activate = null ]) : bool
Parameters
- $activate : bool = null
-
Ativa ou desativa o modo debug
Tags
Return values
booldepecNumber()
Numero DPEC
public
depecNumber(string $numdepec) : void
Parameters
- $numdepec : string
logoParameters()
Set logo e sua posição
public
logoParameters(string $logo[, string $logoAlign = null ][, bool $mode_bw = false ]) : void
Parameters
- $logo : string
- $logoAlign : string = null
- $mode_bw : bool = false
-
se true converte a imagem em branco e preto
printParameters()
Define parametros de impressão
public
printParameters([string $orientacao = '' ][, string $papel = 'A4' ][, int $margSup = 2 ][, int $margEsq = 2 ]) : void
Parameters
- $orientacao : string = ''
- $papel : string = 'A4'
- $margSup : int = 2
- $margEsq : int = 2
render()
Renderiza o pdf e retorna como raw
public
render([string $logo = '' ]) : string
Parameters
- $logo : string = ''
Return values
stringsetCancelFlag()
Atribui uma sinalização de cancelamento externa
public
setCancelFlag([bool $cancelFlag = true ]) : mixed
Parameters
- $cancelFlag : bool = true
setDefaultDecimalPlaces()
Seta o numero de casas decimais a serem usadas como padrão
public
setDefaultDecimalPlaces(int $dec) : mixed
Parameters
- $dec : int
setDefaultFont()
Seta a fonte padrão é times
public
setDefaultFont([string $font = 'times' ]) : mixed
Parameters
- $font : string = 'times'
setExibirDocumentosVinculados()
public
setExibirDocumentosVinculados(bool $exibirDocumentosVinculados) : void
Parameters
- $exibirDocumentosVinculados : bool
toDateTime()
Converte data da NFe YYYY-mm-ddThh:mm:ss-03:00 para \DateTime
public
toDateTime(string $input) : DateTime|false
Parameters
- $input : string
Return values
DateTime|falsetoTimestamp()
Converte data da NFe YYYY-mm-ddThh:mm:ss-03:00 para timestamp unix
public
toTimestamp(string $input) : int
Parameters
- $input : string
Return values
intaddPage()
protected
addPage() : mixed
adjustImage()
Ajusta a imagem do logo
protected
adjustImage(string $logo[, bool $turn_bw = false ]) : string
Parameters
- $logo : string
- $turn_bw : bool = false
Tags
Return values
stringformatField()
Função de formatação de strings onde o cerquilha # é um coringa que será substituido por digitos contidos em campo.
protected
formatField([string $campo = '' ][, string $mascara = '' ]) : string
Parameters
- $campo : string = ''
-
String a ser formatada
- $mascara : string = ''
-
Regra de formatção da string (ex. ##.###.###/####-##)
Return values
string —Retorna o campo formatado
getTagDate()
Recupera e reformata a data do padrão da NFe para dd/mm/aaaa
protected
getTagDate(DOM $theObj, string $keyName[, string $extraText = '' ]) : string
Parameters
- $theObj : DOM
- $keyName : string
-
identificador da TAG do xml
- $extraText : string = ''
-
prefixo do retorno
Tags
Return values
stringgetTagValue()
Extrai o valor do node DOM
protected
getTagValue(object $theObj, string $keyName[, string $extraTextBefore = '' ][, mixed $extraTextAfter = '' ][, mixed $itemNum = 0 ]) : string
Parameters
- $theObj : object
-
Instancia de DOMDocument ou DOMElement
- $keyName : string
-
identificador da TAG do xml
- $extraTextBefore : string = ''
-
prefixo do retorno
- $extraTextAfter : mixed = ''
- $itemNum : mixed = 0
Return values
stringmodulo11()
camcula digito de controle modulo 11
protected
modulo11([string $numero = '' ]) : int
Parameters
- $numero : string = ''
Return values
int —modulo11 do numero passado
monta()
Metodo de montagem do PDF
protected
monta([mixed $logo = '' ]) : mixed
Parameters
- $logo : mixed = ''
qrCodeDamdfe()
protected
qrCodeDamdfe([mixed $y = 0 ]) : mixed
Parameters
- $y : mixed = 0
statusMDFe()
Verifica o status da MDFe
protected
statusMDFe() : array<string|int, mixed>
Return values
array<string|int, mixed>tipoPag()
protected
tipoPag(mixed $tPag) : mixed
Parameters
- $tPag : mixed
ymdTodmy()
Converte datas no formato YMD (ex. 2009-11-02) para o formato brasileiro 02/11/2009)
protected
ymdTodmy([string $data = '' ]) : string
Parameters
- $data : string = ''
-
Parâmetro extraido da NFe
Return values
string —Formatada para apresentação da data no padrão brasileiro
bodyMDFe()
bodyMDFe
private
bodyMDFe(float $x, float $y) : void
Parameters
- $x : float
- $y : float
footerMDFe()
footerMDFe
private
footerMDFe(float $x, float $y) : mixed
Parameters
- $x : float
- $y : float
headerMDFePaisagem()
headerMDFePaisagem
private
headerMDFePaisagem(float $x, float $y) : string
Parameters
- $x : float
- $y : float
Return values
stringheaderMDFeRetrato()
headerMDFeRetrato
private
headerMDFeRetrato(float $x, float $y) : string
Parameters
- $x : float
- $y : float
Return values
stringloadDoc()
private
loadDoc(mixed $xml) : mixed
Parameters
- $xml : mixed