gifts.html 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132
  1. <{include file="header.html"}>
  2. <link rel="stylesheet" type="text/css" href="<{$web_cfg.cdn}>/haili/css/prizelist.css" />
  3. <!--公用标题居中显示-->
  4. <{include file="common_header.html"}>
  5. <section class="prizelist">
  6. <{if $data}>
  7. <h2>您参与活动获得的奖品</h2>
  8. <{else}>
  9. <h2>您还没有获得奖品</h2>
  10. <{/if}>
  11. <{if $data}>
  12. <div class="gifts_list">
  13. <{foreach from=$newData item=v}>
  14. <dl>
  15. <dt><a href="<{$v.url}>"><img src="<{if $v.events_type==6&&$v.prize_type==2}><{$web_cfg.cdn}><{$v.prize_img_url}><{else}><{$v.prize_img_url}><{/if}>"></a></dt>
  16. <dd><p><{$v.prize_name}></p>
  17. <{if $v.feedback == 4}>
  18. <a class="red" href="<{$web_cfg.domain}>/?c=Express&lottery_data_id=<{$v.lottery_data_id}>">填写收货地址</a>
  19. <{elseif $v.feedback == 3}>
  20. <{if $v.events_type==6}>
  21. <a href="<{$v.virtual_data}>">查看二维码</a>
  22. <{else}>
  23. <a href="<{$web_cfg.domain}>/?c=FeedBack&lottery_data_id=<{$v.lottery_data_id}>">查看或修改评价</a>
  24. <{/if}>
  25. <{elseif $v.feedback == 2}>
  26. <a href="<{$web_cfg.domain}>/?c=FeedBack&lottery_data_id=<{$v.lottery_data_id}>">发表试用评价</a>
  27. <{elseif $v.feedback == 5}>
  28. <span class="disable">已过期</span>
  29. <{/if}>
  30. <{if $v.prize_type==2}>
  31. <{if $v.events_type==6}>
  32. <a href="<{$v.virtual_data}>">查看二维码</a>
  33. <{else}>
  34. <span>券:<{$v.virtual_data}></span>
  35. <{/if}>
  36. <{/if}>
  37. <{if $v.prize_express==1}>
  38. <{if $thisTime < $v.end_time_receive_prizes && $v.events_delivery==1 && !$v.express}>
  39. <a class="red" href="<{$web_cfg.domain}>/?c=Express&lottery_data_id=<{$v.lottery_data_id}>">填写收货地址</a>
  40. <{else}>
  41. <{if $thisTime > $v.end_time_receive_prizes && $v.express && $v.events_delivery==2}>
  42. <span>已发货</span>
  43. <{/if}>
  44. <{if $thisTime > $v.end_time_receive_prizes && !$v.express && $v.events_delivery==2 }>
  45. <span class="disable">已过期</span>
  46. <{/if}>
  47. <{/if}>
  48. <{/if}>
  49. </dd>
  50. </dl>
  51. <{/foreach}>
  52. <div class="clear"></div>
  53. <div class="loading">
  54. <img
  55. id="loadPage"
  56. src="<{$web_cfg.cdn}>/public/static/img/loading.gif"
  57. data-ks-lazyload="<{$web_cfg.cdn}>/public/static/img/loading.gif"
  58. data-request-url="<{$web_cfg.domain}>/?c=Member&a=ajax"
  59. data-page="2"
  60. data-totals="<{$totals}>"
  61. style="width:0px;"
  62. />
  63. <div class="loader-inner ball-pulse">
  64. <div></div><div></div><div></div><div></div><div></div><div></div>
  65. </div>
  66. </div>
  67. </div>
  68. <{/if}>
  69. </section>
  70. <{if $data}>
  71. <script>
  72. KISSY.use('node, io, gallery/datalazyload/2.0/index', function (S, Node, IO, Datalazyload) {
  73. var lock = false;
  74. new Datalazyload({
  75. load: function(el){
  76. if (lock) return false;
  77. lock = true;
  78. var requesrUrl = $(el).data('request-url');
  79. var page = Number($(el).data('page'));
  80. var totals = Number($(el).data('totals'));
  81. if (!requesrUrl) {
  82. return false;
  83. }
  84. if (page > totals) {
  85. $('.loading').hide();
  86. return false;
  87. }
  88. IO.get(
  89. requesrUrl
  90. , {page: page}
  91. , function (data) {
  92. if (data.ok) {
  93. var next_page = page + 1;
  94. $('#loadPage').data('page', next_page);
  95. $(".gifts_list").append(data.msg);
  96. lock = false;
  97. //new Datalazyload();
  98. if (next_page > totals) {
  99. $('.up_icon').hide();
  100. }
  101. }
  102. }
  103. , 'json'
  104. );
  105. }
  106. });
  107. });
  108. //有产品列表时添加整体body背景色
  109. $(body).addClass("bg_white");
  110. </script>
  111. <{/if}>
  112. <{include file="bottom.html"}>