repair.vue 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126
  1. <template>
  2. <view class="">
  3. <view @click="goDetail(item)" class="data" v-for="(item, index) in list" :key="index">
  4. <view class="top" style="color: #444444;">
  5. <view class="left">
  6. <view class="title">
  7. <text>报修编号:{{item.repairNo}}</text>
  8. <text @click.stop="copy(item.repairNo)" class="padding-left-20">复制</text>
  9. </view>
  10. </view>
  11. <view class="right">
  12. <text class="text-red" v-if="item.handleStatus==-1">已取消</text>
  13. <text class="text-orange" v-if="item.handleStatus==0">待处理</text>
  14. <text class="" v-if="item.handleStatus==1">已处理</text>
  15. </view>
  16. </view>
  17. <view class="item">
  18. <view style="padding: 0 30rpx;">
  19. <view class="content text-bold text-lg">
  20. <text style="line-height: 50rpx;">{{item.reportDetail}}</text>
  21. </view>
  22. <view class="content flex">
  23. <u-icon name="map-fill" size="30" color="#dc9c72"></u-icon>
  24. <view class="padding-left-10">
  25. {{item.residentialName}}
  26. <text class="cuIcon-move" style="padding: 0 4rpx;"></text>
  27. {{item.reportPosition}}
  28. </view>
  29. </view>
  30. <view class="content flex">
  31. <u-icon name="clock-fill" size="30" color="#fb970b"></u-icon>
  32. <view class="padding-left-10">
  33. {{item.beginTime}}
  34. <text class="cuIcon-move" style="padding: 0 4rpx;"></text>
  35. {{item.endTime}}
  36. </view>
  37. </view>
  38. </view>
  39. </view>
  40. <view class="bottom">
  41. <!-- 待处理状态 -->
  42. <view v-if="item.handleStatus==0" @click.stop="handelRepair(item)" class="cu-btn sm round line-base" style="margin: 0 8rpx;padding: 0 20rpx;font-size: 22rpx;">
  43. 处理工单
  44. </view>
  45. <view v-else class="cu-btn sm round line-base" style="margin: 0 8rpx;padding: 0 20rpx;font-size: 22rpx;">
  46. 查看详情
  47. </view>
  48. </view>
  49. </view>
  50. </view>
  51. </template>
  52. <script>
  53. export default {
  54. name: 'card',
  55. props:{
  56. list:{
  57. type:Array
  58. }
  59. },
  60. data() {
  61. return {
  62. };
  63. },
  64. onLoad() {
  65. },
  66. methods:{
  67. copy(data){
  68. uni.setClipboardData({
  69. data:data
  70. })
  71. },
  72. goDetail(item){
  73. uni.navigateTo({
  74. url:"/pages/repair/detail?id="+item.id
  75. })
  76. },
  77. handelRepair(item){
  78. this.$emit('handelRepair',item)
  79. }
  80. }
  81. };
  82. </script>
  83. <style lang="scss">
  84. .data {
  85. background-color: #ffffff;
  86. margin:8rpx;
  87. border-radius: 6rpx;
  88. box-sizing: border-box;
  89. padding:0 10rpx;
  90. font-size: 28rpx;
  91. .top {
  92. display: flex;
  93. justify-content: space-between;
  94. padding: 18rpx 0;
  95. font-size: 26rpx;
  96. border-bottom: 1rpx dashed #EDEDED;
  97. .left {
  98. display: flex;
  99. align-items: center;
  100. .title {
  101. margin: 0 10rpx;
  102. }
  103. }
  104. .right{
  105. margin-right: 10rpx;
  106. }
  107. }
  108. .item {
  109. margin: 4rpx 0 20rpx 0;
  110. .content {
  111. padding: 8rpx 0;
  112. }
  113. }
  114. .bottom {
  115. display: flex;
  116. padding-bottom: 15rpx;
  117. padding-right: 10rpx;
  118. justify-content: flex-end;
  119. align-items: center;
  120. }
  121. }
  122. </style>