| 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/b2c.hellogtx.com/application/layouts/template3/ |
Upload File : |
<?php
header("Access-Control-Allow-Origin: *");
$object = Zend_Controller_Front::getInstance();
$options = $object->getParam('bootstrap')->getOption('bootstrap');
$baseUrl = $options['siteUrl'];
$siteName = $options['siteName'];
$stylecss = $options['stylecss'];
$IsTBOFlightAPI = $options['IsTBOFlightAPI'];
$tollfreenumber = $options['tollfreenumber'];
$whatsappnumber = $options['whatsappnumber'];
$modulename = $object->getRequest()->getModuleName();
//echo $modulename;
// $staticDataDomestic1 = $this->staticDataDomestic;
// echo"<pre>"; print_r($staticDataDomestic1);die();
$controller = $object->getRequest()->getControllerName();
//echo $controller; die();
$action = $object->getRequest()->getActionName();
$currentPaymentGateway = Catabatic_Helper::getCurrentPaymentGateway();
//echo $action; die();
$actionArray = array(
'modulename' => $modulename,
'controller' => $controller,
'action' => $action,
'PaymentGateway' => $currentPaymentGateway,
);
define('CONST_PACKAGE_TRAVELER_MAX_ROOM', $options['CONST_PACKAGE_TRAVELER_MAX_ROOM']);
define('CONST_PACKAGE_TRAVELER_MAX_ADULT_IN_ROOM', $options['CONST_PACKAGE_TRAVELER_MAX_ADULT_IN_ROOM']);
define('CONST_PACKAGE_TRAVELER_MAX_CHILD_IN_ROOM', $options['CONST_PACKAGE_TRAVELER_MAX_CHILD_IN_ROOM']);
define('CONST_PACKAGE_TRAVELER_MAX_INFANT_IN_ROOM', $options['CONST_PACKAGE_TRAVELER_MAX_INFANT_IN_ROOM']);
$mydevice = Zend_Controller_Action_HelperBroker::getStaticHelper('General')->getDevice();
$getMypopCookie = Zend_Controller_Action_HelperBroker::getStaticHelper('General')->getMypopCookie('MyCookies'); // get the popup sessions
$contactDetail = Zend_Controller_Action_HelperBroker::getStaticHelper('Custom')->getContactDetailForFooter();
$tollfreenumber = ($contactDetail['phone']) ? $contactDetail['phone'] : $tollfreenumber;
$whatsappnumber = ($contactDetail['whatsapp_no']) ? $contactDetail['whatsapp_no'] : $whatsappnumber;
$countrycode = (isset($getMypopCookie['countrycode']) && $getMypopCookie['countrycode'] != '') ? $getMypopCookie['countrycode'] : '+91';
$getCountryFlag = Zend_Controller_Action_HelperBroker::getStaticHelper('General')->getCountryCodeData($countrycode);
$session = new Zend_Session_Namespace('User');
$sessionFlightSearchParams = new Zend_Session_Namespace('sessionFlightSearchParams');
$route = $sessionFlightSearchParams->params['route'];
//$interNationalSearch=$sessionFlightSearchParams->params['interNationalSearch'];
//echo"<pre>";print_r($sessionFlightSearchParams->params);die();
$cssversion = 4.0;
$getPageDetail = $this->getPageDetail;
//echo"<pre>"; print_r($getPageDetail);die();
if (($modulename == 'agentlogin') && ($controller == 'index') && ($action == 'index')) {
?>
<!DOCTYPE html>
<html lang="en">
<head>
<title><?php echo $options['siteName']; ?> Travel Agent Login</title>
<base href="<?php echo Catabatic_Helper::getSiteUrl(); ?>" />
<meta charset="UTF-8">
<!-- <meta name="viewport" content="width=device-width, initial-scale=1">-->
<meta name="viewport" content="user-scalable=no, initial-scale=1, maximum-scale=1, minimum-scale=1, width=device-width, height=device-height, target-densitydpi=device-dpi" />
<!-- <link rel="icon" type="image/png" href="<?php //echo $baseUrl;
?>public/vendor/images/icons/favicon.ico"/>-->
<link rel="shortcut icon" href="<?php echo $baseUrl; ?>public/upload/<?php echo $stylecss ?>/images/favicon.ico">
<link rel="stylesheet" type="text/css" href="<?php echo $baseUrl; ?>public/vendor/bootstrap/css/bootstrap.min.css">
<link rel="stylesheet" type="text/css" href="<?php echo $baseUrl; ?>public/vendor/fonts/font-awesome-4.7.0/css/font-awesome.min.css">
<link rel="stylesheet" type="text/css" href="<?php echo $baseUrl; ?>public/vendor/fonts/Linearicons-Free-v1.0.0/icon-font.min.css">
<link rel="stylesheet" type="text/css" href="<?php echo $baseUrl; ?>public/vendor/animate/animate.css">
<link rel="stylesheet" type="text/css" href="<?php echo $baseUrl; ?>public/vendor/css-hamburgers/hamburgers.min.css">
<link rel="stylesheet" type="text/css" href="<?php echo $baseUrl; ?>public/vendor/animsition/css/animsition.min.css">
<link rel="stylesheet" type="text/css" href="<?php echo $baseUrl; ?>public/vendor/select2/select2.min.css">
<link rel="stylesheet" type="text/css" href="<?php echo $baseUrl; ?>public/vendor/daterangepicker/daterangepicker.css">
<link rel="stylesheet" type="text/css" href="<?php echo $baseUrl; ?>public/vendor/css/util.css">
<link rel="stylesheet" type="text/css" href="<?php echo $baseUrl; ?>public/vendor/css/main.css">
<script>
var SITEURL = '<?php echo $baseUrl ?>';
var stylecss = '<?php echo $stylecss ?>';
var appmode = '<?php echo $options['appmode'] ?>';
var UserLogin = '<?php (isset($session->session) && !empty($session->session)) ? true : false ?>';
var actionArray = '<?php echo json_encode($actionArray) ?>';
var dvc = '<?php echo ($mydevice == "mobile") ? "m" : "d" ?>';
</script>
</head>
<style>
html,
body {
overscroll-behavior-y: contain;
}
button.search-btn.flightsubmit_searchflight {
border: none;
font-size: 13px;
background: #d41a21;
float: right;
width: auto;
min-width: 156px;
padding: 8px 20px;
color: #fff;
border-radius: 5px;
font-weight: 700;
text-decoration: none;
text-align: center;
}
.col-lg-2.col-md-2.col-sm-2.col-12.nospace_left_0 {
padding-left: 0;
}
.exchange_transfer {
z-index: 999;
position: absolute;
width: 24px;
height: 24px;
border-radius: 100px;
left: -15px;
line-height: 22px;
top: 3px;
text-align: center;
}
.internation-flight-search-Banner .srch_form .form-control {
margin-bottom: 5px;
height: 45px;
}
</style>
<body>
<?php
echo $this->layout()->content;
?>
<form id="auth_login_B2B_submit" method="POST" action="<?php echo $baseUrl; ?>agentlogin/index/agentlogin">
<div class="auth_login_submit_B2B">
<input type="hidden" name="EmailId" id="EmailIdB2B">
<input type="hidden" name="UserSysId" id="UserSysIdB2B">
<input type="hidden" name="CustomerSysId" id="CustomerSysIdB2B">
<input type="hidden" name="AgencySysId" id="AgencySysId_B2B">
<input type="hidden" name="MasterAgencySysId" id="MasterAgencySysIdB2B">
<input type="hidden" name="FirstName" id="FirstNameB2B">
<input type="hidden" name="LastName" id="LastNameB2B">
<input type="hidden" name="Password_cu" id="Password_cuB2B">
<input type="hidden" name="AgencyName" id="AgencyNameB2B">
<input type="hidden" name="AgencyCode" id="AgencyCodeB2B">
<input type="hidden" name="ContactNo1" id="Contact_noB2B">
</div>
</form>
<!-- <script type="text/javascript" src="<? //php echo $baseUrl;
?>public/vendor/jquery/jquery-3.2.1.min.js"></script> -->
<script type="text/javascript" src="<?php echo $baseUrl; ?>public/vendor/animsition/js/animsition.min.js"></script>
<script type="text/javascript" src="<?php echo $baseUrl; ?>public/vendor/bootstrap/js/popper.js"></script>
<script type="text/javascript" src="<?php echo $baseUrl; ?>public/vendor/bootstrap/js/bootstrap.min.js"></script>
<script type="text/javascript" src="<?php echo $baseUrl; ?>public/vendor/select2/select2.min.js"></script>
<script type="text/javascript" src="<?php echo $baseUrl; ?>public/vendor/daterangepicker/moment.min.js"></script>
<script type="text/javascript" src="<?php echo $baseUrl; ?>public/vendor/daterangepicker/daterangepicker.js"></script>
<script type="text/javascript" src="<?php echo $baseUrl; ?>public/vendor/countdowntime/countdowntime.js"></script>
<script type="text/javascript" src="<?php echo $baseUrl; ?>public/vendor/js/main.js"></script>
<script type="text/javascript" src="<?php echo $baseUrl; ?>public/js/login.js"></script>
<script type="text/javascript" src="<?php echo $baseUrl; ?>public/js/createinputfilter.js"></script>
<script type="text/javascript" src="public/countrycode/script.js?v=<?= $cssversion ?>"></script>
</body>
</html>
<?php } else { ?>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<!-- <meta name="viewport" content="width=device-width, initial-scale=1">-->
<meta name="viewport" content="user-scalable=no, initial-scale=1, maximum-scale=1, minimum-scale=1, width=device-width, height=device-height, target-densitydpi=device-dpi" />
<link rel="shortcut icon" href="<?php echo $baseUrl; ?>public/upload/<?php echo $stylecss ?>/images/favicon.ico">
<?php
if (($modulename == 'detail') && ($controller == 'index') && ($action == 'index')) {
$detailLayout = $this->detailLayout;
?>
<title><?php echo $detailLayout['PackageTitle']; ?></title>
<meta name="description" content="<?php echo $detailLayout['Description']; ?>" />
<meta name="keywords" content="<?php echo $detailLayout['Keyword']; ?>" />
<?php
} else if (($modulename == 'tours') && ($controller == 'package') && ($action == 'index')) {
$detailLayout = $this->detailLayout;
// echo"<pre>"; print_r($detailLayout);die();
$PackageTitle = (isset($detailLayout['PackageTitle']) && $detailLayout['PackageTitle'] != '') ? $detailLayout['PackageTitle'] : '';
$finPackageTitle = (isset($detailLayout['Metatag']) && $detailLayout['Metatag'] != '') ? $detailLayout['Metatag'] : $PackageTitle;
?>
<title><?php echo $finPackageTitle; ?></title>
<meta name="description" content="<?php echo $detailLayout['Description']; ?>" />
<meta name="keywords" content="<?php echo $detailLayout['Keyword']; ?>" />
<?php
} else if (($modulename == 'destination') && ($controller == 'index') && ($action == 'domestic-destination')) {
//$detailLayout = $this->detailLayout;
$staticDataDomestic1 = $this->staticDataDomestic;
// echo"<pre>"; print_r($staticDataDomestic1[0]['page_title']);die();
$DestinationTitle = (isset($staticDataDomestic1[0]['page_title']) && $detailLayout[0]['page_title'] != '') ? $detailLayout[0]['page_title'] : '';
$finPackageTitle = (isset($staticDataDomestic1[0]['meta_title']) && $staticDataDomestic1[0]['meta_title'] != '') ? $staticDataDomestic1[0]['meta_title'] : $DestinationTitle;
?>
<title><?php echo $finPackageTitle; ?></title>
<meta name="description" content="<?php echo $staticDataDomestic1[0]['meta_description']; ?>" />
<meta name="keywords" content="<?php echo $staticDataDomestic1[0]['meta_keywords']; ?>" />
<?php
} else if (($modulename == 'destination') && ($controller == 'index') && ($action == 'international-destination')) {
$staticInternational = $this->staticDataInternational;
// echo"<pre>"; print_r($staticDataInternational1[0]['page_title']);die();
$PackageTitleInternational = (isset($staticInternational[0]['page_title']) && $staticInternational[0]['page_title'] != '') ? $staticInternational[0]['page_title'] : $siteName;;
$finPackageTitleInternational = (isset($staticInternational[0]['meta_title']) && $staticInternational[0]['meta_title'] != '') ? $staticInternational[0]['meta_title'] : $PackageTitleInternational;
?>
<title><?php echo $finPackageTitleInternational; ?></title>
<meta name="description" content="<?php echo $staticInternational[0]['meta_description'] ?>" />
<meta name="keywords" content="<?php echo $staticInternational[0]['meta_keywords']; ?>" />
<?php
} else if (($modulename == 'travelogue') && ($action == 'index' || $action == 'detail')) {
$resultsetSeoForBlog = $this->resultsetSeoForBlog;
$PackageTitle = (isset($resultsetSeoForBlog['TravTitle']) && $resultsetSeoForBlog['TravTitle'] != '') ? $resultsetSeoForBlog['TravTitle'] : $siteName;
$finPackageTitle = (isset($resultsetSeoForBlog['metatag']) && $resultsetSeoForBlog['metatag'] != '') ? $resultsetSeoForBlog['metatag'] : $PackageTitle;
?>
<title><?php echo $finPackageTitle ?></title>
<meta name="description" content="<?php echo ($resultsetSeoForBlog['Description']); ?>" />
<meta name="keywords" content="<?php echo $resultsetSeoForBlog['Keyword']; ?>" />
<?php
} else if (($modulename == 'cms') && ($controller == 'index') && ($action == 'index')) {
$resultsetSeoForCmsPages = $this->resultsetSeoForCmsPages;
?>
<title><?php echo $resultsetSeoForCmsPages['Title']; ?></title>
<meta name="description" content="<?php echo $resultsetSeoForCmsPages['Description']; ?>" />
<meta name="keywords" content="<?php echo $resultsetSeoForCmsPages['Keyword']; ?>" />
<?php } else if (($modulename == 'default') && ($controller == 'flight') && ($action == 'index')) {
$detailLayout = $this->detailLayout;
//echo"<pre>"; print_r($detailLayout);
?>
<title><?php echo $detailLayout['metaTitle']; ?></title>
<meta name="description" content="<?php echo $detailLayout['Description']; ?>" />
<meta name="keywords" content="<?php echo $detailLayout['Keyword']; ?>" />
<?php } else {
?>
<title>Book Online Holiday Tours | Honeymoon Packages | <?php echo $options['siteName']; ?> </title>
<meta name="description" content="<?php echo $options['siteName']; ?> is a leading travel company in Delhi, India. Get the best holiday tour packages to enjoying fantastic holiday destinations of your choice with Us." />
<meta name="keywords" Content="Online Holiday Tour, Travel Agency in India, Travel Company in Delhi, Book Tour Packages, Adventure Tours from India, Trekking Tour Packages, India Tours, Honeymoon Packages, Holiday Packages, Cheap Tour Packages, Tours and Travel in Delhi, Delhi Tour Company, Travel Agency Delhi, Destination Management Company, DMC India, International Tours from India, International Tours, Holiday Packages from India." />
<?php } ?>
<meta name="author" content="<?php echo $siteName; ?> ">
<meta name="robots" content="index, follow" />
<meta name="language" content="English">
<meta name="p:domain_verify" content="ad7f915dea4182cf9f24faa361ed56d5" />
<link rel="alternate" href="<?php echo $options['websiteUrl'] . $_SERVER[REQUEST_URI]; ?>" hreflang="en-us" />
<link rel="canonical" href="<?php echo $options['websiteUrl'] . $_SERVER[REQUEST_URI]; ?>" />
<?php if (($modulename == 'default') && ($controller == 'index') && ($action == 'index')) { ?>
<meta name="image" content="<?php echo $options['websiteUrl'] . $_SERVER[REQUEST_URI]; ?>public/images/ftr-logo.png">
<meta property="og:type" content="website" />
<meta name="og_site_name" property="og:site_name" content="<?php echo $options['websiteUrl'] . $_SERVER[REQUEST_URI]; ?>" />
<meta name="og_title" property="og:title" content="International Holiday and Honeymoon Tour Packages | <?php echo $options['siteName']; ?> ">
<meta name="Description" property="og:description" content="<?php echo $siteName; ?> is a leading Tours and Travels Company in Delhi, India. Get the best Tour Packages to explore fantastic Holiday Destinations of your choice with Us.">
<meta name="og_url" property="og:url" content="<?php echo $options['websiteUrl'] . $_SERVER[REQUEST_URI]; ?>" />
<!-- Schema.org for Google -->
<meta itemprop="name" content="<?php echo $siteName; ?>">
<meta itemprop="description" content="<?php echo $siteName; ?> is a leading Tours and Travels Company in Delhi, India. Get the best Tour Packages to explore fantastic Holiday Destinations of your choice with Us.">
<meta itemprop="image" content="<?php echo $options['websiteUrl'] . $_SERVER[REQUEST_URI]; ?>public/images/ftr-logo.png">
<!-- Twitter -->
<meta name="twitter:card" content="summary">
<meta name="twitter:title" content="<?php echo $siteName; ?>">
<meta name="twitter:description" content="<?php echo $siteName; ?> is a leading Tours and Travels Company in Delhi, India. Get the best Tour Packages to explore fantastic Holiday Destinations of your choice with Us.">
<?php } ?>
<base href="<?php echo Catabatic_Helper::getSiteUrl(); ?>" />
<!-- Font Styles -->
<!--<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.css">-->
<!--Stylesheets -->
<!-- <link rel="stylesheet" href="<?php /*echo $baseUrl; */ ?>public/flight/css/bootstrap.min.css" />
<link rel="stylesheet" href="<?php /*echo $baseUrl; */ ?>public/flight/css/jquery-ui.css" />-->
<!-- Owl Stylesheets -->
<!-- <link rel="stylesheet" href="<?php /*echo $baseUrl; */ ?>public/flight/owlcarousel/assets/owl.carousel.min.css">
<link rel="stylesheet" href="<?php /*echo $baseUrl; */ ?>public/flight/owlcarousel/assets/owl.theme.default.min.css">
<link rel="stylesheet" href="public/countrycode/style.css">-->
<!-- style css -->
<!--<link rel="stylesheet" href="<?php /*echo $baseUrl; */ ?>public/flight/css/style.css">
<link rel="stylesheet" href="<?php /*echo $baseUrl; */ ?>public/flight/css/responsive.css">-->
<link rel="preconnect" href="https://fonts.gstatic.com">
<link href="https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap" rel="stylesheet">
<link rel="stylesheet" href="public/countrycode/style.css">
<link rel="stylesheet" href="<?php echo $baseUrl; ?>public/upload/<?php echo $stylecss ?>/css/bootstrap.min.css">
<?php if (($modulename == 'default') && ($controller == 'flight') && ($action == 'travellers')) { ?>
<!-- <link rel="stylesheet" href="<?php echo $baseUrl; ?>public/flight/css/style.css"> -->
<?php } ?>
<link rel="stylesheet" type="text/css" href="<?php echo $baseUrl ?>public/upload/<?php echo $stylecss ?>/css/hotel_style.css?v=<?= $cssversion ?>">
<link rel="stylesheet" href="<?php echo $baseUrl; ?>public/upload/<?php echo $stylecss ?>/css/font-awesome.min.css">
<link href="<?php echo $baseUrl; ?>public/flight/tipped/tipped.css" rel="stylesheet" />
<?php if (($modulename == 'default') && ($controller == 'flight') && ($action == 'add-onn-service')) { ?>
<link href="<?php echo $baseUrl; ?>public/flight/css/seatmap.css?v=<?= $cssversion ?>" rel="stylesheet" />
<?php } ?>
<link rel="stylesheet" href="<?php echo $baseUrl; ?>public/upload/<?php echo $stylecss ?>/css/style.css?v=<?= $cssversion ?>">
<!-- Modernizr JS -->
<!-- <script src="<?php /*echo $baseUrl; */ ?>public/js/modernizr-2.6.2.min.js"></script>-->
<script>
var SITEURL = '<?php echo $baseUrl ?>';
var stylecss = '<?php echo $stylecss ?>';
var appmode = '<?php echo $options['appmode'] ?>';
var UserLogin = '<?php (isset($session->session) && !empty($session->session)) ? true : false ?>';
var actionArray = '<?php echo json_encode($actionArray) ?>';
var dvc = '<?php echo ($mydevice == "mobile") ? "m" : "d" ?>';
var HOTEL_CATEGORY = {
"Budget": [1],
"Standard": [2],
"Deluxe": [3],
"Luxury": [4],
"Premium": [5]
};
</script>
<?php
echo $seoContent = (isset($detailLayout['seoHcontent']) && $detailLayout['seoHcontent'] != '') ? $detailLayout['seoHcontent'] : '';
?>
<style>
/*traveller popup cs code 11-2-2022*/
#myModal_Travellers .modal-dialog {
max-width: 800px;
margin: 4rem auto 0;
}
a.sendenquiry-btn {
height: 50px;
border: solid 3px #2e418a;
box-shadow: 0 3px 3px #332;
background: #2e418a;
width: 150px;
line-height: 38px;
font-weight: 600;
color: white;
transform: rotate(90deg);
text-align: center;
font-size: 20px;
position: fixed !important;
right: -47px;
top: 30% !important;
z-index: 999;
cursor: pointer;
border-radius: 0px;
}
.whatsapp-btn {
height: 50px;
border: solid 3px #279620;
box-shadow: 0 3px 3px #332;
background: #279620;
width: 150px;
line-height: 38px;
font-weight: 600;
color: #fff;
transform: rotate(90deg);
text-align: center;
font-size: 16px;
position: fixed;
right: -47px;
top: 55% !important;
z-index: 999;
cursor: pointer;
border-radius: 0;
}
.flight-clsn-trvl-dtl-b2 {
width: 100%;
margin: 0 auto;
/*padding: 10px 16px;*/
padding: 10px 16px 10px 0px;
}
.flight-clsinfnt-m {
width: 100%;
margin: 0 auto;
/*padding: 10px 16px;*/
padding: 10px 16px 10px 0px;
}
.flight-clsadult1 {
width: 100%;
margin: 0;
}
.flight-clsinfnt {
width: 100%;
margin: 0;
}
.flight-clsadult1 ul {
margin: 0;
padding: 5px 0 10px;
width: 100%;
display: flex;
overflow-x: scroll;
}
.flight-clsinfnt ul {
margin: 0;
padding: 5px 0 10px;
width: 100%;
display: flex;
overflow-x: scroll;
}
.flight-clsadult1 li {
border: 1px solid #ccc;
color: var(--black_color);
cursor: pointer;
display: inline-block;
float: left;
font-size: 15px;
margin: 0 4px 0 0;
text-align: center;
font-weight: 700;
width: 50px;
height: 50px;
line-height: 48px;
}
.flight-clsadult1 li:hover {
background-color: var(--secondcolor);
border-color: var(--secondcolor);
}
.flight-clsinfnt li {
border: 1px solid #ccc;
color: var(--black_color);
cursor: pointer;
display: inline-block;
float: left;
font-size: 15px;
margin: 0 4px 0 0;
text-align: center;
width: 33px;
font-weight: 700;
width: 50px;
height: 50px;
line-height: 49px;
}
.flight-clsinfnt li:hover {
background-color: var(--secondcolor);
border-color: var(--secondcolor);
}
#flight-clsadultcnt input[type=radio],
#flight-clsChildCnt input[type=radio],
#flight-clsInfantCnt input[type=radio] {
display: none;
}
#flight-clsadultcnt label,
#flight-clsChildCnt label,
#flight-clsInfantCnt label {
width: 45px !important;
cursor: pointer;
}
#flight-clsadultcnt li.active,
#flight-clsChildCnt li.active,
#flight-clsInfantCnt li.active {
display: block !important;
color: #fff !important;
background-color: var(--maincolor) !important;
border: 1px solid var(--maincolorr) !important;
}
.internation-flight-search-Banner .standard_class {
height: auto;
overflow-y: auto;
}
.internation-flight-search-Banner .standard_class label {
display: inline-block;
padding: 10px 0;
border: 1px solid #d7d7d7;
-webkit-border-radius: 4px;
cursor: pointer;
width: 100%;
text-align: center !important;
margin: 12px 0;
float: left;
font-size: 14px !important;
}
.internation-flight-search-Banner .standard_class input[type="radio"]:checked+label {
background-color: #d11808;
border-color: var(--actionbtn);
color: var(--text-color-white) !important;
}
.internation-flight-search-Banner .standard_class>.radio {
display: block;
margin-top: 0px !important;
margin-bottom: 0px !important;
font-weight: 300 !important;
margin-right: 10px;
width: 143px;
float: left;
}
.close {
font-size: 1rem;
}
.modalheaderbg {
background: #fff;
}
button:focus {
outline: 0px dotted;
outline: 0px auto -webkit-focus-ring-color;
}
a.apply_traveller {
border: none;
font-size: 18px;
background: var(--secondcolor);
float: right;
width: 100px;
padding: 10px 25px 13px;
color: var(--text-color-white);
border-radius: 5px;
font-weight: normal;
text-decoration: none;
text-align: center;
height: 50px;
margin-right: 10px;
}
a.apply_traveller:hover {
background: var(--maincolor);
}
a.apply_traveller:focus {
background: var(--secondcolor);
}
/*traveller popup cs code 11-2-2022*/
.ui-autocomplete {
z-index: 99999999 !important;
}
.ui-front {
z-index: 9999;
}
.countdownDiv {
position: fixed;
bottom: 0;
left: 0;
width: 100%;
background-color: #004362;
color: #fff;
padding: 12px;
text-align: center;
line-height: 33px;
z-index: 9999;
font-size: 15px;
font-weight: bold;
}
/*.custom-nav {*/
/*position: relative !important;*/
/*background: #3584bd !important;*/
/*}*/
</style>
<?php if (($modulename == 'default') && ($controller == 'flight') && ($action != 'index')) { ?>
<style>
@media (max-width:992px) {
footer,
.footeruppercls {
display: none;
}
.copyright {
display: none;
}
}
</style>
<?php } ?>
</head>
<style>
html,
body {
overscroll-behavior-y: contain;
}
</style>
<body ng-app="Farohar">
<!-- <div class="loader" >
<div class="loadingio-spinner-ripple-zdgradklyya">
<div class="ldio-50dj1g083ax">
<div></div>
</div>
</div>
</div> -->
<div id="page" ng-controller="FlightListingController">
<?php if (($modulename == 'default') && ($controller == 'flight') && ($action == 'flight-search')) { ?>
<div ng-hide="loadingFlight == false">
<!-- <div> -->
<?php echo $this->partial('flight/loader.phtml'); ?>
</div>
<div class="domestround" style="display:none">
<?php } ?>
<?php
$data = [
'baseUrl' => $baseUrl, 'AgencySysId' => $options['gtxagencysysid'], 'modulename' => $modulename,
'CONST_PACKAGE_TRAVELER_MAX_ROOM' => CONST_PACKAGE_TRAVELER_MAX_ROOM,
'CONST_PACKAGE_TRAVELER_MAX_ADULT_IN_ROOM' => CONST_PACKAGE_TRAVELER_MAX_ADULT_IN_ROOM,
'CONST_PACKAGE_TRAVELER_MAX_CHILD_IN_ROOM' => CONST_PACKAGE_TRAVELER_MAX_CHILD_IN_ROOM,
'CONST_PACKAGE_TRAVELER_MAX_INFANT_IN_ROOM' => CONST_PACKAGE_TRAVELER_MAX_INFANT_IN_ROOM,
'POPUPCOOKIES' => $getMypopCookie,
'tollfreenumber' => $tollfreenumber
];
require_once(APPLICATION_PATH . '/sites/' . $stylecss . '/layouts/header.phtml');
//echo $this->render("header.phtml");
echo $this->partial('models/modal-enquiry.phtml', ['baseUrl' => $baseUrl, 'siteName' => $siteName, 'tollfreenumber' => $tollfreenumber, 'POPUPCOOKIESENQUIRY' => $getMypopCookie]);
echo $this->partial('models/modal-signin.phtml', ['baseUrl' => $baseUrl]);
if (($modulename == 'tours') && ($controller == 'package') && ($action == 'index')) {
echo $this->partial('models/modal-checkrate-enquiry.phtml', $data);
}
?>
<?php
echo $this->layout()->content;
require_once(APPLICATION_PATH . '/sites/' . $stylecss . '/layouts/footer.phtml');
//echo $this->render("footer.phtml");
?>
<?php if (($modulename == 'default') && ($controller == 'flight') && ($action == 'flight-search')) { ?>
</div>
<?php } ?>
</div>
<script type="text/javascript" src="<?php echo $baseUrl; ?>public/upload/<?php echo $stylecss ?>/js/jquery.min.js?v=<?= $cssversion ?>"></script>
<script type="text/javascript" src="<?php echo $baseUrl; ?>public/assets/js/custom.js?v=4.1"></script>
<script src="<?php echo $baseUrl; ?>public/flight/owlcarousel/owl.carousel.js"></script>
<script src="<?php echo $baseUrl; ?>public/flight/tipped/tipped.js"></script>
<script type="text/javascript" src="<?php echo $baseUrl; ?>public/js/custom_mangal.js"></script>
<script type="text/javascript" src="<?php echo $baseUrl; ?>public/js/login.js"></script>
<script type="text/javascript" src="<?php echo $baseUrl; ?>public/js/createinputfilter.js"></script>
<script type="text/javascript" src="<?php echo $baseUrl; ?>public/countrycode/script.js?v=<?= $cssversion ?>"></script>
<script>
$(document).on('click', '.sortingMult', function() {
var keyH = $(this).attr('keyh');
$('.sroneway' + keyH + ' ul li a').removeClass('active active_sort');
$(this).addClass("active active_sort");
$(this).children('i').toggleClass('fa-long-arrow-up fa-long-arrow-down');
});
$('.sorting').on('click', function(e) {
if ($(this).hasClass("active")) {
$('.sortright-flight ul li a').removeClass('active active_sort');
$(this).addClass("active_sort");
} else {
$('.sortright-flight ul li a').removeClass('active active_sort');
$(this).addClass("active");
}
$(this).children('i').toggleClass('fa-long-arrow-up fa-long-arrow-down');
});
$('.sortingroundfirst').on('click', function(e) {
if ($(this).hasClass("active")) {
$('.sortright-flight-round-first ul li a').removeClass('active active_sort');
$(this).addClass("active_sort");
} else {
$('.sortright-flight-round-first ul li a').removeClass('active active_sort');
$(this).addClass("active");
}
$(this).children('i').toggleClass('fa-long-arrow-up fa-long-arrow-down');
});
$('.sortinground').on('click', function(e) {
if ($(this).hasClass("active")) {
$('.sortright-flight-round ul li a').removeClass('active active_sort');
$(this).addClass("active_sort");
} else {
$('.sortright-flight-round ul li a').removeClass('active active_sort');
$(this).addClass("active");
}
$(this).children('i').toggleClass('fa-long-arrow-up fa-long-arrow-down');
});
$(document).mouseup(function(e) {
if ($(e.target).closest(".hotelrooombox_main").length ===
0) {
$(".hotelrooombox_main").hide();
}
});
</script>
<?php
if (($modulename == 'default') && ($controller == 'flight') && ($action == 'flight-search')) {
$scriptsAngular = $this->headScript(); // include the angular js here
$scriptsAngular->appendFile($baseUrl . "public/js/ng/angular.min.js?v=<?= $cssversion ?>")
->appendFile($baseUrl . "public/js/ng/angular-route.min.js");
if ($route == 2 && $interNationalSearch == '' && $mydevice == 'mobile') {
$scriptsAngular->appendFile($baseUrl . "public/js/ng/ngInfiniteScroll.js");
} else {
$scriptsAngular->appendFile($baseUrl . "public/js/ng/ng-infinite-scroll.min.js");
$scriptsAngular->appendFile($baseUrl . "public/js/ng/ng-infinite-scroll.js");
}
$scriptsAngular->appendFile($baseUrl . "public/js/ng/app.js")
->appendFile($baseUrl . "public/js/ng/ngfactory.js")
->appendFile($baseUrl . "public/js/ng/ngsortingorder.js")
->appendFile($baseUrl . "public/js/ng/flight_search_new.js?v=<?= $cssversion ?>");
echo $scriptsAngular;
}
?>
<!-- flight date calender change -->
<script>
$(document).on('click', '.DateNext', function() {
var Datedata = $(this).attr('datedata');
var formatdate = $(this).attr('formatdate');
$('input[name="departure_date"]').val(Datedata);
$('#from').val(formatdate);
$('.flightsearch').submit();
});
$(document).on('click', '.arrow23', function() {
var box = $(".box-inner23"),
x;
if ($(this).hasClass("arrow-right")) {
x = ((box.width() / 2)) + box.scrollLeft();
console.log(box.width());
console.log(box.scrollLeft());
box.animate({
scrollLeft: x,
})
} else {
x = ((box.width() / 2)) - box.scrollLeft();
console.log(box.width());
console.log(box.scrollLeft());
box.animate({
scrollLeft: -x,
})
}
});
$(document).on('click', '.arrow', function() {
// alert();
var box = $(".box-inner"),
x;
if ($(this).hasClass("arrow-right")) {
x = ((box.width() / 2)) + box.scrollLeft();
box.animate({
scrollLeft: x,
})
} else {
x = ((box.width() / 2)) - box.scrollLeft();
box.animate({
scrollLeft: -x,
})
}
});
$(document).on('click', '.arrow2', function() {
// alert();
var box = $(".box-inner2"),
x;
if ($(this).hasClass("arrow-right")) {
x = ((box.width() / 2)) + box.scrollLeft();
box.animate({
scrollLeft: x,
})
} else {
x = ((box.width() / 2)) - box.scrollLeft();
box.animate({
scrollLeft: -x,
})
}
});
</script>
<script>
$(window).scroll(function() {
if ($(window).scrollTop() + $(window).height() >= $(document).height() - 400) {
$('.loadMoreNew').trigger('click');
$('.loadMoreRound').trigger('click');
$('#windowheight').html($(window).height());
}
});
$('.flights_slider_mobile').on('scroll', function() {
if ($(window).scrollTop() + $(window).height() >= $(document).height() - 400) {
$('.loadMoreNew').trigger('click');
$('.loadMoreRound').trigger('click');
console.log('qqqq');
$('#windowheight').html($(window).height());
}
console.log('qqqq');
});
// $(window).on('scroll', function() {
// // var height = $(window).height(); // New height
// // if ($(window).scrollTop() + $(window).height() >= $(document).height()) {
// // $('.loadMoreNew').trigger('click');
// // $('.loadMoreRound').trigger('click');
// // }
// });
// $('.flights_slider_mobile').on('scroll', function() {
// $('.loadMoreNew').trigger('click');
// $('.loadMoreRound').trigger('click');
// // if ($(window).scrollTop() + $(window).height() >= $(document).height() - 300) {
// // $('.loadMoreNew').trigger('click');
// // }
// // let div = $(this).get(0);
// // var height = $(window).height(); // New height
// // if (div.scrollTop + div.clientHeight >= div.scrollHeight) {
// // $('.loadMoreNew').trigger('click');
// // $('.loadMoreRound').trigger('click');
// // }
// });
$('body').on('click', '.sectorDiv', function() {
var index = $(this).attr('index');
$('.ResultId').hide();
$('#ResultId_' + index).show();
});
$('body').on('click', '.ChangeView', function() {
$(this).text($(this).text() == 'List View' ? 'Combine View' : 'List View');
});
$('body').on('click', '.addmoreoption_fareclass', function() {
var index = $(this).attr('index');
$('.combineviewDiv_' + index).toggle('slow');
});
$('body').on('click', '.combinefareareaclose', function() {
var index = $(this).attr('index');
$('.combineviewDiv_' + index).hide('slow');
});
function countdown() {
var timer2 = localStorage.getItem('timer');
if (timer2 === null) timer2 = "14:00";
$('.countdown').html(timer2);
var interval = setInterval(function() {
var timer = timer2.split(':');
var minutes = parseInt(timer[0], 10);
var seconds = parseInt(timer[1], 10);
--seconds;
minutes = (seconds < 0) ? --minutes : minutes;
if (minutes < 0) {
clearInterval(interval);
localStorage.removeItem('timer');
alert('Your session has been expired. please try again.');
window.location.href = 'flight';
//$('button').show();
} else {
seconds = (seconds < 0) ? 59 : seconds;
seconds = (seconds < 10) ? '0' + seconds : seconds;
$('.countdown').html(minutes + ':' + seconds);
timer2 = minutes + ':' + seconds;
localStorage.setItem('timer', timer2);
}
}, 1000);
};
<?php
if (($modulename == 'default') && ($controller == 'flight') && ($action == 'review' || $action == 'add-onn-service')) {
?>
$(document).on('click', '.IsCancellationProtection', function() {
var IsCP = $(this).val();
updateCancellationProtection(IsCP);
});
countdown();
<?php
}
?>
</script>
<script>
jQuery(document).ready(function($) {
$('.loop').owlCarousel({
center: true,
items: 2,
dots: false,
loop: true,
margin: 30,
responsive: {
320: {
center: false,
items: 2
},
600: {
center: true,
items: 2
},
1000: {
items: 4,
nav: true,
center: true,
loop: true,
navText: ["<i class='fa fa-angle-left' aria-hidden='true'></i>", "<i class='fa fa-angle-right' aria-hidden='true'></i>"]
}
}
});
$('.loop_flight').owlCarousel({
center: false,
items: 2,
dots: false,
loop: false,
margin: 30,
responsive: {
320: {
center: false,
items: 2
},
600: {
center: false,
items: 2
},
1000: {
items: 4,
nav: true,
center: false,
loop: false,
navText: ["<i class='fa fa-arrow-left' aria-hidden='true'></i>", "<i class='fa fa-arrow-right' aria-hidden='true'></i>"]
}
}
});
$('.loop2').owlCarousel({
center: false,
items: 2,
dots: false,
loop: false,
margin: 20,
responsive: {
320: {
center: false,
items: 1,
margin: 10
},
450: {
center: false,
items: 2
},
1000: {
items: 3,
nav: false,
center: false,
loop: false,
navText: ["<i class='fa fa-angle-left' aria-hidden='true'></i>", "<i class='fa fa-angle-right' aria-hidden='true'></i>"]
}
}
});
$('.popularloop').owlCarousel({
center: false,
items: 3,
dots: false,
loop: true,
margin: 10,
responsive: {
320: {
center: false,
items: 2
},
400: {
center: false,
items: 3
},
600: {
center: false,
loop: true,
nav: false,
items: 4
},
1000: {
items: 3,
nav: true,
center: false,
loop: true,
navText: ["<i class='fa fa-angle-left' aria-hidden='true'></i>", "<i class='fa fa-angle-right' aria-hidden='true'></i>"]
}
}
});
$('.nonloop').owlCarousel({
center: true,
items: 2,
loop: false,
margin: 10,
responsive: {
600: {
items: 4
}
}
});
});
</script>
<script>
$(document).ready(function() {
$("#flight-clsadultcnt li").click(function() {
$("#flight-clsadultcnt li").removeClass("active");
if ($(this).find('#flight-clsadultcnt li').hasClass('active')) {
$(this).find('#flight-clsadultcnt li').removeClass('active');
$($(this).find('#flight-clsadultcnt li')).removeClass('active');
return false;
} else {
$(this).addClass("active");
}
});
$(" .round-fltResult-2, #flight-clsChildCnt li").click(function() {
$(" .round-fltResult-2, #flight-clsChildCnt li").removeClass("active");
if ($(this).find(' .round-fltResult-2, #flight-clsChildCnt li').hasClass('active')) {
$(this).find(' .round-fltResult-2, #flight-clsChildCnt li').removeClass('active');
$($(this).find(' .round-fltResult-2, #flight-clsChildCnt li')).removeClass('active');
return false;
} else {
$(this).addClass("active");
}
});
$(".fltResult, #flight-clsInfantCnt li").click(function() {
$(".fltResult, #flight-clsInfantCnt li").removeClass("active");
if ($(this).find('.fltResult, #flight-clsInfantCnt li').hasClass('active')) {
$(this).find('.fltResult, #flight-clsInfantCnt li').removeClass('active');
$($(this).find('.fltResult, #flight-clsInfantCnt li')).removeClass('active');
return false;
} else {
$(this).addClass("active");
}
});
$(".checkboxdba").on('click', function(e) {
$('.paddingright input:radio').first().trigger('click', true);
$('.paddingleft input:radio').first().trigger('click', true);
});
});
function airlinecheck() {
$('.paddingright input:radio').first().trigger('click', true);
$('.paddingleft input:radio').first().trigger('click', true);
}
$(document).ready(function() {
$('.travller_search____').on("click", function() {
$('.flightsubmit_searchflight').prop("disabled", false);
$(".roomBoxMain").slideToggle("slow");
});
$('#done_traveller').on("click", function() {
$(".roomBoxMain").slideUp("slow");
});
$('.flight_infotitle_dd').on("click", function() {
$(".flight_information_details_content").toggle("show_hiddenpart_hidden");
});
$('#travller_search').on("click", function() {
$("#myModal_Travellers").modal('show');
//$(".roomBoxMain").toggle("show_hiddenpart_hidden");
});
$(".flight-clsn-trvl-dtl-r").click(function() {
var TotalPax = 0;
$('.flight-clsn-trvl-dtl input[type=radio]').each(function() {
if (this.checked) {
TotalPax += parseInt($(this).val());
}
});
if (TotalPax >= 10) {
alert("More than 9 Passenger's can not travel.");
return false;
}
$('.flightsubmit_searchflight').prop("disabled", false);
$('.TotalTravellers').html(TotalPax);
$("#myModal_Travellers").modal('hide');
});
$('.ddSpinnerPlus').click(function() {
//var totalpass = $('.TotalTravellers').html();
var adult = $('.counter1').val();
var child = $('.counter2').val();
var totalpass = parseInt(adult) + parseInt(child);
if (totalpass < 9) {
if ($(this).prev().val() < 9) {
$(this).prev().val(+$(this).prev().val() + 1);
$('.counter1').val(+$(this).prev().val());
$('.counter1').attr('value', +$(this).prev().val());
}
SumTravellers();
} else {
alert('Total Passanger (Adult and Child) Can not be more than 9');
}
});
$('.ddSpinnerMinus').click(function() {
var infants = $('#infants').val();
var adult = $(this).next().val();
if (infants > 1) {
if (parseInt(infants) >= adult) {
$('#infants').val(infants - 1)
}
}
if ($('#adults').val() > 1) {
$(this).next().val(+$(this).next().val() - 1);
$('.counter1').val(+$(this).next().val());
$('.counter1').attr('value', +$(this).next().val());
$('.counter-int').attr('value', +$(this).next().val());
}
SumTravellers();
});
$('.chSpinnerPlus').click(function() {
var adult = $('.counter1').val();
var child = $('.counter2').val();
var totalpass = parseInt(adult) + parseInt(child);
if (totalpass < 9) {
if ($(this).prev().val() < 9) {
$(this).prev().val(+$(this).prev().val() + 1);
$('.counter2').val(+$(this).prev().val());
$('.counter2').attr('value', +$(this).prev().val());
}
SumTravellers();
} else {
alert('Total Passanger (Adult and Child) Can not be more than 9');
}
});
$('.chSpinnerMinus').click(function() {
//alert($(this).val());
if ($(this).next().val() > 0) {
if ($(this).next().val() > 0)
$(this).next().val(+$(this).next().val() - 1);
$('.counter2').val(+$(this).next().val());
$('.counter2').attr('value', +$(this).next().val());
}
SumTravellers();
});
$('.infSpinnerPlus').click(function() {
// var adult = $('.counter1').val();
var adults = $('#adults').val();
if (parseInt(adults) <= parseInt($(this).prev().val())) {
alert('Number of infant can not be greater than adult');
return false;
} else {
$(this).prev().val(+$(this).prev().val() + 1);
$('.counter3').val(+$(this).prev().val());
$('.counter3').attr('value', +$(this).prev().val());
SumTravellers();
}
});
$('.infSpinnerMinus').click(function() {
if ($(this).next().val() > 0) {
if ($(this).next().val() > 0)
$(this).next().val(+$(this).next().val() - 1);
$('.counter3').val(+$(this).next().val());
$('.counter3').attr('value', +$(this).next().val());
}
SumTravellers();
});
function SumTravellers() {
var a = 0;
$(".quantity").each(function() {
a += parseInt($(this).val());
});
$('.TotalTravellers').html(a);
return a;
}
function ValidateInfant() {
var a = 0;
$(".quantity").each(function() {
a += parseInt($(this).val());
});
$('.TotalTravellers').html(a);
return a;
}
$(".SelectClass") // select the radio by its id
.change(function() { // bind a function to the change event
if ($(this).is(":checked")) { // check if the radio is checked
var val = $(this).val(); // retrieve the value
var htmlval = $(this).attr('data'); // retrieve the html value
$('.TravellersClass').html(htmlval);
}
});
$("#from, #to").datepicker({
//defaultDate: "+1w",
changeMonth: false,
dateFormat: "d M yy",
numberOfMonths: 2,
minDate: 0,
buttonImage: true,
buttonImageOnly: true,
beforeShow: function() {
if (this.id == 'to') {
var dateMin = $('#from').datepicker("getDate");
var TodateMin = $('#to').datepicker("getDate");
if (TodateMin === null) {
TodateMin = dateMin;
}
var rMin = new Date(dateMin.getFullYear(), dateMin.getMonth(), dateMin.getDate() + 0); // Min Date = Selected + 1d
var rMax = new Date(dateMin.getFullYear(), dateMin.getMonth(), dateMin.getDate() + 180); // Max Date = Selected + 62d
var c_out_date = new Date(TodateMin.getFullYear(), TodateMin.getMonth(), TodateMin.getDate()); // Min Date = Selected + 1d
$('#to').datepicker("option", "minDate", rMin);
$('#to').datepicker("option", "maxDate", rMax);
$('#to').datepicker("setDate", c_out_date);
$('#RoundTrip').prop('checked', true);
}
},
onSelect: function(selectedDate, inst) {
var tripType = $('.tripType:checked').val(); // retrieve the value
//alert('navratan1');
$('.flightsubmit_searchflight').prop("disabled", false);
if (this.id == 'from') {
var dateMin = $('#from').datepicker("getDate");
var rMin = new Date(dateMin.getFullYear(), dateMin.getMonth(), dateMin.getDate() + 0); // Min Date = Selected + 1d
var rMax = new Date(dateMin.getFullYear(), dateMin.getMonth(), dateMin.getDate() + 180); // Max Date = Selected + 62d
var c_out_date = new Date(dateMin.getFullYear(), dateMin.getMonth(), dateMin.getDate() + 1); // Min Date = Selected + 1d
var theDate = new Date(Date.parse($(this).datepicker('getDate')));
var dateFormatted = $.datepicker.formatDate('DD', theDate);
var FromFormatted = $.datepicker.formatDate('dd/mm/yy', theDate);
$('.Departure').html(dateFormatted);
$('#departure_date').val(FromFormatted);
if (parseInt(tripType) === 2) {
$('#to').datepicker("option", "minDate", rMin);
$('#to').datepicker("option", "maxDate", rMax);
$('#to').datepicker("setDate", c_out_date);
$('.Return').html(dateFormatted);
$('#return_date').val($.datepicker.formatDate('dd/mm/yy', c_out_date));
}
// console.log(c_out_date);
///$('#to').focus();return false;
} else {
var dateMin = $('#to').datepicker("getDate");
var c_out_date = new Date(dateMin.getFullYear(), dateMin.getMonth(), dateMin.getDate() + 0);
var theDate = new Date(Date.parse(c_out_date));
var dateFormatted = $.datepicker.formatDate('DD', theDate);
var ToFormatted = $.datepicker.formatDate('dd/mm/yy', theDate);
$('.Return').html(dateFormatted);
$('#return_date').val(ToFormatted);
// console.log(ToFormatted);
}
}
});
$("#Mobilefrom, #Mobileto").datepicker({
//defaultDate: "+1w",
changeMonth: false,
dateFormat: "d M yy",
numberOfMonths: 1,
minDate: 0,
buttonImage: true,
buttonImageOnly: true,
beforeShow: function() {
if (this.id == 'Mobileto') {
var dateMin = $('#Mobilefrom').datepicker("getDate");
var TodateMin = $('#Mobileto').datepicker("getDate");
var rMin = new Date(dateMin.getFullYear(), dateMin.getMonth(), dateMin.getDate() + 0); // Min Date = Selected + 1d
var rMax = new Date(dateMin.getFullYear(), dateMin.getMonth(), dateMin.getDate() + 180); // Max Date = Selected + 62d
var c_out_date = new Date(TodateMin.getFullYear(), TodateMin.getMonth(), TodateMin.getDate()); // Min Date = Selected + 1d
$('#Mobileto').datepicker("option", "minDate", rMin);
$('#Mobileto').datepicker("option", "maxDate", rMax);
$('#Mobileto').datepicker("setDate", c_out_date);
}
},
onSelect: function(selectedDate, inst) {
var tripType = $('.tripType:checked').val(); // retrieve the value
if (this.id == 'Mobilefrom') {
var dateMin = $('#Mobilefrom').datepicker("getDate");
var rMin = new Date(dateMin.getFullYear(), dateMin.getMonth(), dateMin.getDate() + 0); // Min Date = Selected + 1d
var rMax = new Date(dateMin.getFullYear(), dateMin.getMonth(), dateMin.getDate() + 180); // Max Date = Selected + 62d
var c_out_date = new Date(dateMin.getFullYear(), dateMin.getMonth(), dateMin.getDate() + 0); // Min Date = Selected + 1d
var theDate = new Date(Date.parse($(this).datepicker('getDate')));
var dateFormatted = $.datepicker.formatDate('DD', theDate);
var FromFormatted = $.datepicker.formatDate('dd/mm/yy', theDate);
$('.Departure').html(dateFormatted);
$('#departure_date').val(FromFormatted);
if (parseInt(tripType) === 2) {
$('#Mobileto').datepicker("option", "minDate", rMin);
$('#Mobileto').datepicker("option", "maxDate", rMax);
$('#Mobileto').datepicker("setDate", c_out_date);
$('.Return').html(dateFormatted);
}
// console.log(c_out_date);
///$('#to').focus();return false;
} else {
var dateMin = $('#Mobileto').datepicker("getDate");
var c_out_date = new Date(dateMin.getFullYear(), dateMin.getMonth(), dateMin.getDate() + 0);
var theDate = new Date(Date.parse(c_out_date));
var dateFormatted = $.datepicker.formatDate('DD', theDate);
var ToFormatted = $.datepicker.formatDate('dd/mm/yy', theDate);
$('.Return').html(dateFormatted);
$('#return_date').val(ToFormatted);
// console.log(ToFormatted);
}
}
});
var counter = 0;
$(document).ready(function() {
var route = $(".tripType:checked").val();
// alert('Navratan');
if (route === '3') {
$('.disableres').hide();
$('.multitraveller').show();
$('.block').show();
$('.addSegment').show();
$('.addSDiv').show();
$('#oneRound :input').prop("disabled", true);
$('.disableres :input').prop("disabled", true);
var SectorCount = parseInt($('#SectorCount').val());
if (SectorCount === 0) {
SectorCount = 2;
}
for (i = 0; i < SectorCount; i++) {
$(".checkaction").trigger('click');
}
}
});
$(document).on('change', '#trip', function() {
var val = $(this).val();
if (val === '1') {
$("#OneWay").trigger('click');
$(".flight-search-flight4").removeClass("multialignrdhome", true);
} else if (val === '2') {
$("#RoundTrip").trigger('click');
$(".flight-search-flight4").removeClass("multialignrdhome", true);
} else if (val === '3') {
$(".multiCity____").trigger('click');
$(".flight-search-flight4").addClass("multialignrdhome", true);
}
});
$(document).on('click', '.tripType , #trip', function() {
});
$(document).on('click', '.tripType,#trip', function() {
var tripType = $(this).val();
var from = $('#from').val();
$('.flightsubmit_searchflight').prop("disabled", false);
if (tripType == 2) {
$('.disableres').show();
$('.addSDiv').hide();
$('.addSegment').hide();
$('.multitraveller').hide();
$('.block').hide();
$('#oneRound :input').prop("disabled", false);
$('.disableres :input').prop("disabled", false);
var dateMin = $('#from').datepicker("getDate");
var c_out_date = new Date(dateMin.getFullYear(), dateMin.getMonth(), dateMin.getDate() + 1);
var theDate = new Date(Date.parse(c_out_date));
var dateFormatted = $.datepicker.formatDate('DD', theDate);
var ToFormatted = $.datepicker.formatDate('dd/mm/yy', theDate);
$('.Return').html(dateFormatted);
$('#return_date').val(ToFormatted);
$('#to').val($.datepicker.formatDate('d M yy', theDate));
$("#to").removeAttr("readonly", "readonly");
$("#to").removeAttr("disabled", "disabled");
$("#to").removeClass("disabledcls", true);
} else if (tripType == 3) {
<?php if ($IsTBOFlightAPI == 1) { ?>
$('.tripTypeDrop').val(1);
alert('Coming soon...');
return false;
<?php } ?>
// alert('navratan');
$('.disableres').hide();
$('.multitraveller').show();
$('.block').show();
$('.addSDiv').show();
$('.addSegment').show();
$('#oneRound :input').prop("disabled", true);
$('.disableres :input').prop("disabled", true);
//$(".checkaction").trigger('click');
//$(".checkaction").trigger('click');
if (counter == 0) {
$(".checkaction").trigger('click');
// $(".checkaction").trigger('click');
}
} else {
$('.addSDiv').hide();
$('.addSegment').hide();
$('.disableres').show();
$('.multitraveller').hide();
$('.block').hide();
$('#oneRound :input').prop("disabled", false);
$('.disableres :input').prop("disabled", false);
$('#to').val('');
$('.Return').html('');
$('#return_date').val('');
$("#to").attr("readonly", "readonly");
$("#to").addClass("disabledcls");
}
});
$('.addSegment,.countSectore,.checkaction').click(function() {
var object = JSON.parse($('#sessionFlightSearchParams').val());
var addSegment = $(this).attr('checkaction');
$('.flightsubmit_searchflight').prop("disabled", false);
if (counter == 3) {
var CurrentDate = "<?= date('d M Y') ?>";
var CurrentDate2 = "<?= date('Y/m/d') ?>";
} else {
CurrentDate = '';
CurrentDate2 = '';
}
var mytrip_city_from, mytrip_city_to, departure_dates, selectedDate = '';
// alert(selectedDate);
//console.log($.isArray(object.mytrip_city_from));
// var mytrip_city_from = object.mytrip_city_from[counter];
// alert(mytrip_city_from);
if (object !== null && typeof object.mytrip_city_from[counter] !== 'undefined' && $.isArray(object.mytrip_city_from)) {
var mytrip_city_from = object.mytrip_city_from[counter];
} else {
var mytrip_city_from = '';
}
if (object !== null && typeof object.mytrip_city_to[counter] !== 'undefined' && $.isArray(object.mytrip_city_to)) {
mytrip_city_to = object.mytrip_city_to[counter];
} else {
mytrip_city_to = '';
}
if (object !== null && typeof object.departure_date[counter] !== 'undefined' && $.isArray(object.departure_date)) {
var selectedDate = object.departure_date[counter];
var dateM = new Date(selectedDate);
var FromFormatted = $.datepicker.formatDate('d M yy', dateM);
departure_dates = FromFormatted;
} else {
departure_dates = CurrentDate;
}
if (object !== null && typeof object.source_city[counter] !== 'undefined' && $.isArray(object.source_city)) {
var source_city = object.source_city[counter];
} else {
var source_city = '';
}
if (object !== null && typeof object.ContSysId_1[counter] !== 'undefined' && $.isArray(object.ContSysId_1)) {
var ContSysId_1 = object.ContSysId_1[counter];
} else {
var ContSysId_1 = '';
}
if (object !== null && typeof object.destination_city[counter] !== 'undefined' && $.isArray(object.destination_city)) {
var destination_city = object.destination_city[counter];
} else {
var destination_city = '';
}
if (object !== null && typeof object.ContSysId[counter] !== 'undefined' && $.isArray(object.ContSysId)) {
var ContSysId = object.ContSysId[counter];
} else {
var ContSysId = '';
}
if (object !== null && typeof object.source[counter] !== 'undefined' && $.isArray(object.source)) {
var source = object.source[counter];
} else {
var source = '';
}
if (object !== null && typeof object.destination[counter] !== 'undefined' && $.isArray(object.destination)) {
var destination = object.destination[counter];
} else {
var destination = '';
}
if (object !== null && typeof object.from_mytrip_city[counter] !== 'undefined' && $.isArray(object.from_mytrip_city)) {
var from_mytrip_city = object.from_mytrip_city[counter];
} else {
var from_mytrip_city = '';
}
if (object !== null && typeof object.to_mytrip_city[counter] !== 'undefined' && $.isArray(object.to_mytrip_city)) {
var to_mytrip_city = object.to_mytrip_city[counter];
} else {
var to_mytrip_city = '';
}
var removeTag = ''
if (counter > 1) {
removeTag = `<a id="removeDIV` + counter + `" href="javascript:void(0);" index="` + counter + `" class="multiremove22 removeSeg"><i class="fa fa-minus-circle" aria-hidden="true"></i></a>`
}
if (counter == 3) {
$('.addSegment').hide();
}
$('.block').append(`<div class="row DeleteRow_` + counter + `">
<div class="col-md-4 col-sm-6 col-6">
<input class="form-control airport_search countSectore apendn_1` + counter + `" index="1` + counter + `" type="text" name="mytrip_city_from[]" id="mytrip_city_from` + counter + `" placeholder="Type source city.." value="` + mytrip_city_from + `" counter="` + counter + `" autocomplete="off" />
<ul id="sourcesjd"></ul>
</div>
<div class="col-md-4 col-sm-6 col-6 exchangeroot">
<input class="form-control airport_search apendn_2` + counter + `" index="2` + counter + `" type="text" name="mytrip_city_to[]" id="mytrip_city_to` + counter + `" placeholder="Type destination city.." value="` + mytrip_city_to + `" counter="` + counter + `" autocomplete="off" />
<ul id="destinjd"></ul>
</div>
<div class="col-md-4 col-sm-6 col-12">
<div class="date-parent date-parentwidth">
<input class="form-control" type="text" name="departure_dates[]" id="departure_dates` + counter + `" placeholder="" value="` + departure_dates + `" index="` + counter + `" counter="` + counter + `" readonly />
</div>
` + removeTag + `
</div>
</div>
<input type="hidden" id="airport_search_1` + counter + `" name="source_city[]" value="` + source_city + `">
<input type="hidden" id="ContSysId_1` + counter + `" name="ContSysId_1[]" value="` + ContSysId_1 + `" />
<input type="hidden" id="airport_search_2` + counter + `" name="destination_city[]" value="` + destination_city + `">
<input type="hidden" id="ContSysId_2` + counter + `" name="ContSysId[]" value="` + ContSysId + `" />
<input type="hidden" id="FromToCIty_1` + counter + `" name="source[]" value="` + source + `">
<input type="hidden" id="FromToCIty_2` + counter + `" name="destination[]" value="` + destination + `">
<input type="hidden" id="departure_date` + counter + `" name="departure_date[]" value="` + selectedDate + `">
<input type="hidden" id="return_date` + counter + `" name="return_date[]" value="">
<input type="hidden" id="mytrip_city_1` + counter + `" name="from_mytrip_city[]" value="` + from_mytrip_city + `">
<input type="hidden" id="mytrip_city_2` + counter + `" name="to_mytrip_city[]" value="` + to_mytrip_city + `">
<div class="clearfix"></div>
</div> `);
if (addSegment === 'addSegment') {
var mytrip_city_to = $('#mytrip_city_to' + (counter - 1)).val();
var ContSysId_1 = $('#ContSysId_1' + (counter - 1)).val();
var airport_search_2 = $('#airport_search_2' + (counter - 1)).val();
var FromToCIty_2 = $('#FromToCIty_2' + (counter - 1)).val();
var mytrip_city_2 = $('#mytrip_city_2' + (counter - 1)).val();
$('#mytrip_city_from' + (counter)).val(mytrip_city_to);
$('#ContSysId_1' + (counter)).val(ContSysId_1);
$('#airport_search_1' + (counter)).val(airport_search_2);
$('#FromToCIty_1' + (counter)).val(FromToCIty_2);
$('#mytrip_city_1' + (counter)).val(mytrip_city_2);
}
if (counter == 3) {
$('#title_' + counter).html('Source city');
$('#title_1' + counter).html('Destination city');
$('#title_2' + counter).html('Departure Date');
} else { //
$('#title_' + counter).html('');
$('#title_1' + counter).html('');
$('#title_2' + counter).html('');
}
$('#removeDIV' + (counter - 1)).hide();
$('#departure_dates' + counter).datepicker({
changeMonth: false,
dateFormat: "d M yy",
numberOfMonths: 2,
minDate: 0,
buttonImage: true,
buttonImageOnly: true,
beforeShow: function(ct, en) {
var index = $(this).attr('index');
var CheckIn = $("#departure_dates" + (index - 1)).val();
if (typeof CheckIn !== 'undefined') {
var dateMin = new Date(CheckIn);
var rMin = new Date(dateMin.getFullYear(), dateMin.getMonth(), dateMin.getDate());
$('#departure_dates' + index).datepicker("option", "minDate", rMin);
}
//
},
onSelect: function(selectedDate, inst) {
var index = $(this).attr('index');
var dateMin = new Date(selectedDate);
var rMin = new Date(dateMin.getFullYear(), dateMin.getMonth(), dateMin.getDate() + 0); // Min Date = Selected + 1d
var rMax = new Date(dateMin.getFullYear(), dateMin.getMonth(), dateMin.getDate() + 180); // Max Date = Selected + 62d
var c_out_date = new Date(dateMin.getFullYear(), dateMin.getMonth(), dateMin.getDate() + 0); // Min Date = Selected + 1d
var theDate = new Date(Date.parse($(this).datepicker('getDate')));
var FromFormatted = $.datepicker.formatDate('yy/mm/dd', theDate);
$('#departure_date' + (parseInt(index))).val(FromFormatted);
}
});
setTimeout(function() {
$.getJSON(SITEURL + 'flight/getsetcity', function(source) {
$(".airport_search").autocomplete({
minLength: 0,
autoFocus: true,
source: function(request, response) {
var term = $.ui.autocomplete.escapeRegex(request.term),
startsWithMatcher = new RegExp("^" + term, "i"),
startsWith = $.grep(source, function(value) {
return startsWithMatcher.test(value.AirportCode || value.value || value);
}),
containsMatcher = new RegExp(term, "i"),
contains = $.grep(source, function(value) {
return $.inArray(value, startsWith) < 0 &&
containsMatcher.test(value.label || value.value || value);
});
response(startsWith.concat(contains).slice(0, 10));
},
response: function(e) {
//console.log(e);
},
select: function(event, ui) {
var counter = $(this).attr('counter');
var name = $(this).attr('name');
var index = $(this).attr('index');
var value = ui.item.value;
var dddd = value.split(',');
ui.item.value = dddd[0] + ' (' + ui.item.AirportCode + ')';
//alert(dddd[0]);
$('.apendn_' + index).val(dddd[0]);
$('.fromText_' + index).html(dddd[1]);
$('#mytrip_city_' + index).val(dddd[1]);
$('#FromToCIty_' + index).val(value);
$('#airport_search_' + index).val(ui.item.AirportCode);
$('#ContSysId_' + index).val(ui.item.ContSysId);
$(this).removeClass('extend_width');
$("#bannerslider").removeClass("ss");
$(".search-box").removeClass("extend_width2");
$(".flight-search-flight2").removeClass("extend_width2");
$(".apendn_2").removeClass("showsecond");
$(".formtitlecls").removeClass("showsecond");
$(".formullist").removeClass("ss");
$(".frmclose").removeClass("extend_width_frmclose");
$(".custom-nav").removeClass("frmhidesection");
if (name === 'mytrip_city_to[]') {
var fromcity = dddd[0] + '(' + ui.item.AirportCode + ')';
//console.log(fromcity);
//$('#mytrip_city_from' + (parseInt(counter) + 1)).attr('readonly', true);
//$('#mytrip_city_from' + (parseInt(counter) + 1)).removeClass('airport_search');
$('.apendn_1' + (parseInt(counter) + 1)).val(dddd[0]);
$('.fromText_1' + (parseInt(counter) + 1)).html(dddd[1]);
$('#mytrip_city_1' + (parseInt(counter) + 1)).val(dddd[1]);
$('#FromToCIty_1' + (parseInt(counter) + 1)).val(value);
$('#airport_search_1' + (parseInt(counter) + 1)).val(ui.item.AirportCode);
$('#ContSysId_1' + (parseInt(counter) + 1)).val(ui.item.ContSysId);
$('#mytrip_city_from' + (parseInt(counter) + 1)).val(fromcity);
}
}
}).focus(function() {
//$(this).val('');
// debugger;
$(this).addClass("extend_width");
$("#bannerslider").addClass("ss");
$(".search-box").addClass("extend_width2");
$(".flight-search-flight2").addClass("extend_width2");
$(".apendn_2").addClass("showsecond");
$(".formtitlecls").addClass("showsecond");
$(".formullist").addClass("ss");
$(".frmclose").addClass("extend_width_frmclose");
$(".custom-nav").addClass("frmhidesection");
// $('html, body').animate({
// scrollTop: $("#bannerslider").offset().top - 460
// }, 200);
//$(this).autocomplete('search');
});
});
}, 1000);
counter++;
});
$('body').on('click', '.removeSeg', function() {
var index = $(this).attr('index');
$(".DeleteRow_" + index).remove();
$('#removeDIV' + (index - 1)).show();
$('.addSegment').show();
counter--;
});
$(document).on('click', '.tripTypeRound', function() {
$("#to").removeAttr("disabled", "disabled");
$("#RoundTrip").prop('checked', true);
$("#to").removeClass("disabledcls");
// debugger;
$("#to").datepicker("show");
});
$('.getsearch').on('click', function() {
var index = $(this).attr('index');
var searchurl = $('#searchurl_' + index).val();
if (searchurl == '') {
alert('Oops invalid search data');
return false;
} else {
window.location.href = 'flight/flightsearchdata?' + searchurl;
}
});
setTimeout(function() {
// $('.select2').select2();
$.getJSON(SITEURL + 'flight/getsetcity', function(source) {
$(".airport_search").autocomplete({
minLength: 0,
autoFocus: true,
source: function(request, response) {
var term = $.ui.autocomplete.escapeRegex(request.term),
startsWithMatcher = new RegExp("^" + term, "i"),
startsWith = $.grep(source, function(value) {
return startsWithMatcher.test(value.AirportCode || value.value || value);
}),
containsMatcher = new RegExp(term, "i"),
contains = $.grep(source, function(value) {
return $.inArray(value, startsWith) < 0 &&
containsMatcher.test(value.label || value.value || value);
});
response(startsWith.concat(contains).slice(0, 10));
},
response: function(e) {
//console.log(e);
},
select: function(event, ui) {
var index = $(this).attr('index');
var value = ui.item.value;
var dddd = value.split(',');
ui.item.value = dddd[0] + ' (' + ui.item.AirportCode + ')';
//alert(dddd[0]);
$('.apendn_' + index).val(dddd[0]);
$('.fromText_' + index).html(dddd[1]);
$('#mytrip_city_' + index).val(dddd[1]);
$('#FromToCIty_' + index).val(value);
$('#airport_search_' + index).val(ui.item.AirportCode);
$('#ContSysId_' + index).val(ui.item.ContSysId);
$('.flightsubmit_searchflight').prop("disabled", false);
}
}).focus(function() {
$(this).val('');
$(this).autocomplete('search');
});
});
}, 1000);
$(".passengercity").autocomplete({
minLength: 2,
autoFocus: true,
source: SITEURL + 'cms/index/getgeocity',
select: function(event, ui) {
var code = ui.item.code;
var cityid = ui.item.id;
$("#passenger-city-1").val(cityid);
$("#passenger-country-1").val(ui.item.ContId);
}
});
$(document).on('click', '.multicity_form_boxshow2', function() {
var index = $(this).attr('index');
$(".show_multicity_wrapper" + index).toggle("show_hiddenpart_hidden");
$("i", this).toggleClass("fa-chevron-circle-up fa-chevron-circle-down");
});
$(document).on('click', '.multicity_form_boxshow3', function() {
var index = $(this).attr('index');
$(".show_multicity_wrapper3" + index).toggle("show_hiddenpart_hidden");
$("i", this).toggleClass("fa-chevron-circle-up fa-chevron-circle-down");
});
});
$(document).on('click', '.edit_multicity_icond', function() {
if ($('li.FareRules').hasClass('active')) {
$('.FareRulesDiv').click();
}
});
$(document).on('click', '.FareRulesDiv', function() {
var IsLCC = $(this).attr('IsLCC');
var index = $(this).attr('index');
var TraceId = $(this).attr('data');
var apiTraceId = $(this).attr('apiTraceId');
var ApiResultIndex = $(this).attr('ResultIndex');
var ICSourceSysId = $(this).attr('ICSourceSysId');
var ItemData = $('#ItemData').val();
var PriceIDs = $('#PriceIDs').val();
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/getflightfarerules",
dataType: 'html',
data: {
TraceId: TraceId,
apiTraceId: apiTraceId,
ApiResultIndex: ApiResultIndex,
IsLCC: IsLCC,
ICSourceSysId: ICSourceSysId,
PriceID: PriceIDs,
item: ItemData,
},
beforeSend: function() {
$("#FareRulesDiv_" + index).html('<div style="text-align:center;padding-top:30px;"><img src="<?php echo $baseUrl; ?>public/images/loader.gif"/></div>');
},
success: function(data) {
// console.log(data);
$("#FareRulesDiv_" + index).html(data);
}
});
});
function couponApply() {
var couponval = $('#couponcode').val();
var TraceId = $('#TraceId').val();
if (couponval == '') {
alert('Please enter coupon code');
return false;
}
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/coupon-apply",
dataType: 'json',
data: {
couponval: couponval,
TraceId: TraceId,
actions: 'add',
},
beforeSend: function() {
$("#coupon").html('<img src="<?php echo $baseUrl; ?>public/images/loader.gif" height="20"/>');
},
success: function(response) {
if (response.success) {
$("#FareChangeData").html(response.html);
$("#intPublishedFare").html($('.price_fair_').text());
$('#dissntsfds').show();
$('.apply-coupon').hide();
$("#coupon").html('Apply');
} else {
alert(response.message);
$("#coupon").html('Apply');
return false;
}
}
});
}
function removeCoupon() {
var couponval = $('#couponcode').val();
var TraceId = $('#TraceId').val();
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/coupon-apply",
dataType: 'json',
data: {
couponval: couponval,
TraceId: TraceId,
actions: 'remove',
},
success: function(response) {
if (response.success) {
$("#FareChangeData").html(response.html);
$("#intPublishedFare").html($('.price_fair_').text());
$('#couponcode').removeAttr('readonly');
$('.apply-coupon').show();
$('#couponcode').val('');
$("input[type=radio][name=coupon]").prop('checked', false);
} else {
alert(response.message);
return false;
}
}
});
}
$(document).on('click', '.couponrd', function() {
var DiscountCode = $(this).val();
$('#couponcode').val(DiscountCode);
couponApply();
});
$('.exchange_transfer,.exchange_transfer_searchflight').on('click', function() {
$('.flightsubmit_searchflight').prop("disabled", false);
var mytrip_city_from = $('#mytrip_city_from').val();
var mytrip_city_to = $('#mytrip_city_to').val();
$('#mytrip_city_from').val(mytrip_city_to);
$('#mytrip_city_to').val(mytrip_city_from);
var fromText_1 = $('.fromText_1').text();
var fromText_2 = $('.fromText_2').text();
$('.fromText_1').html(fromText_2);
$('.fromText_2').html(fromText_1);
var airport_search_1 = $('#airport_search_1').val();
var airport_search_2 = $('#airport_search_2').val();
$('#airport_search_1').val(airport_search_2);
$('#airport_search_2').val(airport_search_1);
var ContSysId_1 = $('#ContSysId_1').val();
var ContSysId_2 = $('#ContSysId_2').val();
$('#ContSysId_1').val(ContSysId_2);
$('#ContSysId_2').val(ContSysId_1);
var FromToCIty_1 = $('#FromToCIty_1').val();
var FromToCIty_2 = $('#FromToCIty_2').val();
$('#FromToCIty_1').val(FromToCIty_2);
$('#FromToCIty_2').val(FromToCIty_1);
var mytrip_city_1 = $('#mytrip_city_1').val();
var mytrip_city_2 = $('#mytrip_city_2').val();
$('#mytrip_city_1').val(mytrip_city_2);
$('#mytrip_city_2').val(mytrip_city_1);
});
$('.flightsearch').on('submit', function(event) {
var source = $('input[name="source"]').val();
var mytrip_city_from = $('input[name="mytrip_city_from"]').val();
var mytrip_city_to = $('input[name="mytrip_city_to"]').val();
var destination = $('input[name="destination"]').val();
var source_city = $('input[name="source_city"]').val();
var destination_city = $('input[name="destination_city"]').val();
var route = $(".tripType:checked").val();
var TotalPax = 0;
$('.flight-clsn-trvl-dtl input[type=radio]').each(function() {
if (this.checked) {
TotalPax += parseInt($(this).val());
}
});
if (TotalPax >= 10) {
alert("More than 9 Passenger's can not travel.");
return false;
}
if (route === '3') {
/// event.preventDefault();
var returnvalue = true;
$(".countSectore").each(function(i, field) {
var mytrip_city_from = $('#mytrip_city_from' + i).val();
var mytrip_city_to = $('#mytrip_city_to' + i).val();
var departure_dates = $('#departure_dates' + i).val();
if (mytrip_city_from === '') {
alert('Please enter source city name');
returnvalue = false;
return false;
}
if (mytrip_city_to === '') {
alert('Please enter destination city name');
returnvalue = false;
return false;
}
if (departure_dates === '') {
alert('Please enter departure date');
returnvalue = false;
return false;
}
});
if (returnvalue) {
// $('.flightsearch').submit();
} else {
return false;
}
} else {
if (mytrip_city_from === '') {
alert('Please enter from city name');
$('input[name="mytrip_city_from"]').focus();
return false;
}
if (mytrip_city_to === '') {
alert('Please enter to city name');
$('input[name="mytrip_city_to"]').focus();
return false;
}
if (source === '') {
alert('Please enter from city name');
$('input[name="source"]').focus();
return false;
} else if (destination === '') {
alert('Please enter to city name');
$('input[name="destination"]').focus();
return false;
} else if (source_city === '') {
alert('Please enter valif from city name');
$('input[name="source"]').focus();
return false;
} else if (destination_city === '') {
alert('Please enter valif to city name');
$('input[name="destination"]').focus();
return false;
} else if (mytrip_city_from == mytrip_city_to) {
alert('Source and destination can not be same');
return false;
}
}
});
$('.flight_infotitle_dd').on("click", function() {
$(".flight_information_details_content").toggle("show_hiddenpart_hidden");
});
$('.fair_information').on("click", function() {
// $(".fair_information_details").toggle("fair_information_show");
$(".fair_information_details").slideToggle("slow");
//$(".fair_details").slideToggle("slow");
});
$('.RefreshTraveller').on("click", function() {
$('.RefreshTraveller').addClass("fa-spin");
$('.makepayment').hide();
getSearchCutomer();
});
<?php if (isset($session->session) && !empty($session->session) && $action == 'travellers') { ?>
getSearchCutomer();
<?php } ?>
function BookingStatus() {
var bookingid = $.trim($('#bookingid').val());
var bookemail = $.trim($('#bookemail').val());
var regex = /^([a-zA-Z0-9_\.\-\+])+\@(([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/;
if (bookingid === '') {
alert('Please enter booking id.');
$("#bookingid").focus();
cont = false;
return false;
}
if (!regex.test(bookemail)) {
alert('Please enter valid email id.');
$("#bookemail").focus();
cont = false;
return false;
}
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/bookingstatus",
dataType: 'json',
data: {
bookingid: bookingid,
bookemail: bookemail,
},
beforeSend: function() {
$('.bookingstatus_').prop("disabled", true);
$(".bookingstatus_").html('Please wait..');
},
success: function(data) {
if (data.success) {
$('.bookingstatus_').prop("disabled", false);
$(".bookingstatus_").hide();
$(".printticker").show();
$('.printticker').attr('href', 'flight/e-ticket/' + data.BookingId + '?source=' + data.ICSourceSysId);
$('.mesg').html(data.message);
} else {
$('.bookingstatus_').prop("disabled", false);
$(".bookingstatus_").html('Check Status');
alert(data.message);
return false;
}
}
});
}
function getSearchCutomer() {
$('#CustomerSysId-1').val('0');
var leadMobile = $('#leadMobile').val();
var leadEmail = $('#leadEmail').val();
if (leadMobile === '') {
alert('Please enter mobile number');
$("#leadMobile").focus();
$("#leadEmail").val('');
return false;
}
$.ajax({
url: '<?php echo $baseUrl; ?>flight/searchcutomer',
data: {
leadEmail: leadEmail,
leadMobile: leadMobile
},
dataType: 'json',
type: 'POST',
error: function() {},
success: function(response) {
if (response.success) {
var leadPax = (response.leadPax);
$("#passenger-address-1").val(leadPax.Address);
$("#passenger-city-1").val(leadPax.CitySysId);
$("#passenger-country-1").val(leadPax.CountrySysId);
$("#passenger-city-name-1").val(leadPax.CityTitle);
$('.makepayment').show();
// $("#companyname").val(leadPax.companyname);
// $("#gstnnumber").val(leadPax.gstnnumber);
// $("#gstaddress").val(leadPax.gstaddress);
// $("#gstcity").val(leadPax.gstcity);
// $("#gststate").val(leadPax.gststate);
// $("#gstpincode").val(leadPax.gstpincode);
if (JSON.stringify(response.data).length > 0) {
$('#savedtraveller').show();
var values = 0;
$("#relation-1 option[value='" + values + "']").css("display", "none");
$('#relation-1').val(1);
} else {
$('#savedtraveller').hide();
}
var data = (response.data);
SetData('customerMember', JSON.stringify(data));
var ind = 0;
var Listul = $('<div></div>');
$.each(data, function(index, obj) {
if (ind == 0) {
var CustomerSysId = obj.CustomerSysId;
} else {
var CustomerSysId = obj.CustomerMemberSysId;
}
//<span class="checkmark"></span>
Listul.append('<div class="gst_add_align2"><label class="checkboxcontainerreviewaddons_savedlist" style="width:100%;"><input id="custMember_' + CustomerSysId + '" name="cusmemberSelected[]" onclick="Selectmember(this,' + obj.paxType + ')" type="checkbox" value="_' + CustomerSysId + '"/> ' + obj.SalutationTxt + ' ' + obj.FirstName + ' ' + obj.LastName + ' <br><span class="adult_listtitle">' + obj.paxTypeName + '</span></label></div>');
ind++;
});
var ListulMob = $('<div></div>');
$.each(data, function(index, obj) {
ListulMob.append(`<div class="customgst_savedlist gst_add_align2_mobile"><label class="checkboxcontainerreviewaddons_savedlist" for="custMember_` + obj.CustomerMemberSysId + `"><input type="checkbox" id="custMember_` + obj.CustomerMemberSysId + `" name="cusmemberSelected[]" onclick="Selectmember(this,` + obj.paxType + `)" value="` + obj.CustomerMemberSysId + `">` + obj.SalutationTxt + ` ` + obj.FirstName + ` ` + obj.LastName + `<br> <span class="adult_listtitle">` + obj.RelationTxt + ` | ` + obj.paxTypeName + `</span> </label></div>`);
});
var lenght = Object.keys(data).length;
if (lenght > 0) {
$(".saved_btn").show();
}
$('#dynamic_div').html(Listul);
$('.RefreshTraveller').show();
$('#dynamic_div__k').html(ListulMob);
setTimeout(function() {
$('.RefreshTraveller').removeClass("fa-spin");
}, 2000);
} else {
var values = 0;
$("#relation-1 option[value='" + values + "']").css("display", "block");
$('#relation-1').val(0);
$('#savedtraveller').hide();
}
}
});
return false;
}
function Selectmember(data, paxType) {
var checkedornot = $("#custMember" + data.value).prop('checked');
var customerMember = JSON.parse(GetData('customerMember'));
var obj = customerMember[data.value];
var totalpass = $('.adultdetails').length;
var selectedpass = $("input[name='cusmemberSelected[]']:checked");
//alert(totalpass);
//alert(selectedpass);
if (totalpass >= selectedpass.length) {
var b = 1;
//$("#custMember" + data.value).attr('disabled', 'disabled');
$(".familyNumber").each(function() {
var CustomerSysId = $.trim($("#CustomerSysId-" + b).val());
var firstname = $.trim($("#passenger-firstname-" + b).val());
if (CustomerSysId == 0 && firstname == '') {
if (obj.paxType == 1) {
var paxTypes = 'Adult';
} else if (obj.paxType == 2) {
var paxTypes = 'Child';
} else {
var paxTypes = 'Infant';
}
var DOB = obj.dobday + '/' + obj.dobmonth + '/' + obj.dobyear;
$("#CustomerSysId-" + b).val(obj.CustomerMemberSysId);
$("#CRADULT-" + b).attr('value', obj.CustomerMemberSysId);
$("#CRADULT-" + b).show();
$("#passenger-firstname-" + b).val(obj.FirstName);
$("#passenger-lastname-" + b).val(obj.LastName);
$("#travellerdetails" + b).val(obj.SalutationTxt + ' ' + obj.FirstName + ' ' + obj.LastName);
$("#dateofbirth-" + b).val(DOB);
$("#travel_details" + b).html(obj.RelationTxt + ' | ' + paxTypes);
$.each($("input[name='salution-" + b + "']"), function() {
// if (obj.Salutation == $(this).val()) {
// $(".checksalution-" + b + "-" + paxType + "-" + obj.Salutation).trigger('click').prop('checked', true);
// }
});
$("#salution-" + b).val(obj.Salutation);
$("#relation-" + b).val(obj.Relation);
$("#PassportNationality-" + b).val(obj.PassportNation);
$("#passportno-" + b).val(obj.PassportNo);
$("#passportnoexpiry-" + b).val(obj.PassportExpiry);
$("#passporIssue-" + b).val(obj.passporIssue);
//console.log(obj);
return false;
} else {
}
b++;
});
} else {
alert('Please select up to ' + totalpass + ' of traveller(s) or add new in the traveller details');
$("#custMember" + data.value).prop('checked', false);
return false;
}
}
$(document).on('click', '.saved_btn', function() {
var index = $(this).attr('index');
var paxType = $(this).attr('paxTypes');
var FirstName = $(".passenger-firstname-" + index + '-' + paxType).val();
var LastName = $(".passenger-lastname-" + index + '-' + paxType).val();
var DOB = $(".dateofbirth-" + index + '-' + paxType).val();
var Salutation = $("input[name='salution-" + index + "']:checked").attr('data');
var Relation = $(".relation-" + index + '-' + paxType).children("option:selected").text();
if (paxType == 1) {
var paxTypes = 'Adult';
} else if (paxType == 2) {
var paxTypes = 'Child';
} else {
var paxTypes = 'Infant';
}
$("#travellerdetails" + index).val(Salutation + ' ' + FirstName + ' ' + LastName);
$("#travel_details" + index).html(Relation + ' | ' + paxTypes);
$('#ADULT' + index).modal('hide');
$('#CHILD' + index).modal('hide');
$('#INFANT' + index).modal('hide');
});
$('#isgstapply').on("click", function() {
var isgstapply = $("input[name='isgstapply']:checked").length;
if (isgstapply) {
$('.isgstapply').attr('disabled', false);
$('.gstdiv').show();
} else {
$('.isgstapply').attr('disabled', true);
$('.gstdiv').hide();
}
});
//otp start
function makePayment() {
var apiTraceId = $('#apiTraceId').val();
var TraceId = $('#TraceId').val();
var accepttandc = $("input[name='accepttandc']:checked").length;
var IsCancellationProtection = $("input[name='IsCancellationProtection']:checked").val();
if (accepttandc) {
$.ajax({
type: "POST",
data: {
TraceId: apiTraceId,
apiTraceId: TraceId,
IsCancellationProtection: IsCancellationProtection,
},
url: "<?php echo $baseUrl; ?>flight/makepayment",
dataType: 'json',
beforeSend: function() {
$(".paynowbtn22").html('Please wait...');
$(".paynowbtn22").prop('disabled', true);
},
success: function(data) {
if (data.success) {
$('#VerifyOTP').modal('show');
$('#hidePhoneNumberDigit').html(data.hidePhoneNumberDigit);
$(".paynowbtn22").html('Make Payment');
$(".paynowbtn22").prop('disabled', false);
} else {
alert(data.message);
return false;
}
}
});
} else {
alert('Please accept term and condition');
return false;
}
}
function verifying() {
var OTPNumber = $("#OTPNumber").val();
var apiTraceId = $('#apiTraceId').val();
var TraceId = $('#TraceId').val();
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/makepayment",
dataType: 'json',
data: {
OTPNumber: OTPNumber,
TraceId: apiTraceId,
apiTraceId: TraceId,
verifying: 'true',
},
beforeSend: function() {
$(".ContinueAccept").html('Please wait..');
$(".ContinueAccept").attr('disabled', true);
},
success: function(data) {
if (data.success) {
if (data.paynow) {
location.href = 'flight/pay-now/' + TraceId;
return true;
}
$(".ContinueAccept").html('Continue Booking');
$(".ContinueAccept").removeAttr('disabled');
} else {
$(".ContinueAccept").html('Continue Booking');
$(".ContinueAccept").removeAttr('disabled');
alert(data.message);
return false;
}
}
});
}
//otp end
// $(".paynowbtn22").click(function() {
// var accepttandc = $("input[name='accepttandc']:checked").length;
// if (accepttandc) {
// return true;
// } else {
// alert('Please accept term and condition');
// return false;
// }
// });
// $(".checkboxcontainerreviewaddons").click(function() {
// var accepttandc = $("input[name='accepttandc']:checked").length;
// var TraceId = $('#TraceId').val();
// if (accepttandc) {
// //$('.paynowbtn22').attr('href', 'flight/book-flight/' + TraceId + '');
// $('.paynowbtn22').attr('href', 'flight/pay-now/' + TraceId + '');
// $(".continue_btnddonsreview").addClass('continue_btnddonsreview_fillbg');
// } else {
// $('.paynowbtn22').attr('href', 'javascript://');
// $(".continue_btnddonsreview").removeClass('continue_btnddonsreview_fillbg');
// }
// });
function savePassengerDetails() {
var data = $("#passenger-details").serialize();
var mobile_number = $("#leadMobile").val();
var TraceId = $("#TraceId").val();
var countryCode = $("#countryCode").val();
var countryCodeISO = $('#countryCode').find('option:selected').attr('data-countrycode');
var email_id = $("#leadEmail").val();
var companyname = $("#companyname").val();
var gstnnumber = $("#gstnnumber").val();
var gstaddress = $("#gstaddress").val();
var gstcity = $("#gstcity").val();
var gststate = $("#gststate").val();
var gstpincode = $("#gstpincode").val();
var accepttandc = $("input[name='accepttandc']:checked").length;
console.log(data);
//return false;
//alert(accepttandc);
$.ajax({
url: '<?php echo $baseUrl; ?>flight/save-passenger-details',
data: data + '&leadMobile=' + mobile_number + '&leadEmail=' + email_id + '&countryCode=' + countryCode + '&gstnnumber=' + gstnnumber + '&companyname=' + companyname + '&accepttandc=' + accepttandc + '&gstaddress=' + gstaddress + '&gstcity=' + gstcity + '&gststate=' + gststate + '&gstpincode=' + gstpincode + '&traceId=' + TraceId + '&countryCodeISO=' + countryCodeISO,
dataType: 'json',
type: 'POST',
error: function() {},
beforeSend: function() {
$("#proceed").html("Please Wait ...");
//$("#proceed").prop('disabled', true);
$("#proceedMobile").html("Please Wait ...");
//$("#proceedMobile").prop('disabled', true);
},
success: function(response) {
if (response.success) {
LoadAddOns();
$("#proceed").html("Continue");
$('#accordion').accordion('option', 'active', 2);
$('.continue_btn_22').show();
$('.shsjboocontinue').show();
return false;
var apiTraceId = response.apiTraceId;
location.href = 'flight/add-onn-service/' + apiTraceId;
} else {
alert(response.msg);
var elementId = response.index;
$("#" + elementId).focus();
$("#proceed").html("Continue");
$("#proceed").prop('disabled', false);
$("#proceedMobile").html("Continue");
$("#proceedMobile").prop('disabled', false);
}
}
});
}
function opengst() {
$('#isgstapply').prop('checked', true);
$('.gstdiv').show();
$('.isgstapply').attr('disabled', false);
}
function saveMoredetails() {
var data = $("#passenger-details").serialize();
var mobile_number = $("#leadMobile").val();
var TraceId = $("#TraceId").val();
var countryCode = $("#countryCode").val();
var countryCodeISO = $('#countryCode').find('option:selected').attr('data-countrycode');
var email_id = $("#leadEmail").val();
var companyname = $("#companyname").val();
var gstnnumber = $("#gstnnumber").val();
var gstaddress = $("#gstaddress").val();
var gstemail = $("#gstemail").val();
var gststate = $("#gststate").val();
var gstphone = $("#gstphone").val();
var accepttandc = $("input[name='accepttandc']:checked").length;
// alert(accepttandc);
$.ajax({
url: '<?php echo $baseUrl; ?>flight/save-gst-details',
data: data + '&leadMobile=' + mobile_number + '&leadEmail=' + email_id + '&countryCode=' + countryCode + '&gstnnumber=' + gstnnumber + '&companyname=' + companyname + '&accepttandc=' + accepttandc + '&gstaddress=' + gstaddress + '&gstemail=' + gstemail + '&gststate=' + gststate + '&gstphone=' + gstphone + '&traceId=' + TraceId + '&countryCodeISO=' + countryCodeISO,
dataType: 'json',
type: 'POST',
error: function() {},
beforeSend: function() {
$("#proceed").html("Please Wait ...");
// $("#proceed").prop('disabled', true);
$("#proceedMobile").html("Please Wait ...");
// $("#proceedMobile").prop('disabled', true);
},
success: function(response) {
if (response.success) {
var apiTraceId = response.apiTraceId;
location.href = 'flight/add-onn-service/' + apiTraceId;
} else {
alert(response.msg);
var elementId = response.index;
$("#" + elementId).focus();
$("#proceed").html("Continue");
$("#proceed").prop('disabled', false);
$("#proceedMobile").html("Continue");
$("#proceedMobile").prop('disabled', false);
}
}
});
}
$(".passportnoexpiry").datepicker({
dateFormat: "dd/mm/yy",
numberOfMonths: 1,
changeMonth: true,
changeYear: true,
});
$(function() {
$(".dateofbirth,.dateofbirth2,.dateofbirth3,.passportnoexpiry,.passporIssue").datepicker({
Readonly: true
}).attr('readonly', 'readonly');
});
var passporIssue = $(".passporIssue").datepicker({
dateFormat: "dd/mm/yy",
numberOfMonths: 1,
changeMonth: true,
changeYear: true,
beforeShow: function() {
var ct = new Date(); //alert(ct)
var day = ct.getDate() + 1; // month (in integer 0-11)
var month = ct.getMonth() + 1; // month (in integer 0-11)
var year = ct.getFullYear(); // year
var minYear = year;
passporIssue.datepicker("option", "yearRange", '2000:' + minYear);
passporIssue.datepicker("option", "maxDate", minYear + '/' + month + '/' + day);
}
});
var passporIssue2 = $(".passporIssue-2").datepicker({
dateFormat: "dd/mm/yy",
numberOfMonths: 1,
changeMonth: true,
changeYear: true,
beforeShow: function() {
var ct = new Date(); //alert(ct)
var day = ct.getDate() + 1; // month (in integer 0-11)
var month = ct.getMonth() + 1; // month (in integer 0-11)
var year = ct.getFullYear(); // year
var minYear = year;
var minYear2 = year - 12;
passporIssue2.datepicker("option", "yearRange", minYear2 + ':' + (minYear2 + 10));
passporIssue2.datepicker("option", "maxDate", minYear + '/' + month + '/' + day);
}
}).attr('readonly', 'readonly');
var passporIssue3 = $(".passporIssue-3").datepicker({
dateFormat: "dd/mm/yy",
numberOfMonths: 1,
changeMonth: true,
changeYear: true,
beforeShow: function() {
var ct = new Date(); //alert(ct)
var day = ct.getDate() + 1; // month (in integer 0-11)
var month = ct.getMonth() + 1; // month (in integer 0-11)
var year = ct.getFullYear(); // year
var minYear = year;
var minYear2 = year - 2;
passporIssue3.datepicker("option", "yearRange", minYear2 + ':' + (minYear2 + 2));
passporIssue3.datepicker("option", "maxDate", minYear + '/' + month + '/' + day);
}
}).attr('readonly', 'readonly');
var dateofbirth = $(".dateofbirth").datepicker({
dateFormat: "dd/mm/yy",
numberOfMonths: 1,
changeMonth: true,
changeYear: true,
beforeShow: function() {
var ct = new Date(); //alert(ct)
var day = ct.getDate() + 1; // month (in integer 0-11)
var month = ct.getMonth() + 1; // month (in integer 0-11)
var year = ct.getFullYear(); // year
var minYear = year - 13;
dateofbirth.datepicker("option", "yearRange", '1945:' + minYear);
dateofbirth.datepicker("option", "maxDate", minYear + '/' + month + '/' + day);
},
onSelect: function(selectedDate, inst) {
var ct = new Date();
var year = ct.getFullYear();
var theDate = new Date(Date.parse($(this).datepicker('getDate')));
if (year == theDate.getFullYear()) {
var c_out_date = new Date(theDate.getFullYear() - 75, theDate.getMonth(), theDate.getDate());
} else {
var c_out_date = new Date(theDate.getFullYear(), theDate.getMonth(), theDate.getDate());
}
var dateFormatted = $.datepicker.formatDate('dd/mm/yy', c_out_date);
//$("#dateofbirth-1").val(dateFormatted);
}
});
var dateofbirth2 = $(".dateofbirth2").datepicker({
dateFormat: "dd/mm/yy",
numberOfMonths: 1,
changeMonth: true,
changeYear: true,
beforeShow: function() {
var ct = new Date(); //alert(ct)
var day = ct.getDate() + 5; // month (in integer 0-11)
var month = ct.getMonth() + 1; // month (in integer 0-11)
var year = ct.getFullYear(); // year
var minYear2 = year - 12;
var rMin = new Date(ct.getFullYear() - 12, ct.getMonth() + 1, ct.getDate() + 5);
var rMax = new Date((ct.getFullYear() - 12) + 10, ct.getMonth(), ct.getDate() + 5);
dateofbirth2.datepicker("option", "yearRange", minYear2 + ':' + (minYear2 + 10));
dateofbirth2.datepicker("option", "minDate", rMin);
dateofbirth2.datepicker("option", "maxDate", rMax);
}
});
var dateofbirth3 = $(".dateofbirth3").datepicker({
dateFormat: "dd/mm/yy",
numberOfMonths: 1,
changeMonth: true,
changeYear: true,
beforeShow: function() {
var ct = new Date(); //alert(ct)
var day = ct.getDate() + 5; // month (in integer 0-11)
var month = ct.getMonth() + 1; // month (in integer 0-11)
var year = ct.getFullYear(); // year
var minYear2 = year - 2;
var rMin = new Date(ct.getFullYear() - 12, ct.getMonth() + 1, ct.getDate() + 5);
var rMax = new Date((ct.getFullYear() - 2) + 2, ct.getMonth(), ct.getDate());
dateofbirth3.datepicker("option", "yearRange", minYear2 + ':' + (minYear2 + 2));
dateofbirth3.datepicker("option", "minDate", rMin);
dateofbirth3.datepicker("option", "maxDate", rMax);
}
});
$('.travellerconatct_detailsbox').on("click", function() {
$(".travellerconatct_detailsbox").hide();
$(".traveller_information_boxshow").slideToggle("slow");
});
$('.arrowbox_wrppercontact').on("click", function() {
$(".traveller_information_boxshow").hide();
$(".travellerconatct_detailsbox").slideToggle("slow");
});
<?php
if (($modulename == 'default') && ($controller == 'flight') && ($action == 'payment' || $action == 'add-onn-service')) {
?>
LoadAddOns();
<?php } ?>
function LoadAddOns() {
var ApiResultIndex = $('#ApiResultIndex').val();
var ApiResultIndexInb = $('#ApiResultIndexInb').val();
var TraceId = $('#TraceId').val();
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/load-add-ons",
dataType: 'json',
data: {
TraceId: TraceId,
ApiResultIndex: ApiResultIndex,
ApiResultIndexInb: ApiResultIndexInb,
},
beforeSend: function() {
$("#loadaddonservice").html('<div style="text-align:center;padding-top:30px;"><img src="<?php echo $baseUrl; ?>public/images/loader.gif"/></div>');
},
success: function(data) {
if (data.success) {
$("#loadaddonservice").html(data.html);
$('.copyright').show();
} else {
$('.copyright').hide();
alert(data.message);
}
}
});
}
<?php
if (($modulename == 'default') && ($controller == 'flight') && ($action == 'travellers' || $action == 'add-onn-service___ddd')) {
?>
FlightFareQuote();
//LoadAddOns();
function FlightFareQuote() {
var ApiResultIndex = $('#ApiResultIndex').val();
var ApiResultIndexInb = $('#ApiResultIndexInb').val();
var TraceId = $('#TraceId').val();
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/getflightfarequote",
dataType: 'json',
data: {
TraceId: TraceId,
ApiResultIndex: ApiResultIndex,
ApiResultIndexInb: ApiResultIndexInb,
page: '<?= $action ?>'
},
beforeSend: function() {
$('.continue_btn').hide();
$('.continue_btn1').hide();
$('.paynow_btn').hide();
$('.continue_btn_22').hide();
$("#intPublishedFare").html('<img src="<?php echo $baseUrl; ?>public/images/loader-sm.gif"/>');
$("#FareChangeData").html('<div style="text-align:center;padding-top:30px;"><img src="<?php echo $baseUrl; ?>public/images/loader.gif"/></div>');
},
success: function(data) {
if (data.success) {
localStorage.clear();
countdown();
LoadAddOns();
getseatpage();
loadCoupon();
$('.continue_btn1').show();
//alert(data.apiResponse[0].isDobAdult);
if (data.FareChange) {
$("#FareChange").modal('show');
$("#intPublishedFarePOP").html(data.intPublishedFare);
}
if (data.apiResponse[0].isDobAdult == true) {
$('.adultdob').show();
} else {
$('.adultdob').hide();
}
if (data.apiResponse[0].isDobChild == true) {
$('.childdob').show();
} else {
$('.childdob').hide();
}
if (data.apiResponse[0].isDobInfant == true) {
$('.infantdob').show();
} else {
$('.infantdob').hide();
}
$("#FareChangeData").html(data.html);
$("#intPublishedFare").html($('.price_fair_').text());
var Baggagedata = (data.SSRArr.Baggage);
var Mealdata = (data.SSRArr.Meal);
if (data.SSRArrInb) {
var BaggagedataInb = (data.SSRArrInb.Baggage);
var MealdataInb = (data.SSRArrInb.Meal);
SetData('MealdataInb', JSON.stringify(MealdataInb));
SetData('BaggagedataInb', JSON.stringify(BaggagedataInb));
}
SetData('Mealdata', JSON.stringify(Mealdata));
SetData('Baggagedata', JSON.stringify(Baggagedata));
$('.continue_btn').show();
$('.paynow_btn').show();
// $('.continue_btn_22').show();
} else {
alert(data.message);
history.back();
//window.location.href = 'flight';
}
}
});
}
function ContinueAccept() {
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/continue-accept",
dataType: 'json',
// data: {TraceId:TraceId,ApiResultIndex:ApiResultIndex},
beforeSend: function() {
$(".ContinueAccept").html('Please wait...');
$(".ContinueAccept").prop('disabled', true);
},
success: function(data) {
if (data.success) {
$(".ContinueAccept").html('Continue Booking');
$(".ContinueAccept").prop('disabled', false);
$("#FareChangeData").html(data.html);
$("#FareChange").modal('hide');
} else {
alert(data.message);
}
}
});
// $("#fair_content").hide();
// $("#FareChangeData").show();
}
getseatpage();
function getseatpage() {
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/getseatpage",
dataType: 'json',
beforeSend: function() {},
success: function(data) {
$("#getseatpage").html(data.html);
}
});
}
function loadCoupon() {
var TraceId = $('#TraceId').val();
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/travellers/" + TraceId,
dataType: 'json',
success: function(data) {
if (data.success) {
$(".fair_summary-coupon").show();
var Listul = $('<ul></ul>');
$.each(data.response.data, function(index, obj) {
Listul.append(`<li> <input type="radio" name="coupon" class="couponrd" id="code_` + index + `" value="` + obj.DiscountCode + `">
<span class="checkmark"></span>
<span class="you_pay"><span class="discount-codde">` + obj.DiscountCode + `</span> <span class="price_fair_total">INR ` + obj.discount_value + `</span>
<span class="conversation_box dsc"> ` + obj.DiscountName + ` </span>
</span>
</li>`);
});
$('#couponListDiv').html(Listul);
}
}
});
}
$(document).on('click', '.seatmapModal', function() {
var segmentid = $(this).attr('value');
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/seatmap",
dataType: 'html',
data: {
segmentid: segmentid,
},
beforeSend: function() {
$("#loadsaetwarpper").html('<div style="text-align:center;padding-top:30px;"><img src="<?php echo $baseUrl; ?>public/images/loader.gif"/></div>');
},
success: function(data) {
$('.saetwarpper').html(data);
}
});
});
function isEmpty(seatArray) {
var NewArray = new Array();
$.each(seatArray, function(index, obj) {
var value = seatArray[index];
if (typeof value == 'string' && !value.trim() || typeof value == 'undefined' || value === null || value == 'NA') {
} else {
NewArray.push(value);
}
});
return NewArray;
}
$(document).on('click', '.continue_seatbtn', function() {
var segmentid = $(this).attr('segmentid');
var totalPax = $('#totalPax').val();
var seatArray = new Array();
var CustomerSysIdArray = new Array();
var paxTypeArr = new Array();
$('.CustomerSysId').each(function(e) {
var SeatNo = $(this).text();
var CustomerSysId = $(this).attr('CustomerSysId');
seatArray.push($(this).text());
CustomerSysIdArray.push($(this).attr('CustomerSysId'));
paxTypeArr.push($(this).attr('paxType'));
});
// var seatval = $(this).attr('value');
// alert(seatval);
if (parseInt(totalPax) !== isEmpty(seatArray).length) {
alert('Please select ' + totalPax + ' seat(s)');
return false;
} else {
$('#seat' + segmentid).html('Change Seat');
}
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/continuewithseatmap",
dataType: 'json',
data: {
CustomerSysIdArray: CustomerSysIdArray,
seatArray: seatArray,
segmentid: segmentid,
paxTypeArr: paxTypeArr,
},
beforeSend: function() {
$("#continue_seatbtn").html('Please wait..');
},
success: function(data) {
$("#FareChangeData").html(data.html);
$("#SelectedSegment" + segmentid).html(data.SelectedSegment);
$("#SelecButton" + segmentid).html('Change Seat');
$("#intPublishedFare").html(data.MobilePublishedFare);
$("#MobilePublishedFare").html(data.MobilePublishedFare);
$('#seatmapModal').modal('hide');
}
});
});
<?php } ?>
<?php
if (($modulename == 'default') && ($controller == 'flight') && ($action == 'add-onn-service')) {
?>
$(".disableddiv :input").attr("disabled", true);
<?php } ?>
function UpdateFare(data, actiontype, CustomerSysId, tripType) {
var ApiResultIndex = $('#ApiResultIndex').val();
var ApiResultIndexInb = $('#ApiResultIndexInb').val();
var TraceId = $('#TraceId').val();
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/updatefare",
dataType: 'json',
data: {
TraceId: TraceId,
ApiResultIndex: ApiResultIndex,
ApiResultIndexInb: ApiResultIndexInb,
CustomerSysId: CustomerSysId,
data: data,
actiontype: actiontype,
tripType: tripType
},
beforeSend: function() {
$('.continue_btn').hide();
$('.paynow_btn').hide();
$("#FareChangeData").html('<div style="text-align:center;padding-top:30px;"><img src="<?php echo $baseUrl; ?>public/images/loader.gif"/></div>');
},
success: function(data) {
if (data.success) {
$('.continue_btn').show();
$('.paynow_btn').show();
$("#FareChangeData").html(data.html);
$("#intPublishedFare").html(data.MobilePublishedFare);
$("#MobilePublishedFare").html(data.MobilePublishedFare);
} else {
alert(data.message);
}
}
});
}
function UpdateFareNew(actiontype, index, CustomerSysId, segmentid) {
var ApiResultIndex = $('#ApiResultIndex').val();
var ApiResultIndexInb = $('#ApiResultIndexInb').val();
var TraceId = $('#TraceId').val();
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/updatefare",
dataType: 'json',
data: {
TraceId: TraceId,
ApiResultIndex: ApiResultIndex,
ApiResultIndexInb: ApiResultIndexInb,
CustomerSysId: CustomerSysId,
actiontype: actiontype,
index: index,
segmentid: segmentid
},
beforeSend: function() {
$('.continue_btn').hide();
$('.paynow_btn').hide();
$("#FareChangeData").html('<div style="text-align:center;padding-top:30px;"><img src="<?php echo $baseUrl; ?>public/images/loader.gif"/></div>');
},
success: function(data) {
if (data.success) {
$('.continue_btn').show();
$('.paynow_btn').show();
$("#FareChangeData").html(data.html);
$("#intPublishedFare").html(data.MobilePublishedFare);
$("#MobilePublishedFare").html(data.MobilePublishedFare);
} else {
alert(data.message);
}
}
});
}
$(document).on('change', '.SelectBaggage', function() {
var element = $("option:selected", this);
var index = element.attr("value");
var CustomerSysId = element.attr("id");
var segmentid = element.attr("segmentid");
UpdateFareNew('baggage', index, CustomerSysId, segmentid);
});
$(document).on('change', '.SelectMeals', function() {
var element = $("option:selected", this);
var index = element.attr("value");
var CustomerSysId = element.attr("id");
var segmentid = element.attr("segmentid");
UpdateFareNew('meal', index, CustomerSysId, segmentid);
});
function SelectMeal(index, CustomerSysId, tripType) {
$('.removeBaggage').css('display', 'none');
var Mealdata = JSON.parse(GetData('Mealdata'));
console.log(Mealdata);
$.each($(".restMeal_" + CustomerSysId), function() {
var $input = $(this);
if (index + '_' + CustomerSysId == $input.attr('index')) {
$('#meal_' + index + '_' + CustomerSysId).addClass('checked');
} else {
$('#meal_' + $input.attr('index')).removeClass('checked');
}
});
$('#Meal_' + index + '_' + CustomerSysId).css('display', 'block');
//console.log(Mealdata[0][index]);return false;
UpdateFare(Mealdata[0][index], 'meal', CustomerSysId, tripType);
}
function SelectMealInb(index, CustomerSysId, tripType) {
var Mealdata = JSON.parse(GetData('Mealdata'));
$.each($(".restMealInb_" + CustomerSysId), function() {
var $input = $(this);
if (index + '_' + CustomerSysId == $input.attr('index')) {
$('#mealInb_' + index + '_' + CustomerSysId).addClass('checked');
} else {
$('#mealInb_' + $input.attr('index')).removeClass('checked');
}
});
$('#MealInb_' + index + '_' + CustomerSysId).css('display', 'block');
UpdateFare(Mealdata[1][index], 'meal', CustomerSysId, tripType);
}
function SelectBaggage(index, CustomerSysId, tripType) {
$('.removeBaggage').css('display', 'none');
var Baggagedata = JSON.parse(GetData('Baggagedata'));
$.each($(".restBaggage_" + CustomerSysId), function() {
var $input = $(this);
if (index + '_' + CustomerSysId == $input.attr('index')) {
$('#baggage_' + index + '_' + CustomerSysId).addClass('checked');
} else {
$('#baggage_' + $input.attr('index')).removeClass('checked');
}
});
$('#Baggage_' + index + '_' + CustomerSysId).css('display', 'block');
///console.log(Baggagedata[index]);return false;
UpdateFare(Baggagedata[0][index], 'baggage', CustomerSysId, tripType);
}
function SelectBaggageInb(index, CustomerSysId, tripType) {
var Baggagedata = JSON.parse(GetData('Baggagedata'));
$.each($(".restBaggageInb_" + CustomerSysId), function() {
var $input = $(this);
if (index + '_' + CustomerSysId == $input.attr('index')) {
$('#baggageInb_' + index + '_' + CustomerSysId).addClass('checked');
} else {
$('#baggageInb_' + $input.attr('index')).removeClass('checked');
}
});
$('#BaggageInb_' + index + '_' + CustomerSysId).css('display', 'block');
UpdateFare(Baggagedata[1][index], 'baggage', CustomerSysId, tripType);
}
$(document).on('click', '.removeBaggage', function() {
var CustomerSysId = $(this).attr('data');
var segment = $(this).attr('segment');
var type = $(this).attr('type');
var data = $(this).attr('data');
var index = $(this).attr('index');
var id = $(this).attr('id');
var Mealdata = JSON.parse(GetData('Mealdata'));
var Baggagedata = JSON.parse(GetData('Baggagedata'));
console.log(Mealdata);
//var index = element.attr("value");
var TraceId = $('#TraceId').val();
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/removebaggage",
dataType: 'json',
data: {
CustomerSysId: CustomerSysId,
segment: segment,
type: type,
},
beforeSend: function() {
$('.continue_btn').hide();
},
success: function(data) {
if (data.success) {
if (type == "Baggage") {
UpdateFare(Mealdata[0][index], 'meal', CustomerSysId, data);
}
if (type == "Meal") {
UpdateFare(Baggagedata[0][index], 'baggage', CustomerSysId, data);
}
$('#' + id).css('display', 'none');;
//window.location.href = 'flight/add-onn-service/' + TraceId;
// window.location.href = 'flight/travellers/' + TraceId;
}
}
});
});
function GetData(key) {
// alert(key);
var sonuc = "";
if (typeof(localStorage) != "undefined") {
//İkinci html5 localStorage desteği varmı ona bakılır
if (localStorage[key] != null) {
sonuc = localStorage[key];
}
} else {
//son olarak cookie desteği varmı ona bakılır
sonuc = $.cookie(key);
}
return sonuc;
}
<?php
if (($modulename == 'default') && ($controller == 'flight') && ($action == 'book-flight')) {
?>
function GenerateTicket() {
var ApiResultIndex = $('#ApiResultIndex').val();
var TraceId = $('#TraceId').val();
var SecCode = $('#SecCode').val();
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/book-flight/" + TraceId + '/' + SecCode,
dataType: 'json',
data: {
TraceId: TraceId,
ApiResultIndex: ApiResultIndex
},
beforeSend: function() {
$('.continue_btn').hide();
$("#FareChangeData").html('<div style="text-align:center;padding-top:30px;"><img src="<?php echo $baseUrl; ?>public/images/loader.gif"/></div>');
},
success: function(data) {
if (data.success) {
if (data.IsLCC) {
GenerateNonLccTicket();
} else {
window.location.href = 'flight/booking-confirmed?status=true';
}
} else {
alert(data.message);
window.location.href = 'flight';
}
}
});
}
function GenerateNonLccTicket() {
var ApiResultIndex = $('#ApiResultIndex').val();
var TraceId = $('#TraceId').val();
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/generatenonlccticket",
dataType: 'json',
data: {
TraceId: TraceId,
ApiResultIndex: ApiResultIndex
},
beforeSend: function() {
$(".Pleasewaitmesg").html('Please do not refresh or press back button, we are generating your ticket....');
},
success: function(data) {
if (data.success) {
window.location.href = 'flight/booking-confirmed';
} else {
alert(data.message);
window.location.href = 'flight';
}
}
});
}
GenerateTicket();
<?php } ?>
<?php
if (($modulename == 'default') && ($controller == 'flight') && ($action == 'pay-now')) {
?>
function PayNowTicket() {
var PaymentGateway = '<?= $currentPaymentGateway ?>';
var ApiResultIndex = $('#ApiResultIndex').val();
var TraceId = $('#TraceId').val();
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/pay-now/" + TraceId,
dataType: 'json',
data: {
TraceId: TraceId,
ApiResultIndex: ApiResultIndex
},
beforeSend: function() {
$('.continue_btn').hide();
$("#FareChangeData").html('<div style="text-align:center;padding-top:30px;"><img src="<?php echo $baseUrl; ?>public/images/loader.gif"/></div>');
},
success: function(response) {
if (response.success) {
var guid = response.guid;
var walletCode = response.walletCode;
var stringData = response.stringData;
var strReturnURL = response.strReturnURL;
var TPSysId = response.TPSysId;
var amount = response.amount;
var name = response.UserData.name;
var emailId = response.UserData.email;
var mobile = response.UserData.mobile;
var CustomerSysId = response.UserData.CustomerSysId;
var lastInsertId = response.lastInsertId;
var FLBookingID = response.FLBookingID;
$("#guid").val(guid);
$("#securecode").val(walletCode);
$("#returnURL").val(strReturnURL);
$("#errorURL").val(strReturnURL);
$("#stringData").val(stringData);
$("#TPSysId").val(TPSysId);
$("#premium_val").val(amount);
$("#custFirstname").val(name);
$("#custemail").val(emailId);
$("#custphone").val(mobile);
$("#CustomerSysId").val(CustomerSysId);
$("#lastInsertId").val(lastInsertId);
$("#FLBookingID").val(FLBookingID);
if (PaymentGateway == 'RAZORPAY') {
$.ajax({
url: '<?php echo $baseUrl; ?>payment/razor-pay',
type: 'post',
data: $("form#paymentsubmit").serialize(),
dataType: 'json',
success: function(response) {
if (response.razor) {
var options = response.razorData;
options.handler = function(response) {
document.getElementById('razorpay_payment_id').value = response.razorpay_payment_id;
document.getElementById('razorpay_signature').value = response.razorpay_signature;
document.getElementById('razorpay_order_id').value = response.razorpay_order_id;
document.razorpayform.submit();
};
options.theme.image_padding = false;
var rzp = new Razorpay(response.razorData);
rzp.open();
e.preventDefault();
}
}
});
} else {
setTimeout(function() {
$("#paymentsubmit").submit();
}, 2000);
}
} else {
alert(response.message);
window.location.href = 'flight';
}
}
});
}
PayNowTicket();
<?php } ?>
function removepax() {
}
$(document).on('click', '.removePax', function() {
var CustomerSysId = $(this).attr('value');
var b = $(this).attr('data');
$("#custMember_" + CustomerSysId).removeAttr('disabled', 'disabled');
$("#custMember_" + CustomerSysId).removeAttr('checked', 'checked');
$("#CustomerSysId-" + b).val('0');
$("#passenger-firstname-" + b).val('');
$("#passenger-lastname-" + b).val('');
$("#travellerdetails" + b).val('');
$("#dateofbirth-" + b).val('');
$("#travel_details" + b).html('');
$("#relation-" + b).val('0');
$("#passportno-" + b).val('');
$("#passportnoexpiry-" + b).val('');
$("#CRADULT-" + b).hide();
});
$(document).on('click', '.mobile_info', function() {
$('#myModal_faresummary').modal('show');
});
$('.ClearAll').click(function() {
var checked = $('.filter-box input[type="checkbox"]:checked').length;
if (checked >= 1) {
$('.filter-box input[type="checkbox"]:checked').trigger('click');
}
});
Tipped.delegate('#BaseFarePOPBreackUp', {
inline: 'BaseFareBreackUp',
radius: true,
hideOnClickOutside: true,
});
Tipped.delegate('#FeeSurchargeBreakUp', {
inline: 'FeeSurcharge',
radius: true,
hideOnClickOutside: true,
});
// Tipped.delegate('#MobileToolTipesBreakUp', {
// inline: 'FareBreakUpMobileDiv',
// radius: true,
// hideOnClickOutside: true,
// });
Tipped.delegate('#MobileToolTipesBreakUp', {
cache: false,
ajax: {
url: '<?php echo $baseUrl; ?>flight/farebreackupmobile',
data: {
item: 'item'
},
type: 'post'
},
radius: true,
position: 'topleft',
size: 'large'
});
$(document).on('click', '.GetFareRules', function() {
var IsLCC = $(this).attr('IsLCC');
var index = $(this).attr('index');
var TraceId = $(this).attr('TraceId');
var ApiResultIndex = $(this).attr('ApiResultIndex');
var ICSourceSysId = $(this).attr('ICSourceSysId');
// alert(ICSourceSysId);
$('#myModal_viewmore').modal('show');
$.ajax({
type: "POST",
url: "<?php echo $baseUrl; ?>flight/getflightfarerules",
dataType: 'html',
data: {
TraceId: TraceId,
ApiResultIndex: ApiResultIndex,
IsLCC: IsLCC,
ICSourceSysId: ICSourceSysId
},
beforeSend: function() {
$("#FareRulesDiv").html('<div style="text-align:center;padding-top:30px;"><img src="<?php echo $baseUrl; ?>public/images/loader.gif"/></div>');
},
success: function(data) {
// console.log(data);
$("#FareRulesDiv").html(data);
}
});
});
function SetData(key, value) {
if (typeof(localStorage) != "undefined") {
//ikinci önce html5 localStorage desteği varmı ona bakılır
try {
localStorage.setItem(key, value);
return true;
} catch (e) {
return false;
}
} else {
//son olarak cookie desteği varmı ona bakılır
try {
$.cookie(key, value);
return true;
} catch (e) {
return false;
}
}
}
</script>
<script>
// Get the modal
var modal = document.getElementById('id02');
// When the user clicks anywhere outside of the modal, close it
window.onclick = function(event) {
if (event.target == modal) {
modal.style.display = "none";
}
}
$(document).ready(function() {
setTimeout(function() {
$("#rightFloatInTollFreeNumber").stop().animate({
right: 215
}, 215);
}, 4000);
setInterval(function() {
$("#rightFloatInTollFreeNumber").stop().animate({
right: 50
}, 215);
}, 10000);
$('.rightFloat div').mouseover(function() {
$(this).stop().animate({
right: 215
}, 215);
}).mouseout(function() {
$(this).stop().animate({
right: 50
}, 215)
});
});
</script>
<script>
$("document").ready(function() {
$(".tab-slider--body").hide();
$(".tab-slider--body:first").show();
});
$(".tab-slider--nav li").click(function() {
$(".tab-slider--body").hide();
var activeTab = $(this).attr("rel");
$("#" + activeTab).fadeIn();
if ($(this).attr("rel") == "tab2") {
$('.tab-slider--tabs').addClass('slide');
} else {
$('.tab-slider--tabs').removeClass('slide');
}
$(".tab-slider--nav li").removeClass("active");
$(this).addClass("active");
});
</script>
<script type="text/javascript">
if (dvc == "d") {
function fixDiv() {
if ($(window).scrollTop() > 420) {
//console.log($(window).scrollTop());
$('#topview1212').css({
'z-index': '99999',
'position': 'fixed',
'top': '118px',
'margin-left': '0px',
'width': '31%'
});
} else {
$('#topview1212').css({
'z-index': '999',
'position': 'initial',
'top': 'inherit',
'width': '100%'
});
}
}
} else {
function fixDiv() {
if ($(window).scrollTop() > 100) {
console.log($(window).scrollTop());
$('.fh5co-nav-toggle').css({
'top': '1%'
});
} else {
$('.fh5co-nav-toggle').css({
'top': '8%'
});
}
}
}
$(window).scroll(fixDiv);
</script>
<script>
$(document).ready(function() {
$('[data-toggle="tooltip"]').tooltip();
});
</script>
<script>
function showPopFilterMob(that) {
$('.filters-container').hide();
$('#package-filters').show();
$('#myModalFiltersContainer').modal('show');
}
</script>
<script src="public/js/sliderResponsive.js"></script>
<script>
$(document).ready(function() {
$("#slider3").sliderResponsive({
hoverZoom: "off",
hideDots: "off",
showArrows: "off"
});
});
function modifySearch() {
$("#modifySearch").toggleClass("modifySearch");
}
</script>
<script>
$(function() {
var icons = {
header: "ui-icon-circle-arrow-e",
activeHeader: "ui-icon-circle-arrow-s"
};
$("#accordion").accordion({
icons: icons
});
});
</script>
<script>
$(".readmore-link").click(function(e) {
// record if our text is expanded
var isExpanded = $(e.target).hasClass("expand");
//close all open paragraphs
$(".readmore.expand").removeClass("expand");
$(".readmore-link.expand").removeClass("expand");
// if target wasn't expand, then expand it
if (!isExpanded) {
$(e.target).parent(".readmore").addClass("expand");
$(e.target).addClass("expand");
}
});
// $.when(FlightFareQuote()).done(function(ajax1Results) {
$(document).ready(function() {
$('.continue_btn1').click(function() {
var leadmbile = $('#leadMobile').val();
var leademail = $('#leadEmail').val();
if (leadmbile == "") {
alert("Please Enter Mobile Number");
$('#accordion').accordion('option', 'active', 0)
return false;
}
if (leademail == "") {
alert("Please Enter Email Id");
$('#accordion').accordion('option', 'active', 0)
return false;
}
});
$("#ui-id-4, #ui-id-6, #ui-id-8").unbind("click");
});
//});
</script>
<script>
function myFunction(id) {
}
</script>
<?php if (($modulename == 'default') && ($controller == 'flight') && ($action == 'flight-search')) {
?>
<?php // if ($mydevice == "mobile"){
?>
<script type="text/javascript">
window.onbeforeunload = function(e) {
e.preventDefault();
}
</script>
<?php //}
?>
<?php } ?>
<?php if ($mydevice == "mobile") { ?>
<script>
$("#gststate").focus(function() {
$(window).scrollTop($("#gststate").offset().top - 20);
});
$(".travellerinput").focus(function() {
$(window).scrollTop($(".travellerinput").offset().top - 20);
});
$(".travellermobile-cls").focus(function() {
$(window).scrollTop($(".travellermobile-cls").offset().top - 20);
});
function myFunction(id) {
$(window).scrollTop($("." + id).offset().top);
}
</script>
<?php } else { ?>
<script>
function myFunction(id) {
}
</script>
<?php } ?>
</body>
<?php
echo $seoFContent = (isset($detailLayout['seoFcontent']) && $detailLayout['seoFcontent'] != '') ? $detailLayout['seoFcontent'] : '';
?>
<script type="text/javascript">
let sessTimeout = 900000;
function sessionshow() {
$('#sessionModal').modal({
backdrop: 'static',
keyboard: true,
show: true
});
}
var myTimeOut = setTimeout(sessionshow, sessTimeout);
$("body").click(function(event) {
// alert('manish');
clearTimeout(myTimeOut);
// console.log('clicked');
myTimeOut = setTimeout(sessionshow, sessTimeout);
});
</script>
<!-- Modal -->
<!-- <div class="modal fade" id="sessionModal" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="exampleModalLabel">Session Timeout</h5> -->
<!-- <button type="button" class="close" data-dismiss="modal" aria-label="Close">-->
<!-- <span aria-hidden="true">×</span>-->
<!-- </button>-->
<!-- </div>
<div class="modal-body">
<div style="text-align: center;"><img src="<?php echo $baseUrl; ?>public/images/stop_emoji.png" /> </div>
<div class="text_sesion" style="text-align: center;margin-top: 10px;">Are you still here? Please get back to home page and browse again!</div>
</div>
<div class="modal-footer">
<a href="<?php echo $baseUrl; ?>">
<button type="button" class="btn btn-primary getback">Get Back</button>
</a>
</div>
</div>
</div>
</div> -->
</html>
<?php } ?>