book_classification.wxml 3.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. <import src="../../../templates/nodata/nodata.wxml" />
  2. <import src="../../../templates/loading/loading.wxml" />
  3. <view class='container'>
  4. <template is='loading' wx:if='{{!isLoaded}}'></template>
  5. <view class='wrapper' wx:else>
  6. <view class='li'>
  7. <block wx:if='{{isClass}}'>
  8. <view class='li-book'>
  9. <view class='li-book-title'>主题</view>
  10. <view class='li-book-items'>
  11. <view class='li-book-item' wx:for='{{themeList}}' wx:key='index' data-type='{{1}}' data-code='{{item.code}}' data-theme='{{item.name}}' wx:if='{{index!=0}}' bindtap='selectTheme'>{{item.name}}</view>
  12. </view>
  13. </view>
  14. <view class='li-book'>
  15. <view class='li-book-title'>年段</view>
  16. <view class='li-book-items'>
  17. <view class='li-book-item' wx:for='{{gradeList}}' data-type='{{0}}' wx:if='{{index!=0}}' data-theme='{{item}}' wx:key='index' bindtap='selectTheme'>{{item}}</view>
  18. </view>
  19. </view>
  20. </block>
  21. <block wx:if='{{!isClass}}'>
  22. <view class='li-book'>
  23. <view class='li-book-title'>{{theme}}</view>
  24. <scroll-view scroll-x="true" style='width:100%;'>
  25. <view class='li-theme'>
  26. <view wx:if='{{!isTheme}}' wx:for='{{themeList}}' wx:key='index' data-index='{{index}}' data-code='{{item.code}}' class='li-theme-item {{themeIdx==index?"li-theme-active":""}}' bindtap='selectOne'>{{item.name}}</view>
  27. <view wx:if='{{isTheme}}' wx:for='{{gradeList}}' wx:key='index' data-theme='{{item}}' data-index='{{index}}' class='li-theme-item {{themeIdx==index?"li-theme-active":""}}' bindtap='selectTwo'>{{item}}</view>
  28. </view>
  29. </scroll-view>
  30. <view class='list-items'>
  31. <view class='list-item' wx:for='{{list}}' wx:key='index' data-url='parents/pages/book_detail/book_detail' data-zindex='3' data-paras='{{({bookInfoId: item.bookInfoId})}}' bindtap='navigateTo'>
  32. <view class='list-item-img'>
  33. <image src='{{item.localImage?baseImgUrl+item.localImage:"../../../assets/banner1.png"}}' class='list-item-img-items'></image>
  34. </view>
  35. <view class='list-item-content'>
  36. <view class='list-item-content-title'>{{item.title}}</view>
  37. <view class='list-item-content-tips'>{{item.summary}}</view>
  38. <view class='list-item-content-label'>
  39. <view class='list-item-content-label-one' wx:if='{{item.themeName}}'>{{item.themeName}}</view>
  40. <view class='list-item-content-label-two' wx:if='{{item.grade}}'>推荐{{item.grade}}</view>
  41. </view>
  42. <view>
  43. <image src='../../../assets/fire.png' class='list-item-content-fire' wx:for="{{item.heat}}" wx:key='index'></image>
  44. </view>
  45. </view>
  46. </view>
  47. </view>
  48. </view>
  49. </block>
  50. <template is='nodata' data='{{...navList[navIndex]["nodataArray"]}}' wx:if='{{list.length==0}}'></template>
  51. </view>
  52. </view>
  53. </view>