changeDrawer.vue 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118
  1. <template>
  2. <view class="content_main">
  3. <uni-forms :modelValue="infodata" v-if="batteryInfoActive == 0">
  4. <uni-forms-item label="换电编号:" name="name" label-align="right" label-width="120px">
  5. <uni-easyinput type="text" v-model="infodata.swapId || '-'" placeholder="请输入" disabled />
  6. </uni-forms-item>
  7. <uni-forms-item label="车牌号:" name="name" label-align="right" label-width="120px">
  8. <uni-easyinput type="text" v-model="infodata.vehiclePlate || '-'" placeholder="请输入" disabled />
  9. </uni-forms-item>
  10. <uni-forms-item label="换电结果:" name="name" label-align="right" label-width="120px">
  11. <uni-easyinput type="text" v-model="infodata.swapState || '-'" placeholder="请输入" disabled />
  12. </uni-forms-item>
  13. <uni-forms-item label="换电开始时间:" name="name" label-align="right" label-width="120px">
  14. <uni-easyinput type="text" v-model="infodata.swapBeginTime || '-'" placeholder="请输入" disabled />
  15. </uni-forms-item>
  16. <uni-forms-item label="安装满电时长:" name="name" label-align="right" label-width="120px">
  17. <uni-easyinput type="text" v-model="infodata.fullDuration || '-'" placeholder="请输入" disabled />
  18. </uni-forms-item>
  19. <uni-forms-item label="换电时长:" name="name" label-align="right" label-width="120px">
  20. <uni-easyinput type="text" v-model="infodata.swapDuration || '-'" placeholder="请输入" disabled />
  21. </uni-forms-item>
  22. <uni-forms-item label="满电电池SN:" name="name" label-align="right" label-width="120px">
  23. <uni-easyinput type="text" v-model="infodata.swapSn|| '-'" placeholder="请输入" disabled />
  24. </uni-forms-item>
  25. <uni-forms-item label="满电电池SOC:" name="name" label-align="right" label-width="120px">
  26. <uni-easyinput type="text" v-model="infodata.swapSoc|| '-'" placeholder="请输入" disabled />
  27. </uni-forms-item>
  28. <uni-forms-item label="满电电池SOH:" name="name" label-align="right" label-width="120px">
  29. <uni-easyinput type="text" v-model="infodata.swapSoh || '-'" placeholder="请输入" disabled />
  30. </uni-forms-item>
  31. <uni-forms-item label="亏电电池SN:" name="name" label-align="right" label-width="120px">
  32. <uni-easyinput type="text" v-model="infodata.vehicleSn || '-'" placeholder="请输入" disabled />
  33. </uni-forms-item>
  34. <uni-forms-item label="亏电电池SOC:" name="name" label-align="right" label-width="120px">
  35. <uni-easyinput type="text" v-model="infodata.vehicleSoc || '-'" placeholder="请输入" disabled />
  36. </uni-forms-item>
  37. <uni-forms-item label="亏电电池SOH:" name="name" label-align="right" label-width="120px">
  38. <uni-easyinput type="text" v-model="infodata.vehicleSoh || '-'" placeholder="请输入" disabled />
  39. </uni-forms-item>
  40. </uni-forms>
  41. <uni-forms :modelValue="infodata" v-if="batteryInfoActive == 1">
  42. <uni-forms-item label="车牌号:" name="name" label-align="right" label-width="120px">
  43. <uni-easyinput type="text" v-model="infodata.vehiclePlate || '-'" placeholder="请输入" disabled />
  44. </uni-forms-item>
  45. <uni-forms-item label="车辆识别码:" name="name" label-align="right" label-width="120px">
  46. <uni-easyinput type="text" v-model="infodata.vehicleVin || '-'" placeholder="请输入" disabled />
  47. </uni-forms-item>
  48. </uni-forms>
  49. <uni-forms :modelValue="infodata" v-if="batteryInfoActive == 2">
  50. <uni-forms-item label="预选电池仓位:" name="name" label-align="right" label-width="120px">
  51. <uni-easyinput type="text" v-model="infodata.preselectionCode || '-'" placeholder="请输入" disabled />
  52. </uni-forms-item>
  53. <uni-forms-item label="预选满电电池SN:" name="name" label-align="right" label-width="120px">
  54. <uni-easyinput type="text" v-model="infodata.preselectionSn || '-'" placeholder="请输入" disabled />
  55. </uni-forms-item>
  56. <uni-forms-item label="预选满电电池SOC:" name="name" label-align="right" label-width="120px">
  57. <uni-easyinput type="text" v-model="infodata.preselectionSoc || '-'" placeholder="请输入" disabled />
  58. </uni-forms-item>
  59. <uni-forms-item label="预选满电电池SOH:" name="name" label-align="right" label-width="120px">
  60. <uni-easyinput type="text" v-model="infodata.preselectionSoh || '-'" placeholder="请输入" disabled />
  61. </uni-forms-item>
  62. </uni-forms>
  63. <uni-forms :modelValue="infodata" v-if="batteryInfoActive == 3">
  64. <uni-forms-item label="同步状态:" name="name" label-align="right" label-width="120px">
  65. <uni-easyinput type="text" v-model="infodata.state || '-'" placeholder="请输入" disabled />
  66. </uni-forms-item>
  67. <uni-forms-item label="同步时间:" name="name" label-align="right" label-width="120px">
  68. <uni-easyinput type="text" v-model="infodata.uploadTime || '-'" placeholder="请输入" disabled />
  69. </uni-forms-item>
  70. </uni-forms>
  71. </view>
  72. </template>
  73. <script>
  74. export default {
  75. name: 'changeDrawer',
  76. props: ['infodata', 'batteryInfoActive'],
  77. data() {
  78. return {}
  79. },
  80. created() {
  81. if (this.infodata.state == 0) {
  82. this.infodata.state = '待上传'
  83. } else if (this.infodata.state == 1) {
  84. this.infodata.state ='上传成功'
  85. } else if (this.infodata.state == 2) {
  86. this.infodata.state ='上传失败'
  87. } else {
  88. this.infodata.state = null
  89. }
  90. }
  91. }
  92. </script>
  93. <style lang="scss" scoped>
  94. ::v-deep .uni-forms-item__content {
  95. background: rgba(255, 255, 255, 0);
  96. border-radius: 2px 2px 2px 2px;
  97. border: 1px solid #263042;
  98. .uni-easyinput__content {
  99. background: none !important;
  100. border: none !important;
  101. color: #fff;
  102. }
  103. }
  104. ::v-deep .uni-forms-item {
  105. width: auto !important;
  106. }
  107. .content_main {
  108. height: 665px;
  109. overflow: auto;
  110. }
  111. </style>