index.vue 2.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798
  1. <template>
  2. <!-- 巡检计划项 -->
  3. <navigator hover-class="none" :url="prourl" class="u-border-top u-flex mes-block">
  4. <!-- <u-circle-progress border-width="18" active-color="#2979ff" :percent="parobj.finishNum/parobj.pointNum">
  5. <view class="u-progress-content">
  6. <view class="u-progress-dot"></view>
  7. <text class='u-progress-info'>{{(parobj.finishNum/parobj.pointNum)*100}}% </text>
  8. </view>
  9. </u-circle-progress> -->
  10. <cyuan :percent="parobj.completed/parobj.total"/>
  11. <view class="u-m-l-14">
  12. <view class="mes-rig-tile u-f-30">{{parobj.name}}</view>
  13. <view v-if="more == 1" class="mes-rig-blue u-m-t-30">任务日期:{{beginTime.slice(0,10)}}</view>
  14. <view class="u-flex u-m-t-28">
  15. <view class="mes-rig-blue u-m-r-18">开始时间:{{beginTime.slice(10,-3)}}</view>
  16. <view class="">
  17. <u-tag :type="parobj.status == 1 || parobj.status == 3 ? 'success' : parobj.status==2?'warning':'error' " :text="status[parobj.status]" size="mini" mode="dark" />
  18. </view>
  19. </view>
  20. <view class="mes-rig-blue u-m-t-30">截至时间:{{endTime.slice(10,-3)}}</view>
  21. <view class="mes-rig-blue u-m-t-30">今日巡检:{{`${parobj.completed}/${parobj.total}`}}</view>
  22. </view>
  23. <view class="u-absolute " style="right: 15rpx">
  24. <u-icon name="arrow-right" color="rgba(229, 229, 229, 1)" size="40"></u-icon>
  25. </view>
  26. </navigator>
  27. </template>
  28. <script>
  29. import cyuan from '../c-yuan/index.vue'
  30. import dayjs from "dayjs";
  31. export default {
  32. props:{
  33. prourl:{
  34. type:String
  35. },
  36. more:{
  37. type:Number
  38. },
  39. parobj:{
  40. type:Object,
  41. }
  42. },
  43. components:{
  44. cyuan
  45. },
  46. data(){
  47. return {
  48. status: ["", '未开始', '进行中', '已完成',"超时漏检","超时完成"]
  49. }
  50. },
  51. created() {
  52. },
  53. computed:{
  54. beginTime(){
  55. return dayjs(this.parobj.beginTime).format("YYYY-MM-DD HH:mm:ss")
  56. },
  57. endTime(){
  58. return dayjs(this.parobj.endTime).format("YYYY-MM-DD HH:mm:ss")
  59. }
  60. }
  61. }
  62. </script>
  63. <style lang="scss" >
  64. .mes-block {
  65. padding: 34rpx;
  66. text-align: left;
  67. font-size: 28rpx;
  68. .mes-rig-tile {
  69. font-size: 30rpx;
  70. font-family: Microsoft YaHei-3970(82674968);
  71. font-weight: 400;
  72. color: #333333;
  73. }
  74. .mes-rig-blue {
  75. font-size: 26rpx;
  76. font-family: Microsoft YaHei-3970(82674968);
  77. font-weight: 400;
  78. color: #999999;
  79. }
  80. .mes-rig-grey {
  81. color: rgba(128, 128, 128, 1);
  82. }
  83. .u-progress-info{
  84. font-size: 36rpx;
  85. font-family: Microsoft YaHei-3970(82674968);
  86. font-weight: 400;
  87. color: #4A8BFF;
  88. }
  89. }
  90. </style>