<?php echo $header; ?>
<style>
.Qty + .input-group {display: flex;}
.Qty + .input-group input {width: 42px;}
.color-red {
color:Red;
}
.breadcrumb {
padding-top: 20px !important;
}
</style>
<div class="container">
<ul class="breadcrumb">
<?php foreach ($breadcrumbs as $breadcrumb) { ?>
<li><a href="<?php echo $breadcrumb['href']; ?>"><?php echo $breadcrumb['text']; ?></a></li>
<?php } ?>
</ul>
<?php if ($success) { ?>
<div class="alert alert-success"><i class="fa fa-check-circle"></i> <?php echo $success; ?>
<button type="button" class="close" data-dismiss="alert">&times;</button>
</div>
<?php } ?>
<?php if ($error_warning) { ?>
<div class="alert alert-danger"><i class="fa fa-exclamation-circle"></i> <?php echo $error_warning; ?>
<button type="button" class="close" data-dismiss="alert">&times;</button>
</div>
<?php } ?>
<div class="row"><?php echo $column_left; ?>
<?php if ($column_left && $column_right) { ?>
<?php $class = 'col-sm-6'; ?>
<?php } elseif ($column_left || $column_right) { ?>
<?php $class = 'col-sm-9'; ?>
<?php } else { ?>
<?php $class = 'col-sm-12'; ?>
<?php } ?>
<div id="content" class="<?php echo $class; ?>"><?php echo $content_top; ?>
<h1><?php echo $heading_title; ?></h1>
<div class="col-sm-10 col-sm-offset-1 col-xs-12">
<form method="POST" action="<?= $action_return; ?>" enctype="multipart/form-data" id="form-order">
<!-- . -->
<style>
.SiparisGecmisi {
display: inline-block;
margin: -20px 0 20px;
width: 100%;
}
.SiparisGecmisi h3 {
font-family: Quicksand;
font-style: normal;
font-weight: bold;
font-size: 18px;
color: #000;
}
.SiparisGecmisi span {
text-decoration: underline;
font-family: Quicksand;
font-style: normal;
font-weight: bold;
font-size: 18px;
color: #EB5757; /* #219653 */
}
</style>
<span class="SiparisGecmisi">
<h3><?= $text_history; ?></h3>
<span><?= $histories [(count ($histories) - 1)]['status']; ?></span><br/>
<span><?= $histories [(count ($histories) - 1)]['comment']; ?></span><br/>
<span><?= $histories [(count ($histories) - 2)]['comment']; ?></span>
</span>

