Browse Source

修改了两个地方

Reiskuchen 5 years ago
parent
commit
c7c91d85e0
2 changed files with 10 additions and 4 deletions
  1. 9 3
      ys_vue/src/views/base/allocation.vue
  2. 1 1
      ys_vue/src/views/detection/detection.vue

+ 9 - 3
ys_vue/src/views/base/allocation.vue

@@ -39,7 +39,13 @@
       <el-table-column prop="name" label="模具名称" width="100" sortable></el-table-column>
       <el-table-column prop="mouldNumber" label="模具编号" width="120" sortable></el-table-column>
       <el-table-column prop="assets" label="资产方" width="120" sortable></el-table-column>
-      <el-table-column prop="state" label="模具状态" width="100" sortable></el-table-column>
+      <el-table-column prop="state" label="模具状态" width="100" sortable>
+        <template slot-scope="scope">
+          <span v-if="scope.row.state == true">运行</span>
+          <span v-else>停止</span>
+          <el-switch v-model="scope.row.state"></el-switch>
+        </template>
+      </el-table-column>
       <el-table-column label="操作" width="160" sortable>
         <el-button size="small">修改</el-button>
         <el-button type="danger" size="small">删除</el-button>
@@ -105,7 +111,7 @@ export default {
           name: "墨盒",
           mouldNumber: "MUJU123456",
           assets: "南京火石闪信",
-          state: "1"
+          state: true
         },
         {
           deviceNumber: "7891011",
@@ -114,7 +120,7 @@ export default {
           name: "墨盒2",
           mouldNumber: "MUJU654321",
           assets: "南京火石闪信",
-          state: "0"
+          state: false
         }
       ],
       newAllocation: {

+ 1 - 1
ys_vue/src/views/detection/detection.vue

@@ -40,7 +40,7 @@
       <el-table-column prop="lifetime" label="模具寿命" width="100" sortable></el-table-column>
       <el-table-column label="模具保养" width="100" sortable>
         <template slot-scope="scope">
-          <el-button size="small" @click="toMaintenance(scope.row.number)">不需要</el-button>
+          <a style="color: #409EFF; cursor: pointer" @click="toMaintenance(scope.row.number)">不需要</a>
         </template>
       </el-table-column>
       <el-table-column label="模具更新" width="100" sortable>