index.wxml 3.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. <!--index.wxml-->
  2. <view class="sg-container" style="overflow: hidden;">
  3. <view class="flexdstyle">
  4. <view class="sg-top-box sg-index-bg">
  5. <view class="sg-top-item sg-font-xs" bindtap="navigate" data-url="/pages/create-project/index"
  6. wx:if="{{topRole && topRole.rights && topRole.rights.newProject}}">
  7. <van-icon name="edit" class="sg-icon" />
  8. <view class="sg-top-name">新建项目</view>
  9. </view>
  10. <view class="sg-top-item sg-font-xs" bindtap="navigate" data-url="/pages/create-project-role/index"
  11. wx:if="{{topRole && topRole.rights && topRole.rights.memberAdd}}">
  12. <van-icon name="user-o" class="sg-icon" />
  13. <view class="sg-top-name">成员添加</view>
  14. </view>
  15. <view class="sg-top-item sg-font-xs" bindtap="navigate" data-url="/pages/draft/index">
  16. <van-icon name="description" class="sg-icon" />
  17. <view class="sg-top-name">草稿箱</view>
  18. </view>
  19. <view class="sg-top-item sg-font-xs sg-right-border" bindtap="navigate" data-url="/pages/notification/index">
  20. <van-icon name="bell" class="sg-icon" wx:if="{{notReadCount > 0}}" info="{{notReadCount}}" />
  21. <van-icon name="bell" class="sg-icon" wx:else />
  22. <view class="sg-top-name">消息提示</view>
  23. </view>
  24. <view class="sg-top-item sg-font-xs">
  25. <view class="sg-avatar" wx:if="{{userInfo.avatar==''}}">
  26. <open-data type="userAvatarUrl"></open-data>
  27. </view>
  28. <image class="sg-avatar" wx:else src="{{ userInfo.avatar }}" mode="widthFix"></image>
  29. </view>
  30. </view>
  31. <view class="sg-search-box sg-shadow">
  32. <van-icon name="search" class="sg-index-color sg-search-icon" />
  33. <input class="sg-search-input" placeholder="搜索相关项目" bindblur="search" bindinput="updateInput"
  34. data-name="keyword"></input>
  35. </view>
  36. </view>
  37. <view class="sg-box sg-pad" style="margin-top:280rpx">
  38. <view class="sg-header">所有项目</view>
  39. <view class="sg-list">
  40. <view class="sg-item sg-index-card sg-shadow sg-pad sg-margin-top-sm" style="border-radius: 16rpx;"
  41. wx:for="{{list}}" wx:key="index" data-id="{{item.id}}" bindtap="navigate"
  42. data-url="/pages/project/index?id={{item.id}}">
  43. <image class="sg-img" style="border-radius: 16rpx;" mode="widthFix" src="https://rt2.swdz.com/mini/test.png">
  44. </image>
  45. <view class="sg-right">
  46. <view class="">
  47. <view class="sg-name sg-bold">{{ item.name }}</view>
  48. <view class="sg-date sg-gray-color sg-font-small" style="margin-top:15rpx;font-size:25rpx">
  49. 创建时间:{{ item.date }}</view>
  50. </view>
  51. <view class="sg-bottom sg-font-xs sg-margin-top-sm" style="font-size:25rpx">
  52. <view class="sg-desc">项目经理:{{ item.manager ? item.manager.name : '无' }}</view>
  53. <view class="sg-desc">电话:{{ item.manager ? item.manager.phone : '无' }}</view>
  54. </view>
  55. </view>
  56. </view>
  57. </view>
  58. </view>
  59. </view>