poma1

tpl cheng

Oct 24th, 2016
53
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
HTML 10.09 KB | None | 0 0
  1. <?php echo $header; ?>
  2.  
  3. <?php echo $content_top; ?>
  4.  
  5. <div class="breadcrumb">
  6.     <?php foreach ($breadcrumbs as $breadcrumb) { ?>
  7.     <?php echo $breadcrumb['separator']; ?><a href="<?php echo $breadcrumb['href']; ?>"><?php echo $breadcrumb['text']; ?></a>
  8.     <?php } ?>
  9. </div>
  10.  
  11. <header class="heading">
  12.     <a href="index.php?route=account/products" style="display: inline-block;vertical-align: top;padding: 0 10px;text-align: center;"><img src="/image/products.png"><br>Товары</a>
  13.     <a href="/index.php?route=account/order" style="display: inline-block;vertical-align: top;padding: 0 10px;text-align: center;"><img src="/image/orders.png"><br>Заказы</a>
  14.     <a href="index.php?route=account/export" style="display: inline-block;vertical-align: top;padding: 0 10px;text-align: center;"><img src="/image/export.png"><br>Экспорт</a>
  15.     <a href="index.php?route=account/product_return" style="display: inline-block;vertical-align: top;padding: 0 10px;text-align: center;"><img src="/image/returns.png"><br>Возвраты</a>
  16.     <a href="index.php?route=account/account" style="display: inline-block;vertical-align: top;padding: 0 10px;text-align: center;"><img src="/image/help.png"><br>Помощь</a>
  17.     <!--h1><?php echo $heading_title; ?></h1-->
  18. </header>
  19.  
  20. <?php
  21.  
  22.     if ($column_left && $column_right) {
  23.         $main = "col-sm-6 middle sideleft"; }
  24.     else if ($column_left || $column_right) {
  25.         $main = "col-sm-9";
  26.         if($column_left) $main.=" sideleft"; else $main.= " sideright";
  27.     }
  28.     else { $main = "col-sm-12"; }
  29.  
  30.     ?>
  31. <form action="<?php echo $action; ?>" method="post" enctype="multipart/form-data" id="return" class="form" role="form">
  32. <div class="row">
  33.  
  34.     <?php echo $column_left; ?>
  35.  
  36.     <section id="maincontent" class="<?php echo $main; ?>" role="main">
  37.  
  38.         <div class="mainborder">
  39.  
  40.             <?php if ($column_left || $column_right) { ?>
  41.             <div id="toggle_sidebar"></div>
  42.             <?php } ?>
  43.  
  44.             <table class="table table-bordered">
  45.  
  46.                 <thead>
  47.                 <tr>
  48.                     <td colspan="2">
  49.                         <?php echo $text_order_detail; ?>
  50.                     </td>
  51.                 </tr>
  52.                 </thead>
  53.  
  54.                 <tbody>
  55.                 <tr>
  56.                     <td style="width: 50%;">
  57.                         <?php if ($invoice_no) { ?>
  58.                         <b><?php echo $text_invoice_no; ?></b> <?php echo $invoice_no; ?><br />
  59.                         <?php } ?>
  60.  
  61.                         <b><?php echo $text_order_id; ?></b> #<?php echo $order_id; ?><br />
  62.  
  63.                         <b><?php echo $text_date_added; ?></b> <?php echo $date_added; ?><br />
  64.  
  65.                         <!--<b><?php echo $text_post_date; ?>:</b> <?php echo $post_date; ?>-->
  66.                     </td>
  67.                     <td>
  68.                         <b><?php echo $text_payment_method; ?></b> <?php echo $payment_method; ?>
  69.                         <?php if ($shipping_method) { ?>
  70.                         <br /><b><?php echo $text_shipping_method; ?></b> <?php echo $shipping_method; ?>
  71.                         <?php } ?>
  72.  
  73.                         <?php if ($ttn) { ?>
  74.                         <br /><b>ТТН:</b> <?php echo $ttn; ?>
  75.                         <?php } ?>
  76.  
  77.                     </td>
  78.                 </tr>
  79.                 </tbody>
  80.  
  81.             </table>
  82.  
  83.             <table class="table table-bordered">
  84.                 <thead>
  85.                 <tr>
  86.                     <td colspan="4">
  87.                         <?php echo $text_shipping_address; ?>
  88.                     </td>
  89.                 </tr>
  90.                 </thead>
  91.                 <tbody>
  92.                 <?php if ($error_region) { ?>
  93.                 <tr>
  94.                 <td><span class="error"><?php echo $error_region; ?></span></td>
  95.                 </tr>
  96.                     <?php } ?>
  97.                 <tr>
  98.                     <td style="width: 100%;">
  99.                        <span style="color: red;">*</span> <input type="text" name="shipping_firstname" value="<?php echo $shipping_firstname; ?>"/>
  100.                     </td>
  101.                 </tr>
  102.                 <tr>
  103.                     <td>
  104.                         <select name="shipping_zone" id="shipping_zone">
  105.                                 <option value="0">- выберите область -</option>
  106.                             <?php foreach ($zones as $zone) { ?>
  107.                             <?php if(!empty($zone['Area'])){ ?>
  108.                             <option value="<?php echo $zone['Area'] ?>" ><?php echo $zone['name']; ?></option>
  109.                             <?php } ?>
  110.                             <?php } ?>
  111.                         </select>
  112.  
  113.                         <div id="divregion">
  114.                         <select name="shipping_city" id="shipping_city" disabled="disabled">
  115.                             <option  value="0">- выберите город -</option>
  116.                             <?php foreach($regions as $region){ ?>
  117.                             <?php if($region['Area'] == $) { ?>
  118.                             <option  value="<?php echo $region['id']?>"><?php echo $region['DescriptionRu']?></option>
  119.                             <?php } ?>
  120.                         </select>
  121.  
  122.                         </div>
  123.                         <div id="divcity">
  124.                         <select name="payment_address_1" id="payment_address_1">
  125.                             <option  value="0">- выберите отдиления -</option>
  126.                         </select>
  127.                         </div>
  128.                     </td>
  129.                 </tr>
  130.                 <tr>
  131.                     <td style="width: 100%">
  132.                         <span style="color: red;">*</span> <input type="text" name="telephone" value="<?php echo $telephone; ?>"></td>
  133.                 </tr>
  134.                 </tbody>
  135.             </table>
  136.             <?php if($sum_ > 0){ ?>
  137.             <div style="text-align: right;font-size: 16px;"><b>Сумма наложки:</b> <?php echo (float)$sum_; ?></div>
  138.             <?php } ?>
  139.             <table class="table table-bordered table-adjust">
  140.  
  141.                 <thead>
  142.                 <tr>
  143.                     <td><?php echo "Фото"?></td>
  144.                     <td><?php echo $column_name; ?></td>
  145.                     <td><?php echo $column_model; ?></td>
  146.                     <td><?php echo $column_quantity; ?></td>
  147.                     <td><?php echo $column_price; ?></td>
  148.                     <td><?php echo $column_total; ?></td>
  149.                 </tr>
  150.                 </thead>
  151.  
  152.                 <tbody>
  153.  
  154.                 <?php foreach ($products as $product) { ?>
  155.  
  156.                 <tr>
  157.                 <tr>
  158.                     <?php if (!empty($product['image'])) { ?>
  159.                     <td style="text-align: center"><img src="<?php echo "/image/". $product['image'] ;?>" width="100" height="100"></td>
  160.                     <?php } else { ?>
  161.                     <td></td>
  162.                     <?php } ?>
  163.  
  164.                     <td>
  165.                         <b><?php echo $product['name']; ?></b>
  166.  
  167.                         <?php foreach ($product['option'] as $option) { ?>
  168.                         <br />&nbsp;
  169.                         <small> - <?php echo $option['name']; ?>: <?php echo $option['value']; ?></small>
  170.                         <?php } ?>
  171.                         <!--br />
  172.                        <small>
  173.                            <a href="<?php echo $product['return']; ?>" class="" title="<?php echo $button_return; ?>" ><?php echo $button_return; ?>  &rarr;</a>
  174.                        </small-->
  175.                     </td>
  176.                     <td><?php echo $product['model']; ?></td>
  177.                     <td class="right"><?php echo $product['quantity']; ?></td>
  178.                     <td class="right"><?php echo $product['price']; ?></td>
  179.                     <td class="right"><?php echo $product['total']; ?></td>
  180.                 </tr>
  181.  
  182.                 <?php } ?>
  183.  
  184.                 <?php foreach ($vouchers as $voucher) { ?>
  185.  
  186.                 <tr>
  187.                     <td><?php echo $voucher['description']; ?></td>
  188.                     <td></td>
  189.                     <td class="right">1</td>
  190.                     <td class="right"><?php echo $voucher['amount']; ?></td>
  191.                     <td class="right"><?php echo $voucher['amount']; ?></td>
  192.                 </tr>
  193.                 <?php } ?>
  194.  
  195.                 </tbody>
  196.  
  197.                 <tfoot>
  198.                 <?php foreach ($totals as $total) { ?>
  199.  
  200.                 <tr>
  201.                     <td></td>
  202.                     <td colspan="4" class="right"><b><?php echo $total['title']; ?>:</b></td>
  203.                     <td class="right"><?php echo $total['text']; ?></td>
  204.                 </tr>
  205.                 <?php } ?>
  206.                 </tfoot>
  207.  
  208.             </table>
  209.  
  210.  
  211.             <div class="form-actions" style="text-align: center">
  212.                 <a href="<?php echo $back; ?>" class="button button-default"><?php echo $button_back; ?></a>
  213.                 <input type="hidden" name="order_id" value="<?php echo $order_id?>"/>
  214.                 <input type="submit" value="<?php echo $button_continue; ?>" class="button button-default button-inverse" />
  215.             </div>
  216.          </form>
  217.     </section> <!-- #maincontent -->
  218.  
  219.     <?php echo $column_right; ?>
  220.  
  221. </div> <!-- .row -->
  222.  
  223. <?php echo $content_bottom; ?>
  224. <style>
  225.     #divregion, #divcity {
  226.         display: none;
  227.         margin-top: 15px;
  228.     }
  229. </style>
  230. <?php echo $footer; ?>
  231. <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
  232. <script>
  233.     $(document).ready(function () {
  234.         $("#shipping_zone").change(function () {
  235.             var zone = parseInt($("#shipping_zone").val() );
  236.             selectCity(zone);
  237.         });
  238.     });
  239.     function selectCity(zone) {
  240.         var city = $("#shipping_city");
  241.         if(zone > 0){
  242.             $("#divregion").fadeIn("slow");
  243.             city.attr("disabled", false);
  244.             city.load(
  245.                     "order_change.tpl",
  246.                     {zone: zone}
  247.             )
  248.         }
  249.     }
  250. </script>
Add Comment
Please, Sign In to add comment