PageRenderTime 38ms CodeModel.GetById 7ms RepoModel.GetById 0ms app.codeStats 0ms

/prestashop/_/cache/smarty/compile/2c/1e/cb/2c1ecb8d00c58f3238e3376d08d8a7940de2b5de.file.discount.tpl.php

https://gitlab.com/A.Julien/sendstockbymail-module-prestashop
PHP | 176 lines | 165 code | 11 blank | 0 comment | 33 complexity | 5bd26ac7b70a9ea8cdff3b9b9838b281 MD5 | raw file
  1. <?php /* Smarty version Smarty-3.1.19, created on 2016-08-29 22:06:33
  2. compiled from "C:\xampp\htdocs\prestashop\prestashop\_\themes\default-bootstrap\discount.tpl" */ ?>
  3. <?php /*%%SmartyHeaderCode:1818957c495c9ba3475-69633593%%*/if(!defined('SMARTY_DIR')) exit('no direct access allowed');
  4. $_valid = $_smarty_tpl->decodeProperties(array (
  5. 'file_dependency' =>
  6. array (
  7. '2c1ecb8d00c58f3238e3376d08d8a7940de2b5de' =>
  8. array (
  9. 0 => 'C:\\xampp\\htdocs\\prestashop\\prestashop\\_\\themes\\default-bootstrap\\discount.tpl',
  10. 1 => 1472500916,
  11. 2 => 'file',
  12. ),
  13. ),
  14. 'nocache_hash' => '1818957c495c9ba3475-69633593',
  15. 'function' =>
  16. array (
  17. ),
  18. 'variables' =>
  19. array (
  20. 'link' => 0,
  21. 'navigationPipe' => 0,
  22. 'cart_rules' => 0,
  23. 'nb_cart_rules' => 0,
  24. 'discountDetail' => 0,
  25. 'force_ssl' => 0,
  26. 'base_dir_ssl' => 0,
  27. 'base_dir' => 0,
  28. ),
  29. 'has_nocache_code' => false,
  30. 'version' => 'Smarty-3.1.19',
  31. 'unifunc' => 'content_57c495c9f01660_93661634',
  32. ),false); /*/%%SmartyHeaderCode%%*/?>
  33. <?php if ($_valid && !is_callable('content_57c495c9f01660_93661634')) {function content_57c495c9f01660_93661634($_smarty_tpl) {?><?php if (!is_callable('smarty_modifier_regex_replace')) include 'C:\\xampp\\htdocs\\prestashop\\prestashop\\_\\tools\\smarty\\plugins\\modifier.regex_replace.php';
  34. ?>
  35. <?php $_smarty_tpl->_capture_stack[0][] = array('path', null, null); ob_start(); ?><a href="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['link']->value->getPageLink('my-account',true), ENT_QUOTES, 'UTF-8', true);?>
  36. "><?php echo smartyTranslate(array('s'=>'My account'),$_smarty_tpl);?>
  37. </a><span class="navigation-pipe"><?php echo $_smarty_tpl->tpl_vars['navigationPipe']->value;?>
  38. </span><span class="navigation_page"><?php echo smartyTranslate(array('s'=>'My vouchers'),$_smarty_tpl);?>
  39. </span><?php list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]);
  40. if (!empty($_capture_buffer)) {
  41. if (isset($_capture_assign)) $_smarty_tpl->assign($_capture_assign, ob_get_contents());
  42. if (isset( $_capture_append)) $_smarty_tpl->append( $_capture_append, ob_get_contents());
  43. Smarty::$_smarty_vars['capture'][$_capture_buffer]=ob_get_clean();
  44. } else $_smarty_tpl->capture_error();?>
  45. <h1 class="page-heading">
  46. <?php echo smartyTranslate(array('s'=>'My vouchers'),$_smarty_tpl);?>
  47. </h1>
  48. <?php if (isset($_smarty_tpl->tpl_vars['cart_rules']->value)&&count($_smarty_tpl->tpl_vars['cart_rules']->value)&&$_smarty_tpl->tpl_vars['nb_cart_rules']->value) {?>
  49. <table class="discount table table-bordered footab">
  50. <thead>
  51. <tr>
  52. <th data-sort-ignore="true" class="discount_code first_item"><?php echo smartyTranslate(array('s'=>'Code'),$_smarty_tpl);?>
  53. </th>
  54. <th data-sort-ignore="true" class="discount_description item"><?php echo smartyTranslate(array('s'=>'Description'),$_smarty_tpl);?>
  55. </th>
  56. <th class="discount_quantity item"><?php echo smartyTranslate(array('s'=>'Quantity'),$_smarty_tpl);?>
  57. </th>
  58. <th data-sort-ignore="true" data-hide="phone,tablet" class="discount_value item"><?php echo smartyTranslate(array('s'=>'Value'),$_smarty_tpl);?>
  59. *</th>
  60. <th data-hide="phone,tablet" class="discount_minimum item"><?php echo smartyTranslate(array('s'=>'Minimum'),$_smarty_tpl);?>
  61. </th>
  62. <th data-sort-ignore="true" data-hide="phone,tablet" class="discount_cumulative item"><?php echo smartyTranslate(array('s'=>'Cumulative'),$_smarty_tpl);?>
  63. </th>
  64. <th data-hide="phone" class="discount_expiration_date last_item"><?php echo smartyTranslate(array('s'=>'Expiration date'),$_smarty_tpl);?>
  65. </th>
  66. </tr>
  67. </thead>
  68. <tbody>
  69. <?php $_smarty_tpl->tpl_vars['discountDetail'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['discountDetail']->_loop = false;
  70. $_from = $_smarty_tpl->tpl_vars['cart_rules']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
  71. $_smarty_tpl->tpl_vars['discountDetail']->total= $_smarty_tpl->_count($_from);
  72. $_smarty_tpl->tpl_vars['discountDetail']->iteration=0;
  73. $_smarty_tpl->tpl_vars['discountDetail']->index=-1;
  74. $_smarty_tpl->tpl_vars['smarty']->value['foreach']['myLoop']['index']=-1;
  75. foreach ($_from as $_smarty_tpl->tpl_vars['discountDetail']->key => $_smarty_tpl->tpl_vars['discountDetail']->value) {
  76. $_smarty_tpl->tpl_vars['discountDetail']->_loop = true;
  77. $_smarty_tpl->tpl_vars['discountDetail']->iteration++;
  78. $_smarty_tpl->tpl_vars['discountDetail']->index++;
  79. $_smarty_tpl->tpl_vars['discountDetail']->first = $_smarty_tpl->tpl_vars['discountDetail']->index === 0;
  80. $_smarty_tpl->tpl_vars['discountDetail']->last = $_smarty_tpl->tpl_vars['discountDetail']->iteration === $_smarty_tpl->tpl_vars['discountDetail']->total;
  81. $_smarty_tpl->tpl_vars['smarty']->value['foreach']['myLoop']['first'] = $_smarty_tpl->tpl_vars['discountDetail']->first;
  82. $_smarty_tpl->tpl_vars['smarty']->value['foreach']['myLoop']['index']++;
  83. $_smarty_tpl->tpl_vars['smarty']->value['foreach']['myLoop']['last'] = $_smarty_tpl->tpl_vars['discountDetail']->last;
  84. ?>
  85. <tr class="<?php if ($_smarty_tpl->getVariable('smarty')->value['foreach']['myLoop']['first']) {?>first_item<?php } elseif ($_smarty_tpl->getVariable('smarty')->value['foreach']['myLoop']['last']) {?>last_item<?php } else { ?>item<?php }?> <?php if ($_smarty_tpl->getVariable('smarty')->value['foreach']['myLoop']['index']%2) {?>alternate_item<?php }?>">
  86. <td class="discount_code"><?php echo $_smarty_tpl->tpl_vars['discountDetail']->value['code'];?>
  87. </td>
  88. <td class="discount_description"><?php echo $_smarty_tpl->tpl_vars['discountDetail']->value['name'];?>
  89. </td>
  90. <td data-value="<?php echo $_smarty_tpl->tpl_vars['discountDetail']->value['quantity_for_user'];?>
  91. " class="discount_quantity"><?php echo $_smarty_tpl->tpl_vars['discountDetail']->value['quantity_for_user'];?>
  92. </td>
  93. <td class="discount_value">
  94. <?php if ($_smarty_tpl->tpl_vars['discountDetail']->value['reduction_percent']>0) {?>
  95. <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['discountDetail']->value['reduction_percent'], ENT_QUOTES, 'UTF-8', true);?>
  96. %
  97. <?php }?>
  98. <?php if ($_smarty_tpl->tpl_vars['discountDetail']->value['reduction_amount']>0) {?>
  99. <?php if ($_smarty_tpl->tpl_vars['discountDetail']->value['reduction_percent']>0) {?> + <?php }?>
  100. <?php echo $_smarty_tpl->smarty->registered_plugins[Smarty::PLUGIN_FUNCTION]['convertPrice'][0][0]->convertPrice(array('price'=>$_smarty_tpl->tpl_vars['discountDetail']->value['reduction_amount']),$_smarty_tpl);?>
  101. (<?php if ($_smarty_tpl->tpl_vars['discountDetail']->value['reduction_tax']==1) {?><?php echo smartyTranslate(array('s'=>'Tax included'),$_smarty_tpl);?>
  102. <?php } else { ?><?php echo smartyTranslate(array('s'=>'Tax excluded'),$_smarty_tpl);?>
  103. <?php }?>)
  104. <?php }?>
  105. <?php if ($_smarty_tpl->tpl_vars['discountDetail']->value['free_shipping']) {?>
  106. <?php if ($_smarty_tpl->tpl_vars['discountDetail']->value['reduction_percent']>0||$_smarty_tpl->tpl_vars['discountDetail']->value['reduction_amount']>0) {?> + <?php }?>
  107. <?php echo smartyTranslate(array('s'=>'Free shipping'),$_smarty_tpl);?>
  108. <?php }?>
  109. <?php if ($_smarty_tpl->tpl_vars['discountDetail']->value['gift_product']>0) {?>
  110. <?php if ($_smarty_tpl->tpl_vars['discountDetail']->value['reduction_percent']>0||$_smarty_tpl->tpl_vars['discountDetail']->value['reduction_amount']>0||$_smarty_tpl->tpl_vars['discountDetail']->value['gift_product']) {?> + <?php }?>
  111. <?php echo $_smarty_tpl->tpl_vars['discountDetail']->value['gift_product_name'];?>
  112. <?php echo smartyTranslate(array('s'=>'Free %s!','sprintf'=>$_smarty_tpl->tpl_vars['discountDetail']->value['gift_product_name']),$_smarty_tpl);?>
  113. !
  114. <?php }?>
  115. </td>
  116. <td class="discount_minimum" data-value="<?php if ($_smarty_tpl->tpl_vars['discountDetail']->value['minimal']==0) {?>0<?php } else { ?><?php echo $_smarty_tpl->tpl_vars['discountDetail']->value['minimal'];?>
  117. <?php }?>">
  118. <?php if ($_smarty_tpl->tpl_vars['discountDetail']->value['minimal']==0) {?>
  119. <?php echo smartyTranslate(array('s'=>'None'),$_smarty_tpl);?>
  120. <?php } else { ?>
  121. <?php echo $_smarty_tpl->smarty->registered_plugins[Smarty::PLUGIN_FUNCTION]['convertPrice'][0][0]->convertPrice(array('price'=>$_smarty_tpl->tpl_vars['discountDetail']->value['minimal']),$_smarty_tpl);?>
  122. (<?php if ($_smarty_tpl->tpl_vars['discountDetail']->value['minimum_amount_tax']==1) {?><?php echo smartyTranslate(array('s'=>'Tax included'),$_smarty_tpl);?>
  123. <?php } else { ?><?php echo smartyTranslate(array('s'=>'Tax excluded'),$_smarty_tpl);?>
  124. <?php }?>)
  125. <?php }?>
  126. </td>
  127. <td class="discount_cumulative">
  128. <?php if ($_smarty_tpl->tpl_vars['discountDetail']->value['cumulable']==1) {?>
  129. <i class="icon-ok icon"></i> <?php echo smartyTranslate(array('s'=>'Yes'),$_smarty_tpl);?>
  130. <?php } else { ?>
  131. <i class="icon-remove icon"></i> <?php echo smartyTranslate(array('s'=>'No'),$_smarty_tpl);?>
  132. <?php }?>
  133. </td>
  134. <td class="discount_expiration_date" data-value="<?php echo smarty_modifier_regex_replace($_smarty_tpl->tpl_vars['discountDetail']->value['date_to'],"/[\-\:\ ]/",'');?>
  135. ">
  136. <?php echo $_smarty_tpl->smarty->registered_plugins[Smarty::PLUGIN_FUNCTION]['dateFormat'][0][0]->dateFormat(array('date'=>$_smarty_tpl->tpl_vars['discountDetail']->value['date_to']),$_smarty_tpl);?>
  137. </td>
  138. </tr>
  139. <?php } ?>
  140. </tbody>
  141. </table>
  142. <?php } else { ?>
  143. <p class="alert alert-warning"><?php echo smartyTranslate(array('s'=>'You do not have any vouchers.'),$_smarty_tpl);?>
  144. </p>
  145. <?php }?>
  146. <ul class="footer_links clearfix">
  147. <li>
  148. <a class="btn btn-default button button-small" href="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['link']->value->getPageLink('my-account',true), ENT_QUOTES, 'UTF-8', true);?>
  149. ">
  150. <span>
  151. <i class="icon-chevron-left"></i> <?php echo smartyTranslate(array('s'=>'Back to your account'),$_smarty_tpl);?>
  152. </span>
  153. </a>
  154. </li>
  155. <li>
  156. <a class="btn btn-default button button-small" href="<?php if (isset($_smarty_tpl->tpl_vars['force_ssl']->value)&&$_smarty_tpl->tpl_vars['force_ssl']->value) {?><?php echo $_smarty_tpl->tpl_vars['base_dir_ssl']->value;?>
  157. <?php } else { ?><?php echo $_smarty_tpl->tpl_vars['base_dir']->value;?>
  158. <?php }?>">
  159. <span>
  160. <i class="icon-chevron-left"></i> <?php echo smartyTranslate(array('s'=>'Home'),$_smarty_tpl);?>
  161. </span>
  162. </a>
  163. </li>
  164. </ul>
  165. <?php }} ?>