item-info.vue 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. <!--
  2. * @Author: PoJun
  3. * @Date: 2023-05-14 19:39:41
  4. * @LastEditors: PoJun
  5. * @LastEditTime: 2023-05-17 23:45:30
  6. * @Message: Nothing
  7. -->
  8. <template>
  9. <view class="item-info u-boxshadow-1" hover-class="u-hover-class" @tap="itemClick">
  10. <view class="u-flex u-row-between">
  11. <view class="u-font-32 u-weight-600">{{ item.title }}</view>
  12. <u-tag text="todo" :type="item.type ? item.type : 'primary'" size="mini"></u-tag>
  13. </view>
  14. <view class="u-font-26 u-m-t-16">
  15. Lorem ipsum dolor sit, amet consectetur adipisicing elit. Exercitationem sunt quasi iusto iste non
  16. laudantium harum quod. Rem, doloremque consequatur. Nisi, sed fugiat et sunt quod facilis quidem maiores
  17. autem.
  18. </view>
  19. <view class="u-font-26 u-m-t-16 u-tips-color">2023-5-15 21:56:43</view>
  20. </view>
  21. </template>
  22. <script>
  23. export default {
  24. name: "item-info",
  25. props: {
  26. item: {
  27. type: Object,
  28. default: function () {
  29. return {};
  30. },
  31. },
  32. },
  33. data() {
  34. return {};
  35. },
  36. methods: {
  37. itemClick() {
  38. uni.$u.route({
  39. url: "pages/task/detail",
  40. params: {
  41. id: this.item.id,
  42. },
  43. });
  44. },
  45. },
  46. };
  47. </script>
  48. <style lang="scss" scoped>
  49. .item-info {
  50. padding: 24rpx;
  51. }
  52. </style>