my_act.html 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113
  1. <{include file="header.html"}>
  2. <link rel="stylesheet" type="text/css" href="<{$web_cfg.cdn}>/haili/css/index.css" />
  3. <style>
  4. .vogue_top_list img {
  5. background: #fff url("<{$web_cfg.cdn}>/public/static/img/m-load.gif") no-repeat scroll 50% center / 20px 20px;
  6. }
  7. </style>
  8. <header><a href="javascript:history.go(-1)" class="back"></a>我参与的活动</header>
  9. <{if $eventsData}>
  10. <section class="cardlist first-module">
  11. <{foreach from=$eventsData item=events}>
  12. <dl class="noborder">
  13. <dt><a href="<{$events.url}>"><img src="<{$web_cfg.cdn}>/public/static/img/bg_alpha.png" data-ks-lazyload="<{$events.img_url}>"></a></dt>
  14. <dd><h5><{$events.events_name}></h5></dd>
  15. <dd>
  16. <{if $events.rday>=1}>
  17. <span class="time">
  18. <em class="icon-time"></em>剩余<{$events.rday}>天</span>
  19. <{elseif $events.type != 9}>
  20. <span class="time">
  21. <em class="icon-time"></em>已结束</span>
  22. <{/if}>
  23. <{if $events.type == 9}>
  24. <span>阅读 <{$events.click_num}></span>
  25. <span>点赞 <{$events.likes}></span>
  26. <{else}>
  27. <span>参与<{$events.user_total}>人</span>
  28. <{/if}>
  29. </dd>
  30. </dl>
  31. <{/foreach}>
  32. </section>
  33. <{/if}>
  34. <div class="clear"></div>
  35. <{if $totals}>
  36. <div class="loading">
  37. <img
  38. id="loadPage"
  39. data-ks-lazyload="<{$web_cfg.cdn}>/public/static/img/loading_new.gif"
  40. data-request-url="<{$web_cfg.domain}>/?c=member&a=actajax&plat_form_id=<{$plat_form_id}>&url=<{$url}>"
  41. data-page="2"
  42. data-totals="<{$totals}>"
  43. style="width:0px;"
  44. />
  45. <div class="loader-inner ball-pulse">
  46. <div></div><div></div><div></div><div></div><div></div><div></div>
  47. </div>
  48. </div>
  49. <{/if}>
  50. <script>
  51. KISSY.use('node, io, gallery/datalazyload/2.0/index', function (S, Node, IO, Datalazyload) {
  52. var $ = S.all;
  53. var lock = false;
  54. new Datalazyload({
  55. load: function(el){
  56. el = '#loadPage';
  57. if (lock) return false;
  58. lock = true;
  59. var requesrUrl = $(el).attr('data-request-url');
  60. var page = Number($(el).attr('data-page'));
  61. var totals = Number($(el).attr('data-totals'));
  62. if (!requesrUrl) {
  63. lock = false;
  64. return false;
  65. }
  66. if (page > totals) {
  67. $('.loading').hide();
  68. return false;
  69. }
  70. IO.get(
  71. requesrUrl
  72. , {page: page}
  73. , function (data) {
  74. if (data.ok) {
  75. var next_page = page + 1;
  76. $('#loadPage').attr('data-page', next_page);
  77. var new_dl = $(data.msg);
  78. $(".cardlist").append(new_dl);
  79. new Datalazyload();
  80. lock = false;
  81. if (next_page > totals) {
  82. $('.loading').hide();
  83. }
  84. }
  85. }
  86. , 'json'
  87. );
  88. }
  89. });
  90. });
  91. //判断当前页图片加载完成loading消失
  92. /* $(".vogue_top_list").find("img").load(function(){
  93. $(this).parent().css("background","none");
  94. }); */
  95. </script>
  96. <{include file="bottom.html"}>
  97. <script type="text/javascript" src="<{$web_cfg.cdn}>/haili/js/list.js"></script>