<?php
namespace App\Galileo\StructureParser\Structures\Ticketing; class Remarks extends \App\Galileo\StructureParser\Structures\Base\Remarks { protected function _getData() { list($parsedStructure, , ) = $this->getTransactionDetails(); $item = new \App\Galileo\StructureParser\Types\Remarks(); if ($parsedStructure['A14']) { foreach ($parsedStructure['A14'] as $A14) { $comp = new \App\Galileo\StructureParser\Types\RemarkComponent(); $comp->type = 'public'; $comp->content = $A14['A14']['A14DTA']; $item->append($comp); } } if ($parsedStructure['A15']) { foreach ($parsedStructure['A15'] as $A15) { if ($A15['A15']['A15SEG']==0) { $comp = new \App\Galileo\StructureParser\Types\RemarkComponent(); $comp->type = 'public'; $comp->content = $A15['A15']['A15DTA']; $item->append($comp); } } if ($parsedStructure['A04']) { foreach ($parsedStructure['A04'] as $a04) { if ($A15['A15']['A15SEG']==$a04['A04']['A04ITN']) { $comp = new \App\Galileo\StructureParser\Types\RemarkComponent(); $comp->type = 'associated'; $comp->content = $A15['A15']['A15DTA']; $item->append($comp); } } } } return $item; } } 