Rev 22214 | Blame | Compare with Previous | Last modification | View Log | RSS feed
<script type="text/javascript" src="/js/checkout.js?v=<?php echo $staticversion;?>"></script><script type="text/javascript" src="/js/jquery-ui.min.js "></script><script type="text/javascript">$(document).ready(function(){var alpad = " "+($('#footer').height()-45)+"px";$('#addresslist').css("margin-bottom",alpad);/*if($('.myaddress').hasClass('addressselect')){var pin_val = $('.addressselect').data('pinval');$.ajax({method: "GET",url: "<?php echo $base_url;?>shippings/getstate/"+pin_val,},'json').done(function(msg){msg = eval('('+msg+')');if(msg['state'].trim() == "Delhi"){$(".taxbanner").removeClass('hidden');}});}*/var cart_details = localStorage.getItem("cart_details");if(cart_details == undefined){$('span#totalPayable').text(' ₹ 0');$('button.confirmcheckout').prop( "disabled", true );$('.confirmprepaid').addClass('confirmprepaidDisabled').removeClass('confirmprepaid');$('button.confirmcredit').prop( "disabled", true );$('button.confirmcod').prop( "disabled", true );$('span#CreditError').html('');}else{$('button.confirmcheckout').prop( "disabled", false );$('.confirmprepaidDisabled').addClass('confirmprepaid').removeClass('confirmprepaidDisabled');$('button.confirmcredit').prop( "disabled", false );$('button.confirmcod').prop( "disabled", false );}totalPayable = <?php echo $totalPayable;?>;walletAmount = <?php echo $walletAmount;?>;walletPayable = Math.min(totalPayable, walletAmount);walletUsed = 0;localStorage.removeItem('totalPayable');localStorage.setItem('totalPayable', totalPayable);localStorage.removeItem('walletAmount');localStorage.setItem('walletAmount', walletAmount);if (window.history && window.history.pushState) {$(window).on('popstate', function() {$('#myModal').modal('hide');$("#cartloader").addClass('hidden');if(typeof history.checkoutForm != "undefined"){history.checkoutForm.submit();}});}});</script><link rel="stylesheet" href="/css/hexdots.css" type="text/css"><style>#footer {position: fixed;/*height:50px;*//*background-color:red;*/bottom: 0px;left: 0px;right: 0px;margin-bottom: 0px;}#message,#message_success {position: fixed;/*height:50px;*//*background-color:red;*//*background-color: white;*/top: 0px;left: 0px;right: 0px;margin-top: 0px;z-index: 10;}.addressselect {background-color: #D9FACF;}input[type=radio].css-checkbox {position: absolute;z-index: -1000;left: -1000px;overflow: hidden;clip: rect(0, 0, 0, 0);height: 1px;width: 1px;margin: -1px;padding: 0;border: 0;}input[type=radio].css-checkbox+label.css-label {padding-left: 21px;padding-bottom: 10px;height: 16px;display: inline-block;line-height: 16px;background-repeat: no-repeat;background-position: 0 0;/*font-size:16px;*/vertical-align: middle;cursor: pointer;}input[type=radio].css-checkbox:checked+label.css-label {background-position: 0 -16px;}label.css-label {background-image: url(../img/radio.png);-webkit-touch-callout: none;-webkit-user-select: none;-khtml-user-select: none;-moz-user-select: none;-ms-user-select: none;user-select: none;}.custom_class {color: red;}#cartloader{position:absolute;/*top:40%;*/left:50%;z-index:2001;}</style><?phpif($message != null){?><script>$(document).ready(function(){$('#message').empty();$('#message').append("Location is not serviceable...");$('#message').removeClass('hidden');setTimeout(function() {$('#message').addClass('hidden');}, 2000);});</script><?php }?><div class="modal fade" id="loadingModal"><div class="modal-dialog"><div class="modal-content"><div class="modal-body"><div class="text-center"><img src="/img/ajax-loader.gif" /></div></div></div><!-- /.modal-content --></div><!-- /.modal-dialog --></div><divclass="alert alert-danger hidden" id="message"></div><divclass="alert alert-success hidden" id="message_success"></div><div class="text-center hidden" id="cartloader"><br><br><div class="hexdots-loader"></div></div><div class='container' style='margin-bottom: 50px;' id ="addresslist"><div class='row' style="padding-bottom: 55px;"><?php //if($stateres == "Delhi"):?><div class="taxbanner hidden" style="margin-top: 5px;"><a href="/tins"><img src = "../img/vat-tax.gif" width="100%"></a></div><?php //endif;?><div class='row'><div class='col-xs-12'style="background-color: white; margin-top: 5px;"><h4>Shipping Address: <ahref="<?php echo $base_url;?>shippings/add/<?php echo $user_name.'/'.$user_contact;?>"class='btn btn-success btn-xs' style='float: right;'>Add NewAddress</a></h4><br></div></div><div class='col-xs-12'style='background-color: white; padding: 40px; padding: 3px 20px;'><div style='background-color: #f8f8f8; padding: 5px;'><?phpfor($i=0;$i<count($firstshowaddress);$i++){?><?php if($i==3):?><div id='showmoreaddressdropdown' style='display: none;'><?php endif;?><?php //if(count($firstshowaddress)>$i):?><div style='min-height: 80px; padding: 4px;'id="address<?php echo $address['addresses'][$firstshowaddress[$i]]['id'];?>" data-pinval="<?php echo $address['addresses'][$firstshowaddress[$i]]['pin']; ?>"class='myaddress <?php if($defaultselectedaddress == $address['addresses'][$firstshowaddress[$i]]['id']){echo "addressselect";}?>'><input type="radio" class="css-checkbox"id='<?php echo $address['addresses'][$firstshowaddress[$i]]['id'];?>'value='<?php echo $address['addresses'][$firstshowaddress[$i]]['id'];?>'name="selectedaddress"<?php if($defaultselectedaddress == $address['addresses'][$firstshowaddress[$i]]['id']){echo "checked";}?>credit_available="false"><labelfor="<?php echo $address['addresses'][$firstshowaddress[$i]]['id'];?>"class="css-label radGroup2"data-pin="<?php echo $address['addresses'][$firstshowaddress[$i]]['pin'];?>"data-id="<?php echo $address['addresses'][$firstshowaddress[$i]]['id'];?>"credit_available="false"><?phpif(isset($address['addresses'][$firstshowaddress[$i]]['line1']) && !empty($address['addresses'][$firstshowaddress[$i]]['line1'])){echo "Address: ",$address['addresses'][$firstshowaddress[$i]]['line1'];}if(isset($address['addresses'][$firstshowaddress[$i]]['line2']) && !empty($address['addresses'][$firstshowaddress[$i]]['line2'])){echo ",",$address['addresses'][$firstshowaddress[$i]]['line2'];}if(isset($address['addresses'][$firstshowaddress[$i]]['city']) && !empty($address['addresses'][$firstshowaddress[$i]]['city'])){echo "<br>",$address['addresses'][$firstshowaddress[$i]]['city'];}if(isset($address['addresses'][$firstshowaddress[$i]]['state']) && !empty($address['addresses'][$firstshowaddress[$i]]['state'])){echo ", ",$address['addresses'][$firstshowaddress[$i]]['state'];}if(isset($address['addresses'][$firstshowaddress[$i]]['pin']) && !empty($address['addresses'][$firstshowaddress[$i]]['pin'])){echo ",",$address['addresses'][$firstshowaddress[$i]]['pin'];}?><br><?php if($taxInvoiceEnabledUser):?><?php if($address['addresses'][$firstshowaddress[$i]]['taxInvoiceAvailable']):?><i class="glyphicon glyphicon-info-sign" style="font-size: 10px;color: #42A150;"><span style="color: #42A150;font-size: 10px;font-family: "Helvetica Neue",Helvetica,Arial,sans-serif;">Tax Invoice Available</span></i><?php endif;?><?php endif;?></label></div><hr style='margin: 0px; padding: 0px; border-color: #58d936;'><?php //endif;?><?php if($i>3 && $i==(count($firstshowaddress)-1)):?></div><!-- <center><button class='btn btn-default btn-xs' id='showmore'>Show More</button></center> --><?php endif;?><?php }?></div></div><?php if(count($firstshowaddress)>3):?><center><div class='btn btn-default btn-xs' id='showmore'>Show More</div></center><?php endif;?></div><!-- End of address section --><div class="modal fade" id="myModal"><div class="modal-dialog"><div class="modal-content"style="background-color: #f0f0f0; color: #555;"><div class="modal-body"><p id="confirmOrderText" addressId="" checkoutType="" style="color: #555;" class="text-center"></p></div><div class="modal-footer"><button type="button" class="btn btn-md pull-left" id="changeOption"style="background-color: #58d936; color: #fff;"><strong>Change Option<br>(विकल्प बदलें)</strong></button><button type="button" class="btn btn-md pull-right"id="orderNow" style="background-color: #58d936; color: #fff;"><strong>Order Now<br>(अभी खरीदें)</strong></button></div></div><!-- /.modal-content --></div><!-- /.modal-dialog --></div><!-- /.modal --><!-- Cart section started --><div class="row" style="padding: 0px;" id="footer"><div class="col-xs-12" style="background-color: white; padding: 10px 20px 20px 20px; width: 100%;"><h5 style="margin: 0px; margin-bottom: 6px;">Total payable Amount: <span style="color: #ff0000;" id="totalPayable"> ₹<?php echo number_format($totalPayable);?></span></h5><?php if($walletAmount > 0):?><?php if($walletAmount < $totalPayable): ?><div style="margin: 0px; margin-bottom: 6px;"><a href="javascript:void(0);" style="font-size: 12px;width:97px" class="usewallet btn btn-success btn-xs">Use Wallet</a><span id="walletAmount">(₹<?php echo number_format($walletAmount);?>)</span></div><h5 id="netpayable" style="margin: 0px; margin-bottom: 6px; visibility:hidden;">Net payable Amount: <span style="color: #ff0000;padding-left:9px" id="totalPayable"> ₹<?php echo number_format($totalPayable - $walletAmount);?></span></h5><?php if($codAvailable):?><!--<a href="#" style="padding-right: 2px; color: blue; font-size: 15px;" class="confirmprepaid"><u>Other Pay Option</u></a>--><button class="btn btn-success confirmcheckout pull-right">Confirm Order via COD</button><?php else:?><span style='padding-right: 2px; color: red; font-size: 15px;'>*COD Not Available</span><!--<button class="btn btn-success confirmprepaid pull-right">Other Pay Option</button>--><?php endif;?><?php else:?><?php if($codAvailable):?><div class="col-xs-12" style="margin-left: 20px;"><!--<div class="col-xs-4"><button type="button" class="btn btn-md confirmprepaid"style="margin: 10px 20px 0px 0px; background-color: #5cb85c; color: #fff;">Other</button><br><span style="font-size: 8px;"> <span style="color:#ff0000;font-size:12px;"> </span></span></div>--><div class="col-xs-6"><button type="button" class="btn btn-md confirmcod"style="margin: 10px 20px 0px 0px; background-color: #5cb85c; color: #fff;">COD</button><br><span style="font-size: 8px;"> <span style="color:#ff0000;font-size:12px;"> </span></span></div><div class="col-xs-6" style="padding:0px;"><button type="button" class="btn btn-md confirmwallet"style="margin: 10px 20px 0px 0px; background-color: #5cb85c; color: #fff;">Use Wallet</button><br><span style="font-size: 8px;">Wallet Amount<span style="color:#ff0000;font-size:12px;"> ₹ <?php echo number_format($walletAmount);?></span></span></div></div><?php else:?><div class="col-xs-12" style="margin-left: 20px;"><div class="col-xs-4"><spanstyle='padding-right: 2px; color: red; font-size: 12px; " margin: 0px 10px 0px 0px;'>*CODNot Available</span></div><div class="col-xs-4"><button type="button" class="btn btn-md confirmprepaid"style="margin: 10px 20px 0px 0px; background-color: #5cb85c; color: #fff;">Other</button></div><div class="col-xs-4" style="padding:0px;"><button type="button" class="btn btn-md confirmwallet"style="margin: 10px 20px 0px 0px; background-color: #5cb85c; color: #fff;padding-right: 30px;padding-left: 30px;">Wallet</button><br><span style="font-size: 8px;">Wallet Amout<span style="color:#ff0000;font-size:12px;"> ₹ <?php echo number_format($walletAmount);?></span></span></div></div><?php endif;?><?php endif;?><?php else:?><div style="margin: 0px; margin-bottom: 6px;"><?php if($codAvailable):?><!--<a href="#" style="padding-right: 2px; color: blue; font-size: 15px;" class="confirmprepaid"><u>Other Pay Option</u></a>--><button class="btn btn-success confirmcheckout pull-right">Confirm Order via COD</button><?php else:?><span style='padding-right: 2px; color: red; font-size: 15px;'>*COD Not Available</span><!--<button class="btn btn-success confirmprepaid pull-right">Other Pay Option</button>--><?php endif;?></div><?php endif;?></div></div><!-- Cart section end --></div>