shj
2022-07-30 e0530468d54abb4030453ce5d60d53477204957b
src/views/facilityManagement/deviceType/index.vue
@@ -10,12 +10,14 @@
         </el-table-column>
         <el-table-column align="center" label="巡检">
            <template #default="scope">
            <span v-if="scope.row.isVisit == 0">-</span>
               <span v-if="scope.row.isVisit == 1">是</span>
               <span v-if="scope.row.isVisit == 2">否</span>
            </template>
         </el-table-column>
         <el-table-column align="center" label="检测">
            <template #default="scope">
            <span v-if="scope.row.isCheck == 0">-</span>
               <span v-if="scope.row.isCheck == 1">是</span>
               <span v-if="scope.row.isCheck == 2">否</span>
            </template>
@@ -25,7 +27,7 @@
            <template #default="scope">
               <el-button type="primary" link :icon="View" @click="openD('查看', scope.row.id)">查看</el-button>
               <el-button type="primary" link :icon="EditPen" @click="openD('修改', scope.row.id)">修改</el-button>
               <el-button type="primary" link :icon="Delete" @click="Delete(scope.row.id)">删除</el-button>
               <el-button type="primary" link :icon="Delete" @click="Deletes(scope.row.id)">删除</el-button>
               <el-button type="primary" link :icon="CirclePlus" @click="openD('添加', scope.row.id)">添加下级设备设施类型管理</el-button>
            </template>
         </el-table-column>
@@ -62,7 +64,7 @@
         listApi();
      });
      // 删除
      const Delete = (id: number) => {
      const Deletes = (id: number) => {
         facilityManagementApi()
            .getequipmentTypeMngDelete(id)
            .then((res) => {
@@ -74,11 +76,11 @@
                  });
                  listApi();
               } else {
                  ElMessage({
                     showClose: true,
                     message: res.data.msg,
                     type: 'error',
                  });
                  // ElMessage({
                  //    showClose: true,
                  //    message: res.data.msg,
                  //    type: 'error',
                  // });
               }
            });
      };
@@ -98,13 +100,14 @@
         add,
         tableData,
         Show,
         Delete,
         Deletes,
         openD,
         listApi,
         Plus,
         View,
         EditPen,
         CirclePlus,
         Delete,
      };
   },
});