Skip to content

Commit

Permalink
Merge pull request #530 from robmachado/master
Browse files Browse the repository at this point in the history
ajustes PSR2
  • Loading branch information
robmachado authored Nov 19, 2023
2 parents 492903c + ab6b41e commit 90a0680
Show file tree
Hide file tree
Showing 6 changed files with 36 additions and 30 deletions.
1 change: 0 additions & 1 deletion src/Factories/EvtContProc.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,5 +59,4 @@ public function __construct(
) {
parent::__construct($config, $std, $certificate, $date);
}

}
1 change: 0 additions & 1 deletion src/Factories/EvtProcTrab.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,5 +59,4 @@ public function __construct(
) {
parent::__construct($config, $std, $certificate, $date);
}

}
20 changes: 10 additions & 10 deletions src/Factories/Traits/TraitS1210.php
Original file line number Diff line number Diff line change
Expand Up @@ -473,7 +473,7 @@ protected function toNodeS120()
false
);
if (!empty($comp->infodep)) {
foreach($comp->infodep as $dep) {
foreach ($comp->infodep as $dep) {
$infodep = $this->dom->createElement("infoDep");
$this->dom->addChild(
$infodep,
Expand Down Expand Up @@ -525,7 +525,7 @@ protected function toNodeS120()
true
);
if (!empty($rc->deddepen)) {
foreach($rc->deddepen as $ded) {
foreach ($rc->deddepen as $ded) {
$dpen = $this->dom->createElement("dedDepen");
$this->dom->addChild(
$dpen,
Expand Down Expand Up @@ -624,7 +624,7 @@ protected function toNodeS120()
false
);
if (!empty($infp->infovalores)) {
foreach($infp->infovalores as $val) {
foreach ($infp->infovalores as $val) {
$ival = $this->dom->createElement("infoValores");
$this->dom->addChild(
$ival,
Expand Down Expand Up @@ -663,7 +663,7 @@ protected function toNodeS120()
false
);
if (!empty($val->dedsusp)) {
foreach($val->dedsusp as $susp) {
foreach ($val->dedsusp as $susp) {
$dsu = $this->dom->createElement("dedSusp");
$this->dom->addChild(
$dsu,
Expand All @@ -690,7 +690,7 @@ protected function toNodeS120()
false
);
if (!empty($susp->benefpen)) {
foreach($susp->benefpen as $ben) {
foreach ($susp->benefpen as $ben) {
$bpen = $this->dom->createElement("benefPen");
$this->dom->addChild(
$bpen,
Expand Down Expand Up @@ -719,7 +719,7 @@ protected function toNodeS120()
$infocomp->appendChild($ircr);
}
if (!empty($comp->plansaude)) {
foreach($comp->plansaude as $sau) {
foreach ($comp->plansaude as $sau) {
$psau = $this->dom->createElement("planSaude");
$this->dom->addChild(
$psau,
Expand All @@ -740,7 +740,7 @@ protected function toNodeS120()
true
);
if (!empty($sau->infodepsau)) {
foreach($sau->infodepsau as $dep) {
foreach ($sau->infodepsau as $dep) {
$idep = $this->dom->createElement("infoDepSau");
$this->dom->addChild(
$idep,
Expand All @@ -761,7 +761,7 @@ protected function toNodeS120()
}
}
if (!empty($comp->inforeembmed)) {
foreach($comp->inforeembmed as $ree) {
foreach ($comp->inforeembmed as $ree) {
$iree = $this->dom->createElement("infoReembMed");
$this->dom->addChild(
$iree,
Expand All @@ -782,7 +782,7 @@ protected function toNodeS120()
false
);
if (!empty($ree->detreembtit)) {
foreach($ree->detreembtit as $tit) {
foreach ($ree->detreembtit as $tit) {
$rtit = $this->dom->createElement("detReembTit");
$this->dom->addChild(
$rtit,
Expand Down Expand Up @@ -821,7 +821,7 @@ protected function toNodeS120()
true
);
if (!empty($bdep->detreembdep)) {
foreach($bdep->detreembdep as $drdep) {
foreach ($bdep->detreembdep as $drdep) {
$detree = $this->dom->createElement("detReembDep");
$this->dom->addChild(
$detree,
Expand Down
10 changes: 5 additions & 5 deletions src/Factories/Traits/TraitS2500.php
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ protected function toNodeS110()
}
$idetrab->appendChild($dependente);
}
foreach($this->std->infocontr as $ict) {
foreach ($this->std->infocontr as $ict) {
$infoc = $this->dom->createElement("infoContr");
$this->dom->addChild(
$infoc,
Expand Down Expand Up @@ -801,7 +801,7 @@ protected function toNodeS120()
$this->std->dtnascto ?? null,
false
);
foreach($this->std->infocontr as $ictr) {
foreach ($this->std->infocontr as $ictr) {
$infoctr = $this->dom->createElement("infoContr");
$this->dom->addChild(
$infoctr,
Expand Down Expand Up @@ -879,7 +879,7 @@ protected function toNodeS120()
false
);
if (!empty($icl->remuneracao)) {
foreach($icl->remuneracao as $rem) {
foreach ($icl->remuneracao as $rem) {
$remu = $this->dom->createElement("remuneracao");
$this->dom->addChild(
$remu,
Expand Down Expand Up @@ -965,7 +965,7 @@ protected function toNodeS120()
$infoVinc->appendChild($duracao);
}
if (!empty($vinc->observacoes)) {
foreach($vinc->observacoes as $obs) {
foreach ($vinc->observacoes as $obs) {
$observacoes = $this->dom->createElement("observacoes");
$this->dom->addChild(
$observacoes,
Expand Down Expand Up @@ -1065,7 +1065,7 @@ protected function toNodeS120()
}
$infoctr->appendChild($icom);
if (!empty($ictr->mudcategativ)) {
foreach($ictr->mudcategativ as $mud) {
foreach ($ictr->mudcategativ as $mud) {
$mudCategAtiv = $this->dom->createElement("mudCategAtiv");
$this->dom->addChild(
$mudCategAtiv,
Expand Down
33 changes: 21 additions & 12 deletions src/Factories/Traits/TraitS2501.php
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ protected function toNodeS110()
$att = $this->dom->createAttribute('cpfTrab');
$att->value = $this->std->cpftrab;
$idetrab->appendChild($att);
foreach($this->std->calctrib as $calc) {
foreach ($this->std->calctrib as $calc) {
$calctrib = $this->dom->createElement("calcTrib");
$att0 = $this->dom->createAttribute('perRef');
$att0->value = $calc->perref;
Expand All @@ -100,7 +100,7 @@ protected function toNodeS110()
$att4 = $this->dom->createAttribute('vrRendIRRF13');
$att4->value = $calc->vrrendirrf13;
$calctrib->appendChild($att4);
foreach($calc->infocrcontrib as $info) {
foreach ($calc->infocrcontrib as $info) {
$infocont = $this->dom->createElement("infoCRContrib");
$att0 = $this->dom->createAttribute('tpCR');
$att0->value = $info->tpcr;
Expand All @@ -112,7 +112,7 @@ protected function toNodeS110()
}
$idetrab->appendChild($calctrib);
}
foreach($this->std->infocrirrf as $cr) {
foreach ($this->std->infocrirrf as $cr) {
$infoirrf = $this->dom->createElement("infoCRIRRF");
$att0 = $this->dom->createAttribute('tpCR');
$att0->value = $cr->tpcr;
Expand Down Expand Up @@ -194,7 +194,8 @@ protected function toNodeS120()
foreach ($this->std->idetrab as $ide) {
$idetrab = $this->dom->createElement("ideTrab");
$this->dom->addAttribute($idetrab, 'cpfTrab', $ide->cpftrab);
if (!empty($ide->calctrib)) {}
if (!empty($ide->calctrib)) {
}
if (!empty($ide->infocrirrf)) {
foreach ($ide->infocrirrf as $cr) {
$infocrirrf = $this->dom->createElement("infoCRIRRF");
Expand Down Expand Up @@ -226,7 +227,7 @@ protected function toNodeS120()
$inforra->appendChild($despprocjud);
}
if (!empty($rra->ideadv)) {
foreach($rra->ideadv as $adv) {
foreach ($rra->ideadv as $adv) {
$ideadv = $this->dom->createElement("ideAdv");
$this->dom->addAttribute($ideadv, 'tpInsc', $adv->tpinsc ?? null);
$this->dom->addAttribute($ideadv, 'nrInsc', $adv->nrinsc ?? null);
Expand All @@ -246,7 +247,7 @@ protected function toNodeS120()
}
}
if (!empty($cr->penalim)) {
foreach($cr->penalim as $pen) {
foreach ($cr->penalim as $pen) {
$penalim = $this->dom->createElement("penAlim");
$this->dom->addAttribute($penalim, 'tpRend', $pen->tprend ?? null);
$this->dom->addAttribute($penalim, 'cpfDep', $pen->cpfdep ?? null);
Expand All @@ -261,7 +262,7 @@ protected function toNodeS120()
$this->dom->addAttribute($infoprocret, 'nrProcRet', $ret->nrprocret ?? null);
$this->dom->addAttribute($infoprocret, 'codSusp', $ret->codsusp ?? null);
if (!empty($ret->infovalores)) {
foreach($ret->infovalores as $val) {
foreach ($ret->infovalores as $val) {
$infovalores = $this->dom->createElement("infoValores");
$this->dom->addAttribute($infovalores, 'indApuracao', $val->indapuracao ?? null);
$this->dom->addAttribute($infovalores, 'vlrNRetido', $val->vlrnretido ?? null);
Expand All @@ -270,15 +271,23 @@ protected function toNodeS120()
$this->dom->addAttribute($infovalores, 'vlrCmpAnoAnt', $val->vlrcmpanoant ?? null);
$this->dom->addAttribute($infovalores, 'vlrRendSusp', $val->vlrrendsusp ?? null);
if (!empty($val->dedsusp)) {
foreach($val->dedsusp as $sus) {
foreach ($val->dedsusp as $sus) {
$dedsusp = $this->dom->createElement("dedSusp");
$this->dom->addAttribute($dedsusp, 'indTpDeducao', $sus->indtpdeducao ?? null);
$this->dom->addAttribute(
$dedsusp,
'indTpDeducao',
$sus->indtpdeducao ?? null
);
$this->dom->addAttribute($dedsusp, 'vlrDedSusp', $sus->vlrdedsusp ?? null);
if (!empty($sus->benefpen)) {
foreach($sus->benefpen as $ben) {
foreach ($sus->benefpen as $ben) {
$benefpen = $this->dom->createElement("benefPen");
$this->dom->addAttribute($benefpen, 'cpfDep', $ben->cpfdep ?? null);
$this->dom->addAttribute($benefpen, 'vlrDepenSusp', $ben->vlrdepensusp ?? null);
$this->dom->addAttribute(
$benefpen,
'vlrDepenSusp',
$ben->vlrdepensusp ?? null
);
$dedsusp->appendChild($benefpen);
}
}
Expand All @@ -298,7 +307,7 @@ protected function toNodeS120()
$infoircomplem = $this->dom->createElement("infoIRComplem");
$this->dom->addAttribute($infoircomplem, 'dtLaudo', $ide->infoircomplem->dtlaudo ?? null);
if (!empty($ide->infoircomplem->infodep)) {
foreach($ide->infoircomplem->infodep as $dep) {
foreach ($ide->infoircomplem->infodep as $dep) {
$infodep = $this->dom->createElement("infoDep");
$this->dom->addAttribute($infodep, 'cpfDep', $dep->cpfdep ?? null);
$this->dom->addAttribute($infodep, 'dtNascto', $dep->dtnascto ?? null);
Expand Down
1 change: 0 additions & 1 deletion src/Factories/Traits/TraitS8200.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,4 @@ protected function toNodeS120()
{
//sem necessidade de criação do evento pois somente pode ser enviado pelo poder judiciário
}

}

0 comments on commit 90a0680

Please sign in to comment.