index_1002.html 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141
  1. <extend name="Public:pinduoduobase" />
  2. <block name="content">
  3. <link rel="stylesheet" href="__PUBLIC__/pinduoduo/assets/css/index.css">
  4. <div id="main">
  5. <div id="index-content" class="container">
  6. {~W('GoodsCategory/goods_category_show')}
  7. <div id="rp-banner">
  8. <?php if($is_sub == 0){ ?>
  9. <section class="m-component-download clearfix" id="downloadApp">
  10. <span class="pull-left">
  11. <a href="{$sub_url}">
  12. <img class="m-img " src="Uploads/image/{$site_logo}">
  13. </a>
  14. </span>
  15. <span class="pull-left m-tips">{$site_title}<br>{$site_name}</span>
  16. <span class="pull-right m-btn">
  17. <a href="{$sub_url}" class="app_btn" role="button" name="apk_url">立刻关注</a>
  18. </span>
  19. </section>
  20. <?php } ?>
  21. <!-- banner begin -->
  22. {~W('Slider/slider_show')}
  23. <!--banner end -->
  24. <?php if(!empty($quan_list)) { ?>
  25. <div class="mall-coupons">
  26. <div class="mall_all_goods">优惠券</div>
  27. <div class="mall-coupons-list-wrapper">
  28. <ul class="mall-coupon-list">
  29. <?php foreach($quan_list as $quan) { ?>
  30. <li class="mall-coupons-detail">
  31. <img src="__PUBLIC__/pinduoduo/assets/img/mall_coupon_available_bg.png">
  32. <div class="coupon-left">
  33. <div class="coupon-discount">
  34. ¥<?php echo round($quan['credit'],0); ?>
  35. </div>
  36. <?php if($quan['limit_money'] > 0) { ?>
  37. <div class="coupon-min-custom">
  38. 满<?php echo $quan['limit_money']; ?>元立减
  39. </div>
  40. <?php } ?>
  41. </div>
  42. <div class="coupon-right">
  43. <div class="coupon-take" data-id="<?php echo $quan['id']; ?>">领取</div>
  44. <div class="coupon-expire-time"><?php echo date('Y.m.d',$quan['end_time']); ?>过期</div>
  45. </div>
  46. </li>
  47. <?php } ?>
  48. </ul>
  49. </div>
  50. </div>
  51. <?php } ?>
  52. <!-- Subject begin -->
  53. {~W('Subject/hot_subject_show')}
  54. <!-- Subject end -->
  55. {~W('Slider/slider_show_list')}
  56. <!-- Product begin -->
  57. <include file="Widget:index_ajax_goods_list" />
  58. <!-- Product end -->
  59. </div>
  60. </div>
  61. </div>
  62. <style>
  63. .m-component-download {
  64. padding: 10px;
  65. background: #fff;
  66. position: relative;
  67. overflow: hidden;
  68. }
  69. .pull-left {
  70. float: left;
  71. }
  72. .m-component-download .m-img {
  73. display: inline;
  74. width: 50px;
  75. height: 50px;
  76. }
  77. .m-component-download .m-tips {
  78. float: left!important;
  79. margin: 4px 0 0 10px;
  80. font-size:15px;
  81. }
  82. .pull-right {
  83. float: right;
  84. }
  85. .m-component-download .m-btn {
  86. margin: 4px 0 0 10px;
  87. }
  88. .m-component-download .app_btn, .m-component-download .tf_app_btn {
  89. color: #fff;
  90. background-color: #5cb85c;
  91. border-color: #4cae4c;
  92. display: inline-block;
  93. margin-bottom: 0;
  94. font-weight: 400;
  95. text-align: center;
  96. vertical-align: middle;
  97. -ms-touch-action: manipulation;
  98. touch-action: manipulation;
  99. cursor: pointer;
  100. background-image: none;
  101. border: 1px solid transparent;
  102. white-space: nowrap;
  103. font-size: 14px;
  104. line-height: 1.42857143;
  105. border-radius: 4px;
  106. }
  107. .m-component-download .app_btn {
  108. padding: 6px 12px;
  109. }
  110. </style>
  111. <include file="Widget:pin_notify" />
  112. {~W('Share/common_share')}
  113. <include file="Widget:pin_toast" />
  114. <include file="Public:foot_lazy" />
  115. <include file="Public:foot_pinduoduo" />
  116. <script>
  117. $(function(){
  118. $('.coupon-take').click(function(){
  119. var quan_id = $(this).attr('data-id');
  120. $.ajax({
  121. url:"{:U('Seller/getQuan')}",
  122. type:'post',
  123. data:{quan_id:quan_id},
  124. dataType:'json',
  125. success:function(result){
  126. showTip(result.msg);
  127. }
  128. })
  129. })
  130. })
  131. </script>
  132. </block>