暫無描述
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

users_gift_list.htm 9.8KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247
  1. <!DOCTYPE HTML>
  2. <html>
  3. <head>
  4. <meta charset="utf-8" />
  5. <title>积分兑换-{eyou:global name='web_name' /}</title>
  6. <meta name="renderer" content="webkit">
  7. <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
  8. <meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" name="viewport" />
  9. <link href="{eyou:global name='web_cmspath'/}/favicon.ico" rel="shortcut icon" type="image/x-icon" />
  10. {eyou:static file="users/skin/css/basic.css"/}
  11. {eyou:static file="users/skin/css/eyoucms.css"/}
  12. <!-- 新样式 2020-11-25 -->
  13. {eyou:static file="users/skin/css/element/index.css" /}
  14. {eyou:static file="users/skin/css/e-user.css" /}
  15. {eyou:include file="users/skin/css/diy_css.htm"/}
  16. {eyou:static file="/public/static/common/js/jquery.min.js"/}
  17. {eyou:static file="/public/plugins/layer-v3.1.0/layer.js"/}
  18. {eyou:static file="/public/static/common/js/tag_global.js"/}
  19. {eyou:static file="/public/static/common/js/mobile_global.js"/}
  20. </head>
  21. <body class="centre">
  22. <!-- 头部信息 -->
  23. <div class="ey-header-status">
  24. <div class="header-status-l">
  25. <a href="javascript:history.go(-1)"><i class="el-icon-arrow-left"></i></a>
  26. </div>
  27. <div class="header-status-m">积分兑换</div>
  28. <div class="header-status-r">
  29. <a href="{eyou:url link='user/Users/index' /}"><i class="el-icon-user"></i></a>
  30. </div>
  31. </div>
  32. <!-- 头部信息结束 -->
  33. <div class="h50"></div>
  34. <div class="oper-row border-b-1-e">
  35. <!-- 足迹导航栏 -->
  36. <div class="oper-row-roll">
  37. <a class="oper-row-button active" id="a_changeGift1" onclick="changeGift(1);"> 全部商品 </a>
  38. <a class="oper-row-button" id="a_changeGift2" onclick="changeGift(2);"> 兑换记录 </a>
  39. </div>
  40. <!-- 足迹导航栏 -->
  41. </div>
  42. <div class="ey-container">
  43. <div class="ey-con">
  44. <!-- 中部 -->
  45. <div class=" pro-list">
  46. {eyou:empty name="$list"}
  47. <div class="ey-row min-hg-c-92 flex flex-center">
  48. <div class="tc mt-92">
  49. <p class=""><img id='litpic_img' src="{eyou:static file='users/skin/images/null-data.png' /}"/></p>
  50. <p class="fc9">当前暂无兑换商品哦~</p>
  51. </div>
  52. </div>
  53. {eyou:else/}
  54. <div class="ey-row min-hg-c-92 bgfff ptb0">
  55. {eyou:volist name="$list" id="vo" key="k"}
  56. <div class="balances">
  57. <a class="balances-pic" href="{:url('user/Memgift/users_gift_detail',['gift_id'=>$vo.gift_id])}">
  58. <img class="pic" src="{$vo.litpic}">
  59. </a>
  60. <div class="balances-info">
  61. <div class="title">
  62. <a href="{:url('user/Memgift/users_gift_detail',['gift_id'=>$vo.gift_id])}">{$vo.giftname}</a>
  63. </div>
  64. <div><span>{$vo.score}{$score_name}</span></div>
  65. </div>
  66. <div class="balances-num">
  67. {eyou:if condition='$users.scores >= $vo.score'}
  68. {eq name='$vo.type' value='-1'}
  69. <a href="javascript:void(0)" class="okgo" data-url="{:url('user/Memgift/users_gift_shiwu',['gift_id'=>$vo.gift_id])}" onclick="jumpInfo(this)">立即兑换</a>
  70. {else/}
  71. <a href="javascript:void(0)" class="okgo" data-url="{:url('user/Memgift/users_gift_vip',['gift_id'=>$vo.gift_id])}" onclick="jumpVip(this)">立即兑换</a>
  72. {/eq}
  73. {eyou:else /}
  74. <a class="okgo nones">{$score_name}不足</a>
  75. {/eyou:if}
  76. </div>
  77. </div>
  78. {/eyou:volist}
  79. </div>
  80. {/eyou:empty}
  81. </div>
  82. <div class="order-list" style="display: none;">
  83. {eyou:empty name="$order_list"}
  84. <div class="ey-row min-hg-c-92 flex flex-center">
  85. <div class="tc mt-92">
  86. <p class=""><img id='litpic_img' src="{eyou:static file='users/skin/images/null-data.png' /}"/></p>
  87. <p class="fc9">当前暂无兑换商品哦~</p>
  88. </div>
  89. </div>
  90. {eyou:else/}
  91. <div class="ey-row min-hg-c-92 bgfff ptb0">
  92. {eyou:volist name="$order_list" id="vo" }
  93. <div class="balances">
  94. <div class="balances-pic">
  95. <img class="pic" src="{$vo.litpic}">
  96. </div>
  97. <div class="balances-info">
  98. <div class="title">
  99. {$vo.giftname}
  100. </div>
  101. <div><span class="mr10">{$vo.score}{$score_name}{eyou:if condition="$vo.status eq 2"}[{$score_name}已返还]{/eyou:if}</span><span>{$vo.add_time|MyDate="Y-m-d H:i",###}</span></div>
  102. </div>
  103. <div class="list_z tc">
  104. {eyou:if condition="$vo.status eq 1"}
  105. <span style="color: #67c23a">已发货</span>
  106. {elseif condition="$vo.status eq 2"}
  107. <span style="color: #F00">发货取消</span>
  108. {else /}
  109. <span style="color: #333">待发货</span>
  110. {/eyou:if}
  111. </div>
  112. </div>
  113. {/eyou:volist}
  114. </div>
  115. {/eyou:empty}
  116. </div>
  117. </div>
  118. </div>
  119. <script>
  120. function changeGift(n) {
  121. if (1 == n){
  122. $('#a_changeGift1').addClass('active');
  123. $('#a_changeGift2').removeClass('active');
  124. $('.pro-list').show();
  125. $('.order-list').hide();
  126. } else{
  127. $('#a_changeGift2').addClass('active');
  128. $('#a_changeGift1').removeClass('active');
  129. $('.pro-list').hide();
  130. $('.order-list').show();
  131. }
  132. }
  133. //兑换实物
  134. function jumpInfo(obj){
  135. var url = $(obj).data('url');
  136. var index = layer.open({
  137. type: 2,
  138. id: 'iframe_goinfo',
  139. title: '填写快递信息',
  140. fixed: true, //不固定
  141. shadeClose: false,
  142. shade: [0.3,'#000'],
  143. maxmin: false, //开启最大化最小化按钮
  144. closeBtn: 1,
  145. area: ['90%','288px'],
  146. content: url
  147. });
  148. }
  149. //打开详情页
  150. function goDetail(obj) {
  151. //iframe窗
  152. var url = $(obj).data('url');
  153. var index = layer.open({
  154. type: 2,
  155. id: 'iframe_goDetail',
  156. title: '商品详情',
  157. fixed: true, //不固定
  158. shadeClose: false,
  159. shade: [0.3, '#000'],
  160. maxmin: false, //开启最大化最小化按钮
  161. closeBtn: 1,
  162. area: ['700px', '99%'],
  163. content: url,
  164. });
  165. }
  166. //兑换会员
  167. function jumpVip(obj) {
  168. var url = $(obj).data('url');
  169. layer.confirm('确定要兑换商品?', {
  170. skin: 'xin-demo-btn',
  171. closeBtn: 0,
  172. shadeClose: true
  173. }, function() {
  174. $.ajax({
  175. url: url,
  176. type: 'POST',
  177. dataType: 'JSON',
  178. data: {
  179. long: 0
  180. },
  181. success: function(res) {
  182. if (1 == res.code) {
  183. layer.msg(res.msg, {
  184. icon: 1,
  185. time: 1000
  186. }, function() {
  187. window.location.reload();
  188. });
  189. } else if (res.code == 2) {
  190. layer.confirm(res.msg, {
  191. btn: ['继续兑换', '取消'] //按钮
  192. }, function() {
  193. $.ajax({
  194. url: url,
  195. type: 'POST',
  196. dataType: 'JSON',
  197. data: {
  198. long: 1
  199. },
  200. success: function(res) {
  201. if (1 == res.code) {
  202. layer.msg(res.msg, {
  203. icon: 1,
  204. time: 1000
  205. }, function() {
  206. window.location.reload();
  207. });
  208. } else {
  209. layer.msg(res.msg, {
  210. icon: 2,
  211. time: 2000
  212. });
  213. }
  214. },
  215. error: function(e) {
  216. layer.closeAll();
  217. layer.alert(e.responseText, {
  218. icon: 5,
  219. title: false
  220. });
  221. }
  222. })
  223. });
  224. } else {
  225. layer.msg(res.msg, {
  226. icon: 2,
  227. time: 2000
  228. });
  229. }
  230. },
  231. error: function(e) {
  232. layer.closeAll();
  233. layer.alert(e.responseText, {
  234. icon: 5,
  235. title: false
  236. });
  237. }
  238. })
  239. }, function(index) {
  240. layer.closeAll(index);
  241. });
  242. }
  243. </script>
  244. <!-- END -->