PageRenderTime 50ms CodeModel.GetById 23ms RepoModel.GetById 0ms app.codeStats 0ms

/app/cache/prod/smarty/compile/db/66/05/db6605f8562b0e3bd4aa4db1009b1027554017e8.file.notification_bt.tpl.php

https://bitbucket.org/tippycracker/autokraitis
PHP | 178 lines | 170 code | 8 blank | 0 comment | 28 complexity | 66b7e0fb17cbc891e77890cf274567dd MD5 | raw file
Possible License(s): BSD-2-Clause, GPL-2.0, GPL-3.0, BSD-3-Clause, Apache-2.0
  1. <?php /* Smarty version Smarty-3.1.19, created on 2018-04-11 22:09:57
  2. compiled from "/home/autokr/domains/autokrai.kraitis.lt/public_html/modules/gamification/views/templates/hook/notification_bt.tpl" */ ?>
  3. <?php /*%%SmartyHeaderCode:5238298735ace5d853131b4-90272276%%*/if(!defined('SMARTY_DIR')) exit('no direct access allowed');
  4. $_valid = $_smarty_tpl->decodeProperties(array (
  5. 'file_dependency' =>
  6. array (
  7. 'db6605f8562b0e3bd4aa4db1009b1027554017e8' =>
  8. array (
  9. 0 => '/home/autokr/domains/autokrai.kraitis.lt/public_html/modules/gamification/views/templates/hook/notification_bt.tpl',
  10. 1 => 1523456951,
  11. 2 => 'file',
  12. ),
  13. ),
  14. 'nocache_hash' => '5238298735ace5d853131b4-90272276',
  15. 'function' =>
  16. array (
  17. ),
  18. 'variables' =>
  19. array (
  20. 'current_id_tab' => 0,
  21. 'current_level_percent' => 0,
  22. 'current_level' => 0,
  23. 'advice_hide_url' => 0,
  24. 'link' => 0,
  25. 'notification' => 0,
  26. 'badges_to_display' => 0,
  27. 'unlock_badges' => 0,
  28. 'badge' => 0,
  29. 'i' => 0,
  30. 'next_badges' => 0,
  31. ),
  32. 'has_nocache_code' => false,
  33. 'version' => 'Smarty-3.1.19',
  34. 'unifunc' => 'content_5ace5d8552ea84_53447616',
  35. ),false); /*/%%SmartyHeaderCode%%*/?>
  36. <?php if ($_valid && !is_callable('content_5ace5d8552ea84_53447616')) {function content_5ace5d8552ea84_53447616($_smarty_tpl) {?><script>
  37. var current_id_tab = <?php echo intval($_smarty_tpl->tpl_vars['current_id_tab']->value);?>
  38. ;
  39. var current_level_percent = <?php echo intval($_smarty_tpl->tpl_vars['current_level_percent']->value);?>
  40. ;
  41. var current_level = <?php echo intval($_smarty_tpl->tpl_vars['current_level']->value);?>
  42. ;
  43. var gamification_level = '<?php echo smartyTranslate(array('s'=>'Level','mod'=>'gamification','js'=>1),$_smarty_tpl);?>
  44. ';
  45. var advice_hide_url = '<?php echo $_smarty_tpl->tpl_vars['advice_hide_url']->value;?>
  46. ';
  47. var hide_advice = '<?php echo smartyTranslate(array('s'=>'Do you really want to hide this advice?','mod'=>'gamification','js'=>1),$_smarty_tpl);?>
  48. ';
  49. $('#dropdown_gamification .notifs_panel_header, #dropdown_gamification .tab-content').click(function () {
  50. return false;
  51. });
  52. $('#dropdown_gamification .panel-footer').click(function (elt) {
  53. window.location.href = '<?php echo $_smarty_tpl->tpl_vars['link']->value->getAdminLink('AdminGamification');?>
  54. ';
  55. });
  56. $('#gamification_tab li').click(function () {
  57. gamificationDisplayTab($(this).children('a'));
  58. return false;
  59. });
  60. function gamificationDisplayTab(elt)
  61. {
  62. $('#gamification_tab li, .gamification-tab-pane').removeClass('active');
  63. $(elt).parent('li').addClass('active');
  64. $('#'+$(elt).data('target')).addClass('active');
  65. }
  66. </script>
  67. <li id="gamification_notif" style="background:none" class="dropdown">
  68. <a href="javascript:void(0);" class="dropdown-toggle gamification_notif" data-toggle="dropdown">
  69. <i class="icon-trophy"></i>
  70. <svg class="icon-trophy-svg" viewBox="0 0 24 24">
  71. <path fill="#6c868e" d="M20.2,2H19.5H18C17.1,2 16,3 16,4H8C8,3 6.9,2 6,2H4.5H3.8H2V11C2,12 3,13 4,13H6.2C6.6,15 7.9,16.7 11,17V19.1C8.8,19.3 8,20.4 8,21.7V22H16V21.7C16,20.4 15.2,19.3 13,19.1V17C16.1,16.7 17.4,15 17.8,13H20C21,13 22,12 22,11V2H20.2M4,11V4H6V6V11C5.1,11 4.3,11 4,11M20,11C19.7,11 18.9,11 18,11V6V4H20V11Z" />
  72. </svg>
  73. <span id="gamification_notif_number_wrapper" class="notifs_badge">
  74. <span id="gamification_notif_value"><?php echo intval($_smarty_tpl->tpl_vars['notification']->value);?>
  75. </span>
  76. </span>
  77. </a>
  78. <div class="dropdown-menu notifs_dropdown" id="dropdown_gamification">
  79. <section id="gamification_notif_wrapper" class="notifs_panel" style="width:325px">
  80. <header class="notifs_panel_header">
  81. <h3><?php echo smartyTranslate(array('s'=>'Your Merchant Expertise','mod'=>'gamification'),$_smarty_tpl);?>
  82. <span class="label label-default" style="float:right"><?php echo smartyTranslate(array('s'=>'Level','mod'=>'gamification'),$_smarty_tpl);?>
  83. <?php echo intval($_smarty_tpl->tpl_vars['current_level']->value);?>
  84. : <?php echo intval($_smarty_tpl->tpl_vars['current_level_percent']->value);?>
  85. %</span>
  86. </h3>
  87. </header>
  88. <div class="progress" style="margin: 10px">
  89. <div class="progress-bar progress-bar-info" role="progressbar" aria-valuenow="<?php echo intval($_smarty_tpl->tpl_vars['current_level_percent']->value);?>
  90. " aria-valuemin="0" aria-valuemax="100" style="width: <?php echo intval($_smarty_tpl->tpl_vars['current_level_percent']->value);?>
  91. %;">
  92. <span style="color:#FFF"><?php echo smartyTranslate(array('s'=>'Level','mod'=>'gamification'),$_smarty_tpl);?>
  93. <?php echo intval($_smarty_tpl->tpl_vars['current_level']->value);?>
  94. : <?php echo intval($_smarty_tpl->tpl_vars['current_level_percent']->value);?>
  95. %</span>
  96. </div>
  97. </div>
  98. <!-- Nav tabs -->
  99. <ul class="nav nav-tabs" id="gamification_tab" style="margin-left:10px">
  100. <li class="active">
  101. <a href="#home" data-toggle="tab" data-target="gamification_1" onclick="gamificationDisplayTab(this); return false;"><?php echo smartyTranslate(array('s'=>'Last badge :','mod'=>'gamification'),$_smarty_tpl);?>
  102. </a>
  103. </li>
  104. <li>
  105. <a href="#profile" data-toggle="tab" data-target="gamification_2" onclick="gamificationDisplayTab(this); return false;"><?php echo smartyTranslate(array('s'=>'Next badge :','mod'=>'gamification'),$_smarty_tpl);?>
  106. </a>
  107. </li>
  108. </ul>
  109. <!-- Tab panes -->
  110. <div class="tab-content">
  111. <div class="tab-pane gamification-tab-pane active" id="gamification_1">
  112. <ul id="gamification_badges_list" style="<?php if (count($_smarty_tpl->tpl_vars['badges_to_display']->value)<=2) {?> height:170px;<?php }?> padding-left:0">
  113. <?php $_smarty_tpl->tpl_vars['badge'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['badge']->_loop = false;
  114. $_smarty_tpl->tpl_vars["i"] = new Smarty_Variable;
  115. $_from = $_smarty_tpl->tpl_vars['unlock_badges']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
  116. foreach ($_from as $_smarty_tpl->tpl_vars['badge']->key => $_smarty_tpl->tpl_vars['badge']->value) {
  117. $_smarty_tpl->tpl_vars['badge']->_loop = true;
  118. $_smarty_tpl->tpl_vars["i"]->value = $_smarty_tpl->tpl_vars['badge']->key;
  119. ?>
  120. <?php if ($_smarty_tpl->tpl_vars['badge']->value->id) {?>
  121. <li class="<?php if ($_smarty_tpl->tpl_vars['badge']->value->validated) {?> unlocked <?php } else { ?> locked <?php }?>" style="float:left;">
  122. <span class="<?php if ($_smarty_tpl->tpl_vars['badge']->value->validated) {?> unlocked_img <?php } else { ?> locked_img <?php }?>" <?php if ($_smarty_tpl->tpl_vars['badge']->value->validated) {?>style="left: 12px;"<?php }?>></span>
  123. <div class="gamification_badges_title"><span><?php if ($_smarty_tpl->tpl_vars['badge']->value->validated) {?> <?php echo smartyTranslate(array('s'=>'Last badge :','mod'=>'gamification'),$_smarty_tpl);?>
  124. <?php } else { ?> <?php echo smartyTranslate(array('s'=>'Next badge :','mod'=>'gamification'),$_smarty_tpl);?>
  125. <?php }?></span></div>
  126. <div class="gamification_badges_img" data-placement="<?php if ($_smarty_tpl->tpl_vars['i']->value<=1) {?>bottom<?php } else { ?>top<?php }?>" data-original-title="<?php echo $_smarty_tpl->smarty->registered_plugins[Smarty::PLUGIN_MODIFIER]['escape'][0][0]->smartyEscape($_smarty_tpl->tpl_vars['badge']->value->description,'html','UTF-8');?>
  127. "><img src="<?php echo $_smarty_tpl->tpl_vars['badge']->value->getBadgeImgUrl();?>
  128. "></div>
  129. <div class="gamification_badges_name"><?php echo $_smarty_tpl->smarty->registered_plugins[Smarty::PLUGIN_MODIFIER]['escape'][0][0]->smartyEscape($_smarty_tpl->tpl_vars['badge']->value->name,'html','UTF-8');?>
  130. </div>
  131. </li>
  132. <?php }?>
  133. <?php } ?>
  134. </ul>
  135. </div>
  136. <div class="tab-pane gamification-tab-pane" id="gamification_2">
  137. <ul id="gamification_badges_list" style="<?php if (count($_smarty_tpl->tpl_vars['badges_to_display']->value)<=2) {?> height:170px;<?php }?> padding-left:0">
  138. <?php $_smarty_tpl->tpl_vars['badge'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['badge']->_loop = false;
  139. $_smarty_tpl->tpl_vars["i"] = new Smarty_Variable;
  140. $_from = $_smarty_tpl->tpl_vars['next_badges']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
  141. foreach ($_from as $_smarty_tpl->tpl_vars['badge']->key => $_smarty_tpl->tpl_vars['badge']->value) {
  142. $_smarty_tpl->tpl_vars['badge']->_loop = true;
  143. $_smarty_tpl->tpl_vars["i"]->value = $_smarty_tpl->tpl_vars['badge']->key;
  144. ?>
  145. <?php if ($_smarty_tpl->tpl_vars['badge']->value->id&&!$_smarty_tpl->tpl_vars['badge']->value->awb) {?>
  146. <li class="<?php if ($_smarty_tpl->tpl_vars['badge']->value->validated) {?> unlocked <?php } else { ?> locked <?php }?>" style="float:left;">
  147. <span class="<?php if ($_smarty_tpl->tpl_vars['badge']->value->validated) {?> unlocked_img <?php } else { ?> locked_img <?php }?>" <?php if ($_smarty_tpl->tpl_vars['badge']->value->validated) {?>style="left: 12px;"<?php }?>></span>
  148. <div class="gamification_badges_title"><span><?php if ($_smarty_tpl->tpl_vars['badge']->value->validated) {?> <?php echo smartyTranslate(array('s'=>'Last badge :','mod'=>'gamification'),$_smarty_tpl);?>
  149. <?php } else { ?> <?php echo smartyTranslate(array('s'=>'Next badge :','mod'=>'gamification'),$_smarty_tpl);?>
  150. <?php }?></span></div>
  151. <div class="gamification_badges_img" data-placement="<?php if ($_smarty_tpl->tpl_vars['i']->value<=1) {?>bottom<?php } else { ?>top<?php }?>"data-toggle="tooltip" data-original-title="<?php echo $_smarty_tpl->smarty->registered_plugins[Smarty::PLUGIN_MODIFIER]['escape'][0][0]->smartyEscape($_smarty_tpl->tpl_vars['badge']->value->description,'html','UTF-8');?>
  152. "><img src="<?php echo $_smarty_tpl->tpl_vars['badge']->value->getBadgeImgUrl();?>
  153. "></div>
  154. <div class="gamification_badges_name"><?php echo $_smarty_tpl->smarty->registered_plugins[Smarty::PLUGIN_MODIFIER]['escape'][0][0]->smartyEscape($_smarty_tpl->tpl_vars['badge']->value->name,'html','UTF-8');?>
  155. </div>
  156. </li>
  157. <?php }?>
  158. <?php } ?>
  159. </ul>
  160. </div>
  161. </div>
  162. <footer class="panel-footer">
  163. <a href="<?php echo $_smarty_tpl->tpl_vars['link']->value->getAdminLink('AdminGamification');?>
  164. "><?php echo smartyTranslate(array('s'=>'View my complete profile','mod'=>'gamification'),$_smarty_tpl);?>
  165. </a>
  166. </footer>
  167. </section>
  168. </div>
  169. </li>
  170. <?php }} ?>