itemCard.wxml 1.6 KB

12345678910111213141516171819202122232425262728293031
  1. <!-- 为首页消息通知的组件,数据在mainData.js -->
  2. <view class="card" bindtap="getActivityInfo">
  3. <view class="profile">
  4. <view class="avatar-name" catchtap="getPublisherInfo">
  5. <image class="publisher-avatar" src="{{item.publisherAvatar}}" mode="aspectFill"></image>
  6. <view class="publisher-name">{{item.publisherName}}</view>
  7. </view>
  8. <view class="activity-attribute primary-background-color white-text-color" catchtap="filterMsgType">{{item.attribute[0]}}
  9. </view>
  10. </view>
  11. <view class="title-time">
  12. <view class="title">{{item.title}}</view>
  13. <view class="time primary-text-color">{{item.time}}</view>
  14. </view>
  15. <view class="sub-title">{{item.subTitle}}</view>
  16. <imagePicker wx:if="{{item.poster != ''}}" images="{{[item.poster]}}" max="1" image-width="690" image-height="365"
  17. readonly />
  18. <imagePicker wx:if="{{item.poster == '' && item.photo.length != 0}}" images="{{item.photo}}" max="1"
  19. image-width="{{item.photo.length == 1 ? 690 : item.photo.length <= 4 ? 330 : 220}}"
  20. image-height="{{item.photo.length == 1 ? 690 : item.photo.length <= 4 ? 330 : 220}}" readonly />
  21. <view class="bottom-line">
  22. <view class="tags primary-text-color">
  23. <text style="font-size: 25rpx; margin: 0rpx 30rpx;" wx:for="{{item.tag}}" wx:for-item="tag"
  24. wx:key="_id">{{tag}}</text>
  25. </view>
  26. <view class="to-detail">
  27. <text class="primary-text-color" style="font-size: 20rpx;">查看详情</text>
  28. <image class="arrow" src="/images/hollow_arrow.png" mode="aspectFill"></image>
  29. </view>
  30. </view>
  31. </view>