<!-- . -->
<!-- . -->
<? if ($payment_address): ?>
<style>
.FaturaAdresi {
display: inline-block;
width: 100%;
}
.FaturaAdresi h3 {
font-family: Quicksand;
font-style: normal;
font-weight: 600;
font-size: 14px;
width: 100%;
color: #000;
}
.FaturaAdresi span {
border: 1px solid #BDBDBD;
box-sizing: border-box;
font-family: Quicksand;
display: inline-block;
font-style: normal;
border-radius: 3px;
padding: 15px 20px;
font-weight: bold;
font-size: 14px;
color: #4F4F4F;
width: 100%;
}
</style>
<span class="FaturaAdresi">
<h3><?= $text_payment_address; ?></h3>
<span><?= $payment_address; ?></span>
</span>
<? endif; ?>
<!-- . -->
<!-- . -->
<? if ($shipping_address): ?>
<style>
.TeslimatAdresi {
display: inline-block;
width: 100%;
}
.TeslimatAdresi h3 {
font-family: Quicksand;
font-style: normal;
font-weight: 600;
font-size: 14px;
color: #000;
}
.TeslimatAdresi h3 a.TeslimatAdresiDuzenle {
margin: -5px 0 0 5px;
padding: 3px 5px;
}
.TeslimatAdresi span {
border: 1px solid #BDBDBD;
box-sizing: border-box;
font-family: Quicksand;
display: inline-block;
font-style: normal;
border-radius: 3px;
padding: 15px 20px;
font-weight: bold;
font-size: 14px;
color: #4F4F4F;
width: 100%;
}
</style>
<span class="TeslimatAdresi">
<h3><?= $text_shipping_address; ?> <a class="TeslimatAdresiDuzenle btn btn-success btn-sm" href="<?= $edit_shipping_address; ?>"><i class="fa fa-pencil"></i></a></h3>
<span><?= $shipping_address; ?></span>
</span>
<? endif; ?>
<!-- . -->
<!-- . -->
<style>
.SiparisDetaylari {
display: inline-block;
margin-top: 20px;
width: 100%;
}
.SiparisDetaylari h3 {
font-family: Quicksand;
font-style: normal;
font-weight: 600;
font-size: 14px;
color: #000;
}
.SiparisDetaylari ul {
border: 1px solid #BDBDBD;
background-color: #F2F2F2;
box-sizing: border-box;
font-family: Quicksand;
display: inline-block;
font-style: normal;
border-radius: 3px;
padding: 15px 20px;
font-weight: bold;
font-size: 14px;
color: #4F4F4F;
width: 100%;
}
.SiparisDetaylari ul li {
border-bottom: solid 1px #BDBDBD;
font-family: Quicksand;
list-style-type: none;
padding: 15px 0;
color: #000;
}
.SiparisDetaylari ul li:last-child {
border-bottom: none;
}
.SiparisDetaylari ul li span {
float: right;
}
</style>
<span class="SiparisDetaylari">
<h3><?= $text_order_detail; ?></h3>
<ul>
<? if ($invoice_no): ?>
<li><b><?= $text_invoice_no; ?></b> <span><?= $invoice_no; ?></span></li>
<? endif; ?>
<? if ($order_id): ?>
<li><b><?= $text_order_id; ?></b> <span>#<?= $order_id; ?></span></li>
<? endif; ?>
<? if ($date_added): ?>
<li><b><?= $text_date_added; ?></b> <span><?= $date_added; ?></span></li>
<? endif; ?>
<? if ($payment_method): ?>
<li><b><?= $text_payment_method; ?></b> <span><?= $payment_method; ?></span></li>
<? endif; ?>
<? if ($shipping_method): ?>
<li><b><?= $text_shipping_method; ?></b> <span><?= $shipping_method; ?></span></li>
<? endif; ?>
</ul>
</span>
<!-- . -->
<!-- . -->
<style>
.Urunler {
width: 100%;
}
.Urunler .Urun {
border-bottom: solid 1px #BDBDBD;
padding: 20px 0;
width: 100%;
}
.Urunler .Urun:last-child {
border-bottom: none;
}
.Urunler .Urun .Opsiyon {
padding-left: 20px;
}
.Urunler .Urun .TemelFiyat {
font-family: Quicksand;
font-style: normal;
font-weight: 600;
font-size: 14px;
color: #162025;
}
.Urunler .Urun .Baslik {
font-family: Quicksand;
font-style: normal;
font-weight: 500;
font-size: 14px;
color: #4F4F4F;
}
.Urunler .Urun .Qty {
border: 1px solid #BDBDBD;
font-family: Quicksand;
text-align: center;
font-size: 16px;
color: #828282;
height: 40px;
width: 40px;
}
.Urunler .Urun .Degisim {
background-color: #FFF;
font-family: Quicksand;
font-style: normal;
box-shadow: none;
font-weight: 600;
margin-top: 7px;
font-size: 18px;
color: #EB5757;
border: none;
padding: 0;
}
.Urunler .Urun .Degisim i {font-size: 16px;}
.Urunler .Urun .Fiyat {
font-family: Quicksand;
font-style: normal;
font-weight: 500;
font-size: 14px;
color: #162025;
}
@media (max-width: 768px)
{
.Urunler {
min-width: 200vw;
}
.Urunler .Urun {}
}
</style>
<div class="table-responsive" style="width: 100%;">
<table class="Urunler">
<? foreach ($products as $product): ?>
<tr class="Urun">
<td class="Opsiyon">
<?php if($product['return_check']){ ?>
<input type="checkbox" name="product_item[]" value="<?= $product ['order_product_id']; ?>" data-checkbox="checkbox_text" class="product_return_checkbox"/>
<?php } else { ?>
<a href="javascript:;" data-toggle="tooltip" title="<?=$product['tooltip_message'];?>">
<i class="fa fa-info"></i>
</a>
<?php } ?>
</td>
<td class="text-center">
<br /><br />
<? if ($product ['case_pattern_image']): ?>
<img src="<?= $product ['case_pattern_image']; ?>" alt="" />
<? elseif ($product ['customcase_image']): ?>
<img height="111" src="<?php echo $product['case_image']; ?>" alt="Frame" style="position: absolute;" />
<img height="111" src="<?php echo $product['customcase_image']; ?>" alt="" />
<? endif; ?>
<br /><br /><br />
</td>
<td class="text-left">
<span class="TemelFiyat"><?= $product['price']; ?></span>
<br />
<span class="Baslik"><?= $product ['name']; ?></span>
<? foreach ($product ['option'] as $option): ?>
<br />
<small> - <?= $option ['name']; ?>: <?= $option ['value']; ?></small>
<? endforeach; ?>
<br />
<?php if($product ['change_check']){ ?>
<a href="<?= $product ['return']; ?>" data-toggle="tooltip" title="Değişim" class="Degisim btn"><i class="fa fa-refresh"></i> Değişim </a>
<?php } ?>
</td>
<td>
<input class="Qty quantity_text_<?= $product ['order_product_id']; ?>" type="text" name="quantity[<?= $product ['order_product_id']; ?>][]"  data-quantity="<?= $product ['order_product_id']; ?>" value="1" min="1" max="<?= $product ['quantity']; ?>" />
</td>
<td class="Fiyat"><?= $product['total']; ?></td>
</tr>
<? endforeach; ?>
</table>
</div>
<!-- . -->
<!-- . -->
<style>
.SiparisDetaylari {}
.SiparisDetaylari.SiparisDetaylari--2 {}
.SiparisDetaylari.SiparisDetaylari--2 ul {
border-bottom-right-radius: 0;
border-bottom-left-radius: 0;
}
</style>
<span class="SiparisDetaylari SiparisDetaylari--2">
<ul>
<? foreach ($vouchers as $voucher): ?>
<li><b><?= $voucher ['description']; ?></b> <span><?= $voucher ['amount']; ?></span></li>
<? endforeach; ?>
<? foreach ($totals as $total): ?>
<li><b><?= $total ['title']; ?></b> <span><?= $total ['text']; ?></span></li>
<? endforeach; ?>
<!-- <input type="checkbox" class="" name="prefer_pay_coupon" /> İptal edilecek ürün tutarı kadar kupon hediyesi (Bu seçeneği işaretlerseniz iadeniz hediye kupon ile gerçekleşecektir.) -->
</ul>
</span>
<!-- . -->
<!-- . -->
<style>
.Dugmeler {
display: inline-block;
margin-top: -10px;
width: 100%;
}
.Dugmeler #return_button,
.Dugmeler a {
font-family: Quicksand;
letter-spacing: .7px;
font-style: normal;
font-weight: bold;
border-radius: 0;
font-size: 16px;
padding: 12px 0;
border: none;
width: 100%;
color: #FFF;
}
.Dugmeler #return_button {
background-color: #EB5757;
}
.Dugmeler a {
background-color: #000;
}
</style>
<!-- 14 workdays return control -->
<?php if($workdays_return_control){ ?>
<span class="Dugmeler">
<? if ($product_return_limit == 0): ?>
<?php if($order_cancel_status){ ?>
                        <div class="col-md-6" style="padding-right: 0px; padding-left: 0px; border-right: solid indianred;">
                            <button type="submit" class="btn btn-danger col-sm-2 return_button" name="cancel_button2" value="cancel" id="return_button" data-toggle="tooltip" title="Lütfen, iade kargonuzun içerisine; isim-soyisim ve sipariş numaranızı ekleyiniz.">Ücreti Kupon Olarak Tanımla<br> </button>
                        </div>
                        <div class="col-md-6" style="padding-right: 0px; padding-left: 0px;">
                            <button type="submit" style="padding: 12px 0;" class="btn btn-danger return_button" name="cancel_button" value="cancel" id="return_button" data-toggle="tooltip" title="Lütfen, iade kargonuzun içerisine; isim-soyisim ve sipariş numaranızı ekleyiniz.">Ücreti Kartıma Aktar</button>
                        </div>
                      <?php }else{ ?>
                        <div class="col-md-6" style="padding-right: 0px; padding-left: 0px; border-right: solid indianred;">
                            <button type="submit" class="btn btn-danger return_button" name="return_button2" value="return" id="return_button" data-toggle="tooltip" title="Lütfen, iade kargonuzun içerisine; isim-soyisim ve sipariş numaranızı ekleyiniz.">Ücreti Kupon Olarak Tanımla<br> </button>
                        </div>
                        <div class="col-md-6" style="padding-right: 0px; padding-left: 0px;">
                            <button type="submit" style="padding: 12px 0;" class="btn btn-danger return_button" name="return_button" value="return" id="return_button" data-toggle="tooltip" title="Lütfen, iade kargonuzun içerisine; isim-soyisim ve sipariş numaranızı ekleyiniz.">Ücreti Kartıma Aktar</button>
                        </div>
                      <?php } ?>
<? else: ?>
<?php if($order_cancel_status){ ?>
                            <?php if($payment_cod){ ?>
                                <div class="col-md-12" style="padding-right: 0px; padding-left: 0px;">
                                    <button type="submit" style="padding: 12px 0;" class="btn btn-danger return_button" name="cancel_button" value="cancel" id="return_button" data-toggle="tooltip" title="Lütfen, iade kargonuzun içerisine; isim-soyisim ve sipariş numaranızı ekleyiniz.">İptal Et</button>
                                </div>
                            <?php }else{ ?>
                                <div class="col-md-6" style="padding-right: 0px; padding-left: 0px; border-right: solid indianred;">
                                    <button type="submit" class="btn btn-danger return_button" name="cancel_button2" value="cancel" id="return_button" data-toggle="tooltip" title="Lütfen, iade kargonuzun içerisine; isim-soyisim ve sipariş numaranızı ekleyiniz." disabled>Ücreti Kupon Olarak Tanımla<br> </button>
                                </div>
                                <div class="col-md-6" style="padding-right: 0px; padding-left: 0px;">
                                    <button type="submit" style="padding: 12px 0;" class="btn btn-danger return_button" name="cancel_button" value="cancel" id="return_button" data-toggle="tooltip" title="Lütfen, iade kargonuzun içerisine; isim-soyisim ve sipariş numaranızı ekleyiniz." disabled>Ücreti Kartıma Aktar</button>
                                </div>
                            <?php } ?>
                      <?php }else{ ?>
                            <?php if($payment_cod){ ?>
                                <div class="col-md-12" style="padding-right: 0px; padding-left: 0px;">
                                    <button type="submit" style="padding: 12px 0;" class="btn btn-danger return_button" name="return_button" value="return" id="return_button" data-toggle="tooltip" title="Lütfen, iade kargonuzun içerisine; isim-soyisim ve sipariş numaranızı ekleyiniz.">İade Et</button>
                                </div>
                            <?php }else{ ?>
                                <div class="col-md-6" style="padding-right: 0px; padding-left: 0px; border-right: solid indianred;">
                                    <button type="submit" class="btn btn-danger return_button" name="return_button2" value="return" id="return_button" data-toggle="tooltip" title="Lütfen, iade kargonuzun içerisine; isim-soyisim ve sipariş numaranızı ekleyiniz." disabled>Ücreti Kupon Olarak Tanımla<br> </button>
                                </div>
                                <div class="col-md-6" style="padding-right: 0px; padding-left: 0px;">
                                    <button type="submit" style="padding: 12px 0;" class="btn btn-danger return_button" name="return_button" value="return" id="return_button" data-toggle="tooltip" title="Lütfen, iade kargonuzun içerisine; isim-soyisim ve sipariş numaranızı ekleyiniz." disabled>Ücreti Kartıma Aktar</button>
                                </div>
                            <?php } ?>
                      <?php } ?>
                        <a href="<?= $continue; ?>" class="btn btn-primary"><?= $button_continue; ?></a>
<? endif; ?>
</span>
<!-- . -->
<!-- . -->
<? if ($product_return_limit): ?>
<style>
@keyframes Animasyon--Dikkat {
0% {color: #FF0000;}
50% {color: #000000;}
100% {color: #FF0000;}
}
.Dikkat {
animation-iteration-count: infinite;
animation-name: Animasyon--Dikkat;
animation-duration: 1s;
display: inline-block;
animation-delay: 1s;
text-align: center;
margin-top: 20px;
width: 100%;
}
</style>
<span class="Dikkat">
<div class="alert alert-secondary" role="alert" data-toggle="tooltip" data-placement="bottom" title="İpta-İade Taleplerinizde, kampanya kapsamı dışına çıkılacaktır ve minimum <?= $product_return_limit; ?> adet ürün seçmeniz gerekmektedir.">
Bu siparişte en az <?= $product_return_limit; ?> ürün iade edebilirsiniz. <br>
</div>
</span>
<? endif; ?>
<!-- . -->
<?php } ?>
<!-- 14 workdays return control -->
</form>
<?php echo $content_bottom; ?>
</div>
<?php echo $column_right; ?></div>
</div>
</div>
<script type="text/javascript"><!--
$(function () {
$('input[name^=\'quantity\']').on('change', function() {
var checked_object = $(this).attr('data-quantity');
$('.product_return_checkbox').prop('checked', false);
$('input[name^=\'product_item\']').trigger('change');
});
var product_return_limit = '<?=$product_return_limit?>';
$('input[name^=\'product_item\']').on('change', function() {
var item_quantity = 0;
$('input[name^=\'product_item\']:checked').each(function() {
item_quantity += parseInt($('.quantity_text_' + $(this).val()).val());
});
if(item_quantity >= product_return_limit){
$(".return_button").prop( "disabled", false );
}else {
$(".return_button").prop( "disabled", true );
}
//console.log(item_quantity);
/*
var item_quantity = 0;
var product_item = $('input[name^=\'product_item\']:checked');
//console.log(product_item.length);
for (i = 0; i < product_item.length; i++) {
if($(product_item[i]).is(":checked")){
//console.log($(this).val());
item_quantity += parseInt($('.quantity_text_' + $(this).val()).val());
}
//item_quantity += parseInt($('.quantity_text_' + $(this).val()).val());
}
console.log(item_quantity); */
/*var product_item = $('input[name^=\'product_item\']:checked');
//console.log(product_item.length);
if($(this).attr('data-quantity')){
//product_item.length += parseInt($(this).val());
console.log(product_item);
}*/
/*
var product_item = $('input[name^=\'product_item\']:checked');
var quantity = $('.quantity_text_' + $(this).val()).val();
console.log(quantity);
//console.log($(this).attr('data-quantity'));
if($(this).attr('data-quantity')){
//product_item.length += parseInt($(this).val());
//console.log(product_item);
}
//console.log(product_item.length);
if(product_item.length >= product_return_limit){
$('#return_button').show();
}else {
$('#return_button').hide();
} */
});
});
//--></script>
<!--<script src="/catalog/view/theme/deercase/stylesheet/jquery/bootstrap-input-spinner.js"></script>
<script>
jQuery (function ($) {
$(".Qty").inputSpinner ();
});
</script>-->
<?php echo $footer; ?>