<?php
namespace App\Bsp\HotUA\Lines\Transaction;

/**
 * Line parser
 * @author Lucian Sirbu
 */
class BKI63 extends \App\Bsp\HotUA\HOTBase
{
	protected $children = [
		['key'=>'SMSG',                 'type'=>'Constant', 'val'=>'BKI',       'len'=>3,      'label'=>'Standard Message Identifier'],              // L/M/Standard Message Identifier
		['key'=>'SQNR',                 'type'=>'Integer',                      'len'=>8,      'label'=>'Sequence Number'],                          // L/M/Sequence Number
		['key'=>'STNQ',                 'type'=>'Constant', 'val'=>'63',        'len'=>2,      'label'=>'Standard Numeric Qualifier'],               // L/M/Standard Numeric Qualifier
		['key'=>'DAIS',                 'type'=>'Date',     'fmt'=>'YYMMDD',    'len'=>6,      'label'=>'Date of Issue', 'store'=>'DAIS',],                            // L/M/Date of Issue
		['key'=>'TRNN',                 'type'=>'Integer',                      'len'=>6,      'label'=>'Transaction Number'],                       // L/M/Transaction Number
		['key'=>'TDNR_airline',         'type'=>'StringRaw',                    'len'=>3,      'label'=>'Ticket/Document Number(airline number)'],   // S/M/Ticket/Document Number
		['key'=>'TDNR_ticketNumber',    'type'=>'StringRaw',                    'len'=>10,     'label'=>'Ticket/Document Number'],
		['key'=>'TDNR_extra',           'type'=>'StringRaw',                    'len'=>1,      'label'=>'Ticket/Document Number(extra digits)'],
		['key'=>'CDGT',                 'type'=>'Digits',                       'len'=>1,      'label'=>'Check-Digit'],                              // L/M/Check-Digit
		['key'=>'SEGI',                 'type'=>'Digits',                       'len'=>1,      'label'=>'Segment Identifier'],                       // L/M/Segment Identifier
		['key'=>'STPO',                 'type'=>'Letters',                      'len'=>1,      'label'=>'Stopover Code'],                            // L/M/Stopover Code
		['key'=>'NBDA',                 'type'=>'Date',     'fmt'=>'DDMMM',     'len'=>5,      'label'=>'Not Valid Before Date', 'allowSpaces'=>true, 'onlyFuture'=>true, 'ref'=>'DAIS',],                    // X/C/Not Valid Before Date
		['key'=>'NADA',                 'type'=>'Date',     'fmt'=>'DDMMM',     'len'=>5,      'label'=>'Not Valid After Date',  'allowSpaces'=>true, 'onlyFuture'=>true, 'ref'=>'DAIS',],                     // X/C/Not Valid After Date
		['key'=>'ORAC',                 'type'=>'StringTrim',                   'len'=>5,      'label'=>'Origin Airport/ City Code'],                // L/M/Origin Airport/ City Code
		['key'=>'DSTC',                 'type'=>'StringTrim',                   'len'=>5,      'label'=>'Destination Airport/ City Code'],           // L/M/Destination Airport/ City Code
		['key'=>'CARR',                 'type'=>'StringTrim',                   'len'=>3,      'label'=>'Carrier'],                                  // L/C/Carrier
		['key'=>'CABI',                 'type'=>'StringRaw',                    'len'=>1,      'label'=>'Sold passenger cabin'],
		['key'=>'FTNR',                 'type'=>'StringRaw',                    'len'=>5,      'label'=>'Flight Number'],                            // L/C/Flight Number
		['key'=>'RBKD',                 'type'=>'StringRaw',                    'len'=>2,      'label'=>'Reservation Booking Designator'],           // L/M/Reservation Booking Designator
		['key'=>'FTDA',                 'type'=>'Date',     'fmt'=>'DDMMM',     'len'=>5,      'label'=>'Flight Date',           'allowSpaces'=>true, 'onlyFuture'=>true, 'ref'=>'DAIS',],                              // L/C/Flight Date
		['key'=>'FTDT',                 'type'=>'StringRaw',                    'len'=>5,      'label'=>'Flight Departure Time'],                    // X/C/Flight Departure Time
		['key'=>'FBST',                 'type'=>'Letters',                      'len'=>2,      'label'=>'Flight Booking Status'],                    // X/C/Flight Booking Status
		['key'=>'FBAL',                 'type'=>'StringRaw',                    'len'=>3,      'label'=>'Free Baggage Allowance'],                   // X/C/Free Baggage Allowance
		['key'=>'FBTD',                 'type'=>'StringTrim',                   'len'=>15,     'label'=>'Fare Basis/Ticket Designator'],             // L/M/Fare Basis/Ticket Designator
		['key'=>'FFRF',                 'type'=>'StringTrim',                   'len'=>20,     'label'=>'Frequent Flyer Reference'],                 // X/C/Frequent Flyer Reference
		['key'=>'FCPT',                 'type'=>'StringRaw',                    'len'=>3,      'label'=>'Frequent Component priced passenger type code'],
		['key'=>'RESD',                 'type'=>'StringTrim',                   'len'=>10,     'label'=>'Reserved Space'],                           //  /M/Reserved Space
	];
}
