@@ -76,7 +76,7 @@ |
||
| 76 | 76 | $this->dom->addChild( |
| 77 | 77 | $ideEvento, |
| 78 | 78 | "nrRecibo", |
| 79 | - ! empty($this->std->nrrecibo) ? $this->std->nrrecibo : null, |
|
| 79 | + !empty($this->std->nrrecibo) ? $this->std->nrrecibo : null, |
|
| 80 | 80 | false |
| 81 | 81 | ); |
| 82 | 82 | $this->dom->addChild( |
@@ -4,7 +4,6 @@ |
||
| 4 | 4 | |
| 5 | 5 | /** |
| 6 | 6 | * Class eSocial EvtTSVInicio Event S-2300 constructor |
| 7 | - |
|
| 8 | 7 | * Read for 2.5.0 layout |
| 9 | 8 | * |
| 10 | 9 | * @category library |
@@ -69,7 +69,7 @@ discard block |
||
| 69 | 69 | $this->dom->addChild( |
| 70 | 70 | $ideEvento, |
| 71 | 71 | "nrRecArqBase", |
| 72 | - ! empty($this->std->nrrecarqbase) ? $this->std->nrrecarqbase : null, |
|
| 72 | + !empty($this->std->nrrecarqbase) ? $this->std->nrrecarqbase : null, |
|
| 73 | 73 | false |
| 74 | 74 | ); |
| 75 | 75 | $this->dom->addChild( |
@@ -87,7 +87,7 @@ discard block |
||
| 87 | 87 | true |
| 88 | 88 | ); |
| 89 | 89 | $this->node->appendChild($ideTrabalhador); |
| 90 | - if (! empty($this->std->vrdeddep)) { |
|
| 90 | + if (!empty($this->std->vrdeddep)) { |
|
| 91 | 91 | $infoDep = $this->dom->createElement("infoDep"); |
| 92 | 92 | $this->dom->addChild( |
| 93 | 93 | $infoDep, |
@@ -102,7 +102,7 @@ discard block |
||
| 102 | 102 | $this->dom->addChild( |
| 103 | 103 | $infoIrrf, |
| 104 | 104 | "codCateg", |
| 105 | - ! empty($nIrrf->codcateg) ? $nIrrf->codcateg : null, |
|
| 105 | + !empty($nIrrf->codcateg) ? $nIrrf->codcateg : null, |
|
| 106 | 106 | false |
| 107 | 107 | ); |
| 108 | 108 | $this->dom->addChild( |
@@ -161,7 +161,7 @@ discard block |
||
| 161 | 161 | $this->dom->addChild( |
| 162 | 162 | $idePais, |
| 163 | 163 | "nifBenef", |
| 164 | - ! empty($nIrrf->idepgtoext->nifbenef) ? $nIrrf->idepgtoext->nifbenef : null, |
|
| 164 | + !empty($nIrrf->idepgtoext->nifbenef) ? $nIrrf->idepgtoext->nifbenef : null, |
|
| 165 | 165 | false |
| 166 | 166 | ); |
| 167 | 167 | $idePgtoExt->appendChild($idePais); |
@@ -176,19 +176,19 @@ discard block |
||
| 176 | 176 | $this->dom->addChild( |
| 177 | 177 | $endExt, |
| 178 | 178 | "nrLograd", |
| 179 | - ! empty($nIrrf->idepgtoext->nrlograd) ? $nIrrf->idepgtoext->nrlograd : null, |
|
| 179 | + !empty($nIrrf->idepgtoext->nrlograd) ? $nIrrf->idepgtoext->nrlograd : null, |
|
| 180 | 180 | false |
| 181 | 181 | ); |
| 182 | 182 | $this->dom->addChild( |
| 183 | 183 | $endExt, |
| 184 | 184 | "complem", |
| 185 | - ! empty($nIrrf->idepgtoext->complem) ? $nIrrf->idepgtoext->complem : null, |
|
| 185 | + !empty($nIrrf->idepgtoext->complem) ? $nIrrf->idepgtoext->complem : null, |
|
| 186 | 186 | false |
| 187 | 187 | ); |
| 188 | 188 | $this->dom->addChild( |
| 189 | 189 | $endExt, |
| 190 | 190 | "bairro", |
| 191 | - ! empty($nIrrf->idepgtoext->bairro) ? $nIrrf->idepgtoext->bairro : null, |
|
| 191 | + !empty($nIrrf->idepgtoext->bairro) ? $nIrrf->idepgtoext->bairro : null, |
|
| 192 | 192 | false |
| 193 | 193 | ); |
| 194 | 194 | $this->dom->addChild( |
@@ -200,7 +200,7 @@ discard block |
||
| 200 | 200 | $this->dom->addChild( |
| 201 | 201 | $endExt, |
| 202 | 202 | "codPostal", |
| 203 | - ! empty($nIrrf->idepgtoext->codpostal) ? $nIrrf->idepgtoext->codpostal : null, |
|
| 203 | + !empty($nIrrf->idepgtoext->codpostal) ? $nIrrf->idepgtoext->codpostal : null, |
|
| 204 | 204 | false |
| 205 | 205 | ); |
| 206 | 206 | $idePgtoExt->appendChild($endExt); |
@@ -4,7 +4,6 @@ |
||
| 4 | 4 | |
| 5 | 5 | /** |
| 6 | 6 | * Class eSocial EvtIrrfBenef Event S-5002 constructor |
| 7 | - |
|
| 8 | 7 | * Read for 2.5.0 layout |
| 9 | 8 | * |
| 10 | 9 | * @category library |
@@ -235,8 +235,7 @@ |
||
| 235 | 235 | $this->dom->addChild( |
| 236 | 236 | $instEnsino, |
| 237 | 237 | "bairro", |
| 238 | - !empty($this->std->estagiario->instituicao->bairro) ? $this->std->estagiario->instituicao->bairro : |
|
| 239 | - null, |
|
| 238 | + !empty($this->std->estagiario->instituicao->bairro) ? $this->std->estagiario->instituicao->bairro : null, |
|
| 240 | 239 | false |
| 241 | 240 | ); |
| 242 | 241 | $this->dom->addChild( |
@@ -4,7 +4,6 @@ |
||
| 4 | 4 | |
| 5 | 5 | /** |
| 6 | 6 | * Class eSocial EvtTSVAltContr Event S-2306 constructor |
| 7 | - |
|
| 8 | 7 | * Read for 2.5.0 layout |
| 9 | 8 | * |
| 10 | 9 | * @category library |
@@ -57,7 +57,7 @@ discard block |
||
| 57 | 57 | */ |
| 58 | 58 | public function toStd($xml = null) |
| 59 | 59 | { |
| 60 | - if (! empty($xml)) { |
|
| 60 | + if (!empty($xml)) { |
|
| 61 | 61 | $this->whichIs($xml); |
| 62 | 62 | } |
| 63 | 63 | $sxml = simplexml_load_string($this->node); |
@@ -77,7 +77,7 @@ discard block |
||
| 77 | 77 | */ |
| 78 | 78 | public function whichIs($xml) |
| 79 | 79 | { |
| 80 | - if (! Validator::isXML($xml)) { |
|
| 80 | + if (!Validator::isXML($xml)) { |
|
| 81 | 81 | throw new InvalidArgumentException( |
| 82 | 82 | "O argumento passado não é um XML válido." |
| 83 | 83 | ); |
@@ -87,10 +87,10 @@ discard block |
||
| 87 | 87 | $dom->formatOutput = false; |
| 88 | 88 | $dom->loadXML($xml); |
| 89 | 89 | foreach ($this->rootTagList as $key) { |
| 90 | - $node = ! empty($dom->getElementsByTagName($key)->item(0)) |
|
| 90 | + $node = !empty($dom->getElementsByTagName($key)->item(0)) |
|
| 91 | 91 | ? $dom->getElementsByTagName($key)->item(0) |
| 92 | 92 | : ''; |
| 93 | - if (! empty($node)) { |
|
| 93 | + if (!empty($node)) { |
|
| 94 | 94 | $this->node = $dom->saveXML($node); |
| 95 | 95 | return $key; |
| 96 | 96 | } |
@@ -116,7 +116,7 @@ discard block |
||
| 116 | 116 | */ |
| 117 | 117 | public function toJson($xml = null) |
| 118 | 118 | { |
| 119 | - if (! empty($xml)) { |
|
| 119 | + if (!empty($xml)) { |
|
| 120 | 120 | $this->toStd($xml); |
| 121 | 121 | } |
| 122 | 122 | return $this->json; |
@@ -129,7 +129,7 @@ discard block |
||
| 129 | 129 | */ |
| 130 | 130 | public function toArray($xml = null) |
| 131 | 131 | { |
| 132 | - if (! empty($xml)) { |
|
| 132 | + if (!empty($xml)) { |
|
| 133 | 133 | $this->toStd($xml); |
| 134 | 134 | } |
| 135 | 135 | return json_decode($this->json, true); |
@@ -123,14 +123,14 @@ |
||
| 123 | 123 | $orig .= "$p->"; |
| 124 | 124 | } |
| 125 | 125 | $exist = false; |
| 126 | - $test = "\$exist = (!empty(".substr($orig, 0, strlen($orig) - 2).")) ? true : false;"; |
|
| 126 | + $test = "\$exist = (!empty(" . substr($orig, 0, strlen($orig) - 2) . ")) ? true : false;"; |
|
| 127 | 127 | eval($test); |
| 128 | 128 | } |
| 129 | 129 | $orig .= $name; |
| 130 | 130 | $resp = null; |
| 131 | 131 | eval("\$resp = $orig;"); |
| 132 | 132 | if (!empty($resp) || $resp === 0) { |
| 133 | - $comm .= $name.'= $resp'; |
|
| 133 | + $comm .= $name . '= $resp'; |
|
| 134 | 134 | } else { |
| 135 | 135 | $comm .= "$name = null"; |
| 136 | 136 | } |
@@ -76,7 +76,7 @@ discard block |
||
| 76 | 76 | $this->dom->addChild( |
| 77 | 77 | $ideEvento, |
| 78 | 78 | "nrRecibo", |
| 79 | - ! empty($this->std->nrrecibo) ? $this->std->nrrecibo : null, |
|
| 79 | + !empty($this->std->nrrecibo) ? $this->std->nrrecibo : null, |
|
| 80 | 80 | false |
| 81 | 81 | ); |
| 82 | 82 | $this->dom->addChild( |
@@ -119,7 +119,7 @@ discard block |
||
| 119 | 119 | ); |
| 120 | 120 | $this->node->appendChild($ideVinculo); |
| 121 | 121 | $infoAvPrevio = $this->dom->createElement("infoAvPrevio"); |
| 122 | - if (! empty($this->std->infoavprevio->detavprevio)) { |
|
| 122 | + if (!empty($this->std->infoavprevio->detavprevio)) { |
|
| 123 | 123 | $detAvPrevio = $this->dom->createElement("detAvPrevio"); |
| 124 | 124 | $this->dom->addChild( |
| 125 | 125 | $detAvPrevio, |
@@ -142,13 +142,13 @@ discard block |
||
| 142 | 142 | $this->dom->addChild( |
| 143 | 143 | $detAvPrevio, |
| 144 | 144 | "observacao", |
| 145 | - ! empty($this->std->infoavprevio->detavprevio->observacao) ? |
|
| 145 | + !empty($this->std->infoavprevio->detavprevio->observacao) ? |
|
| 146 | 146 | $this->std->infoavprevio->detavprevio->observacao : null, |
| 147 | 147 | false |
| 148 | 148 | ); |
| 149 | 149 | $infoAvPrevio->appendChild($detAvPrevio); |
| 150 | 150 | } |
| 151 | - if (! empty($this->std->infoavprevio->cancavprevio)) { |
|
| 151 | + if (!empty($this->std->infoavprevio->cancavprevio)) { |
|
| 152 | 152 | $cancAvPrevio = $this->dom->createElement("cancAvPrevio"); |
| 153 | 153 | $this->dom->addChild( |
| 154 | 154 | $cancAvPrevio, |
@@ -159,7 +159,7 @@ discard block |
||
| 159 | 159 | $this->dom->addChild( |
| 160 | 160 | $cancAvPrevio, |
| 161 | 161 | "observacao", |
| 162 | - ! empty($this->std->infoavprevio->cancavprevio->observacao) ? |
|
| 162 | + !empty($this->std->infoavprevio->cancavprevio->observacao) ? |
|
| 163 | 163 | $this->std->infoavprevio->cancavprevio->observacao : null, |
| 164 | 164 | false |
| 165 | 165 | ); |
@@ -105,7 +105,7 @@ discard block |
||
| 105 | 105 | $this->dom->addChild( |
| 106 | 106 | $ide, |
| 107 | 107 | "fimValid", |
| 108 | - ! empty($this->std->fimvalid) ? $this->std->fimvalid : null, |
|
| 108 | + !empty($this->std->fimvalid) ? $this->std->fimvalid : null, |
|
| 109 | 109 | false |
| 110 | 110 | ); |
| 111 | 111 | |
@@ -171,7 +171,7 @@ discard block |
||
| 171 | 171 | $this->dom->addChild( |
| 172 | 172 | $nova, |
| 173 | 173 | "fimValid", |
| 174 | - ! empty($this->std->novavalidade->fimvalid) |
|
| 174 | + !empty($this->std->novavalidade->fimvalid) |
|
| 175 | 175 | ? $this->std->novavalidade->fimvalid |
| 176 | 176 | : null, |
| 177 | 177 | false |
@@ -4,7 +4,6 @@ |
||
| 4 | 4 | |
| 5 | 5 | /** |
| 6 | 6 | * Class eSocial EvtTabEquipamento Event S-1065 constructor |
| 7 | - |
|
| 8 | 7 | * Read for 2.5.0 layout |
| 9 | 8 | * |
| 10 | 9 | * @category library |
@@ -76,7 +76,7 @@ |
||
| 76 | 76 | $this->dom->addChild( |
| 77 | 77 | $ideEvento, |
| 78 | 78 | "nrRecibo", |
| 79 | - ! empty($this->std->nrrecibo) ? $this->std->nrrecibo : null, |
|
| 79 | + !empty($this->std->nrrecibo) ? $this->std->nrrecibo : null, |
|
| 80 | 80 | false |
| 81 | 81 | ); |
| 82 | 82 | $this->dom->addChild( |
@@ -86,7 +86,7 @@ discard block |
||
| 86 | 86 | * @var array |
| 87 | 87 | */ |
| 88 | 88 | protected $grupos = [ |
| 89 | - 1 => [ //EVENTOS INICIAIS grupo [1] |
|
| 89 | + 1 => [//EVENTOS INICIAIS grupo [1] |
|
| 90 | 90 | 'S-1000', |
| 91 | 91 | 'S-1005', |
| 92 | 92 | 'S-1010', |
@@ -99,7 +99,7 @@ discard block |
||
| 99 | 99 | 'S-1070', |
| 100 | 100 | 'S-1080', |
| 101 | 101 | ], |
| 102 | - 2 => [ //EVENTOS NÃO PERIÓDICOS grupo [2] |
|
| 102 | + 2 => [//EVENTOS NÃO PERIÓDICOS grupo [2] |
|
| 103 | 103 | 'S-2190', |
| 104 | 104 | 'S-2200', |
| 105 | 105 | 'S-2205', |
@@ -127,7 +127,7 @@ discard block |
||
| 127 | 127 | 'S-5012', |
| 128 | 128 | 'S-5013', |
| 129 | 129 | ], |
| 130 | - 3 => [ //EVENTOS PERIÓDICOS grupo [3] |
|
| 130 | + 3 => [//EVENTOS PERIÓDICOS grupo [3] |
|
| 131 | 131 | 'S-1200', |
| 132 | 132 | 'S-1202', |
| 133 | 133 | 'S-1207', |
@@ -169,7 +169,7 @@ discard block |
||
| 169 | 169 | $this->certificate = $certificate; |
| 170 | 170 | $this->path = realpath(__DIR__ . '/../../') . '/'; |
| 171 | 171 | $this->serviceXsd = XsdSeeker::seek( |
| 172 | - $this->path."schemes/comunicacao/$this->serviceStr/" |
|
| 172 | + $this->path . "schemes/comunicacao/$this->serviceStr/" |
|
| 173 | 173 | ); |
| 174 | 174 | } |
| 175 | 175 | |