Selaa lähdekoodia

fix:控制维护按钮

lupeng 1 vuosi sitten
vanhempi
commit
8cd6ab3b88
1 muutettua tiedostoa jossa 2 lisäystä ja 2 poistoa
  1. 2 2
      src/views/device/maintenance/index.vue

+ 2 - 2
src/views/device/maintenance/index.vue

@@ -33,14 +33,14 @@
                    icon="el-icon-setting"
                    text
                    v-hasPerm="[ButtonPermKeys.DEVICE.BTNS.maintenance_handle]"
-                   v-if="row.type === '1' && row.state === 0"
+                   v-if="row.type === '1' && row.state === 0 && Date.parse(row.nextTime) <= new Date()"
                    type="primary"
                    :size="size">维护</el-button>
         <el-button disabled
                    icon="el-icon-setting"
                    text
                    v-hasPerm="[ButtonPermKeys.DEVICE.BTNS.maintenance_handle]"
-                   v-if="row.type === '1' && row.state === 1"
+                   v-if="row.type === '1' && row.state === 1 && Date.parse(row.nextTime) <= new Date()"
                    type="primary"
                    :size="size">维护</el-button>
         <el-button @click="maintenanceList(row)"