hot.wxml 7.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127
  1. <template name="hot">
  2. <!-- <view class="messageSection" wx:if="{{hotData.unReadMessageNum > 0}}" bindtap="goToMessage"> -->
  3. <!-- <view class="marquee">
  4. <view class="content">
  5. <text>【新春派兑】小红花兑换乐高玩具,6666朵小红花可兑换价值约500元的乐高积木玩具,2月26日兑换。</text>
  6. <text style="display: inline-block; width: 5em;"></text>
  7. <text>【新春派兑】小红花兑换乐高玩具,6666朵小红花可兑换价值约500元的乐高积木玩具,2月26日兑换。</text>
  8. <text style="display: inline-block; width: 5em;"></text>
  9. <text>【新春派兑】小红花兑换乐高玩具,6666朵小红花可兑换价值约500元的乐高积木玩具,2月26日兑换。</text>
  10. <text style="display: inline-block; width: 5em;"></text>
  11. </view>
  12. </view> -->
  13. <!-- <view class="messageSection" >
  14. <image class="messageIcon" src="../../static/image/message_icon.png" />
  15. <view class="marquee">
  16. <view class="content">
  17. <text>{{hotData.unReadMessageContent}}</text>
  18. <text style="display: inline-block; width: 5em;"></text>
  19. <text>{{hotData.unReadMessageContent}}</text>
  20. <text style="display: inline-block; width: 5em;"></text>
  21. <text>{{hotData.unReadMessageContent}}</text>
  22. <text style="display: inline-block; width: 5em;"></text>
  23. </view>
  24. </view>
  25. </view> -->
  26. <!-- <view class="messageSection" bindtap="goToMessage" wx:if="{{hotData.unReadMessageContent !== ''}}">
  27. <image class="messageIcon" src="../../static/image/message_icon.png" />
  28. <text class="messageText">{{hotData.unReadMessageContent}}</text>
  29. </view> -->
  30. <!-- <view class="myCourseSection" bindtap="clickBaidu">
  31. <!-- <view class="title">
  32. <view class="title-regular">我的课程</view>
  33. <view class="right" bindtap="toMyCourse" wx:if="{{hotData.myCourse.length > 3}}">
  34. 更多
  35. <image src="../../static/image/black_to.png" />
  36. </view>
  37. </view> -->
  38. <!-- <view class="myCoursePlaceHolder" wx:if="{{hotData.myCourse.length === 0}}" bindtap="goToBooks">
  39. <image src="../../static/image/add_class.png" />
  40. </view> -->
  41. <view class="myCoursePlaceHolder">
  42. <image src="https://reader.image.lingjiao.cn/reader/resource/baidu_img.png" />
  43. </view>
  44. <!-- <view class="book-box" wx:if="{{hotData.myCourse.length !== 0}}">
  45. <block wx:for="{{hotData.myCourse}}" wx:key="{{index}}">
  46. <view class="book-item" data-id="{{item.productId}}" bindtap="goToBook" data-title="{{item.title}}">
  47. <image class="book-img" src="{{item.iconImg}}"></image>
  48. <view class="book-title">{{item.title}}</view>
  49. </view>
  50. </block>
  51. </view> -->
  52. <!-- </view> -->
  53. <view class="searchSection">
  54. <input bindinput="inputHandler" value="{{hotData.inputValue}}" focus="{{hotData.inputFocus}}" bindfocus="searchIconDisappear" bindblur="searchIconCome" bindconfirm="searchHandler" placeholder="{{hotData.hotSearch}}" placeholder-style="text-indent:20rpx" confirm-type="search"></input>
  55. <view>{{searchIcon}}</view>
  56. <view bindtap="inputFocus" class="searchBtn" wx:if="{{hotData.searchIcon}}">
  57. <!-- <icon type="search" size="14" /> -->
  58. <image src="../../static/image/search_new.png" alt="" />
  59. </view>
  60. <view class="allBooks" bindtap="goToBooks">全部课程</view>
  61. <!-- <form bindsubmit="submitTest" report-submit="{{true}}" class="allBooks">
  62. <button formType="submit">Reset</button>
  63. </form> -->
  64. </view>
  65. <view class="swiperSection">
  66. <view class="title-regular swiper-title">官方推荐</view>
  67. <swiper previous-margin="0" next-margin="243rpx" bindchange="swiperChange" current="{{hotData.swiperCurrent}}" circular="{{true}}" autoplay="{{hotData.autoplay}}" interval="{{hotData.interval}}" duration="{{hotData.duration}}" circular="{{hotData.circular}}">
  68. <block wx:for="{{hotData.recommend}}" wx:key="{{index}}">
  69. <swiper-item class="slide-item" bindtap="openClass" data-classId="{{item.classId}}" data-title="{{item.title}}">
  70. <image src="{{item.img}}" data-type="{{item.type}}" data-id="{{item.id}}" class="slide-image" />
  71. <view class="slide-summary">
  72. <text class="slide-title">{{item.title}}</text>
  73. <text class="slide-tip">{{item.summary}}</text>
  74. </view>
  75. </swiper-item>
  76. </block>
  77. </swiper>
  78. <view class="swiper-dots-wrapper">
  79. <block wx:for="{{hotData.recommend}}" wx:key="{{index}}">
  80. <view class="swiper-dots {{hotData.swiperCurrent === index ? 'dot-active' : ''}}">
  81. <text>{{index + 1}}</text>
  82. </view>
  83. </block>
  84. </view>
  85. </view>
  86. <view class="recommdSection">
  87. <view class="recommd-title">热门作品</view>
  88. <view class="hotWares">
  89. <view wx:for="{{hotData.hotWorks}}" wx:key="{{index}}" class="worksCard" bindtap="openWorks" data-readId="{{item.classId}}" data-title="{{item.title}}">
  90. <view class="topData">
  91. <view class="worksLeft" catchtap="goToUsers" data-uid="{{item.uid}}">
  92. <image class="authorAvatar" lazy-load="true" src="{{item.avatar}}" />
  93. <view class="profession" wx:if="{{item.profession}}">
  94. {{item.profession}}
  95. </view>
  96. <view class="worksInfo">
  97. <view class="authorName">{{item.nickName}}</view>
  98. <view class="time">{{item.time}}</view>
  99. </view>
  100. </view>
  101. <view class="numberInfo">
  102. <view class="wareCardPlays">
  103. <image class="wareCardPlaysImg" lazy-load="true" src="../../static/image/hotPlays.png" />
  104. <text>{{item.plays}}</text>
  105. </view>
  106. <view class="wareCardLikes">
  107. <image class="wareCardLikesImg" lazy-load="true" src="../../static/image/flower_small_pink.png" />
  108. <text>{{item.likes}}</text>
  109. </view>
  110. </view>
  111. </view>
  112. <image class="wareCardImg" src="{{item.img}}" />
  113. <view class="titleSummary">
  114. <text class="wareCardTitle">{{item.title}}</text>
  115. <text class="wareCardTip">{{item.summary}}</text>
  116. </view>
  117. </view>
  118. </view>
  119. </view>
  120. <!--小度广告海报-->
  121. <view class="xiaodu-dialog" bindtap="xiaoduClick" wx:if="{{hotData.baiduFlag}}">
  122. <image class="dialog-img" lazy-load="true" src="https://reader.image.lingjiao.cn/reader/resource/海报.png" />
  123. <view class="dialog-circle" catchtap="PreservationXiaodu">
  124. <text>点我保存到相册,识别二维码</text>
  125. </view>
  126. </view>
  127. </template>