order_pink.html 9.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192
  1. {extend name="public/container"}
  2. {block name='title'}我的拼团详情{/block}
  3. {block name="head_top"}
  4. <style>
  5. body {
  6. background-color: #f5f5f5;
  7. }
  8. </style>
  9. {/block}
  10. {block name="content"}
  11. <div v-cloak id="app">
  12. <div class="assemble">
  13. <div class="header acea-row row-between-wrapper">
  14. <div class="item">
  15. <div class="iconfont icon-weixinzhifu"></div>
  16. <div>1.支付成功</div>
  17. </div>
  18. <div class="iconfont icon-icon-yxj-arrow-right"></div>
  19. <div class="item">
  20. <div class="iconfont icon-yaoqing-"></div>
  21. <div>2.邀请朋友参团</div>
  22. </div>
  23. <div class="iconfont icon-icon-yxj-arrow-right"></div>
  24. <div class="item">
  25. <div class="iconfont icon-bofang1 acea-row row-center-wrapper"></div>
  26. <div>3.上课啦</div>
  27. </div>
  28. </div>
  29. <div class="teamwork">
  30. <div class="list acea-row row-center-wrapper">
  31. <div class="pictrue">
  32. <img src="{__WAP_PATH}zsff/images/king.png" class="king">
  33. <img :src="pinkT.avatar">
  34. </div>
  35. <div class="pictrue" v-for="item in pinkAll"><img :src="item.avatar"></div>
  36. <div class="pictrue" v-for="item in count"><img src="{__WAP_PATH}zsff/images/symbol.png"></div>
  37. </div>
  38. <div class="tiptime" v-if="count && pinkBool!=1">仅剩{{count}}人,剩余时间<span class="time">{{hour}}: {{minute}}: {{second}}</span></div>
  39. <div class="tiptime" v-else>拼团成功,快去学习吧!</div>
  40. <div class="label acea-row row-center-wrapper" v-if="!pinkBool">正在拼团</div>
  41. <div class="label acea-row row-center-wrapper" v-else-if="pinkBool==1">拼团成功</div>
  42. <div class="label acea-row row-center-wrapper" v-else-if="pinkBool > 1 && pinkBool < 4">拼团失败</div>
  43. <div class="label acea-row row-center-wrapper" v-else-if="pinkBool==6">拼团人数已满</div>
  44. </div>
  45. <div class="my-course">
  46. <div class="swiper-list2">
  47. <div class="item acea-row">
  48. <a class="pictrue" :href="getTashUrl(special.id)"><img :src="special.image"></a>
  49. <div class="text-pic">
  50. <div class="name line1" v-text="special.title" :href="getTashUrl(special.id)"></div>
  51. <div class="label acea-row row-middle">
  52. <div class="num acea-row row-center-wrapper" v-for="(vo,index) in special.label" v-text="vo" v-if="index < min"></div>
  53. </div>
  54. <!-- <div class="money">{{special.is_pink ? (special.pink_money == 0 ? '免费':'¥'+special.pink_money): (special.money <= 0 ? '免费':'¥'+special.money) }}</div> -->
  55. <div class="bottom acea-row row-middle">
  56. <template v-if="special.is_pink">
  57. <div v-if="special.pink_money === '0.00'" class="free">免费</div>
  58. <div v-else class="money">¥<span>{{ special.pink_money }}</span></div>
  59. </template>
  60. <template v-else>
  61. <div v-if="special.money === '0.00'" class="free">免费</div>
  62. <div v-else class="money">¥<span>{{ special.money }}</span></div>
  63. </template>
  64. </div>
  65. </div>
  66. </div>
  67. </div>
  68. </div>
  69. <div class="initiate-group">
  70. <div class="acea-row row-center-wrapper" v-if="!pinkBool">
  71. <a class="bnt invite acea-row row-center-wrapper" style="margin: 0 auto;width: 7rem;" :href="goPosterShow()"> {{is_help ? '帮助他完成拼团':'邀请朋友拼课'}}</a>
  72. </div>
  73. <div class="acea-row row-center-wrapper" v-else-if="pinkBool==1">
  74. <a class="bnt invite acea-row row-center-wrapper" style="margin: 0 auto;width: 7rem;" :href="getTashUrl(special.id,true)">去学习</a>
  75. </div>
  76. <div class="acea-row row-center-wrapper" v-else-if="pinkBool==2">
  77. <div class="bnt invite acea-row row-center-wrapper" style="margin: 0 auto;width: 7rem;">拼团时间已到,退款中</div>
  78. </div>
  79. <div class="acea-row row-center-wrapper" v-else-if="pinkBool==3">
  80. <div class="bnt invite acea-row row-center-wrapper" style="margin: 0 auto;width: 7rem;">拼团已结束,请您参加别的拼团</div>
  81. </div>
  82. <div class="acea-row row-center-wrapper" v-else-if="pinkBool==6">
  83. <div class="bnt invite acea-row row-center-wrapper" style="margin: 0 auto;width: 7rem;">拼团人数已满,等待订单状态</div>
  84. </div>
  85. </div>
  86. <div class="shares-model" v-show="shares" @click="shares=false">
  87. <img style="position: fixed;left: 0;top: 0;width: 100%;height: 100%;" src="{__WAP_PATH}zsff/images/share-info.png">
  88. </div>
  89. {if !$subscribe && !empty($userInfo)}
  90. <div class="publicFollow acea-row row-between-wrapper">
  91. <div>关注公众号"{$Auth_site_name}",看课更方便</div>
  92. <div class="follow acea-row row-center-wrapper" @click=" is_code = true ">关注</div>
  93. </div>
  94. <div class="mask" style="align-items:center;display: flex;" v-show="is_code" @click="is_code=false">
  95. <img :src="wechat_qrcode" alt="" style="width: 5rem;height: 5rem;margin: 0 auto;">
  96. </div>
  97. <div style="height: 1.0rem"></div>
  98. {/if}
  99. </div>
  100. <shortcut></shortcut>
  101. </div>
  102. {/block}
  103. {block name='foot'}
  104. <script>
  105. var pink_id={$pink_id},is_help = {$is_help},wechat_qrcode = '{$subscribeQrcode}';
  106. window.overallShare=false;
  107. require(['vue','helper','store','{__WAP_PATH}zsff/js/shortcut.js'],function(Vue,$h,app) {
  108. new Vue({
  109. el: '#app',
  110. data: {
  111. special:{},
  112. pinkT:{},
  113. pinkAll:[],
  114. count:0,
  115. hour:"00",
  116. minute:"00",
  117. second:"00",
  118. shares:false,
  119. datatime:0,
  120. pinkBool:0,
  121. userBool:0,
  122. min:2,
  123. is_help:is_help,
  124. wechat_qrcode:wechat_qrcode,
  125. is_code: true,
  126. },
  127. methods:{
  128. goPosterShow:function(){
  129. return $h.U({c:'special',a:'poster_show',q:{special_id:this.special.id,pinkId:pink_id,is_help:is_help}});
  130. },
  131. getTashUrl:function(id,isAtn){
  132. return $h.U({c:'special',a:'details',q:{id:id}})+(isAtn ? '#tash' : '');
  133. },
  134. getPinkInfo:function () {
  135. var that=this;
  136. app.baseGet($h.U({c:'special',a:'get_pink_info',q:{pinkId:pink_id}}),function (res) {
  137. var data=res.data.data;
  138. that.$set(that,'pinkT',data.pinkT);
  139. that.$set(that,'pinkAll',data.pinkAll);
  140. that.$set(that,'special',data.special);
  141. that.count=data.count < 0 ? 0 : data.count;
  142. that.pinkBool=data.pinkBool;
  143. that.userBool=data.userBool;
  144. that.datatime=data.pinkT.stop_time;
  145. that.show_time();
  146. mapleWx($jssdk(), function () {
  147. this.onMenuShareAll({
  148. title:'仅差'+that.count+'人拼课成功! ['+that.special.title+']' ,
  149. desc: that.special.abstract,
  150. imgUrl: that.special.image,
  151. link: that.special.link
  152. });
  153. });
  154. },function (msg) {
  155. $h.pushMsgOnce(msg,function () {
  156. window.location.href=$h.U({c:'my',a:'order_list'});
  157. })
  158. },true);
  159. },
  160. show_time:function(){
  161. var that = this;
  162. function nowTime() {
  163. var intDiff = that.datatime - Date.parse(new Date()) / 1000;
  164. var days = 0, hour = 0, minute = 0, second = 0;
  165. if (intDiff > 0) {
  166. hour = Math.floor(intDiff / (60 * 60)) - (days * 24);
  167. minute = Math.floor(intDiff / 60) - (hour * 60);
  168. second = Math.floor(intDiff) - (hour * 60 * 60) - (minute * 60);
  169. if (hour <= 9) hour = '0' + hour;
  170. if (minute <= 9) minute = '0' + minute;
  171. if (second <= 9) second = '0' + second;
  172. that.hour=hour;
  173. that.minute=minute;
  174. that.second=second;
  175. } else {
  176. that.hour="00";
  177. that.minute="00";
  178. that.second="00";
  179. clearInterval(timer);
  180. }
  181. }
  182. nowTime();
  183. var timer = setInterval(nowTime, 1000);
  184. }
  185. },
  186. mounted:function () {
  187. this.getPinkInfo();
  188. }
  189. })
  190. })
  191. </script>
  192. {/block}