瀏覽代碼

工单管理;用户选择组件去掉了外层空的div标签

damon227 1 年之前
父節點
當前提交
bf7de44086

+ 4 - 4
src/views/modules/common/upload-component-v2.vue

@@ -126,10 +126,10 @@ export default {
         uploadFiles(formData).then(({ data }) => {
           if (data && data.code === "200") {
             data.data.forEach((item) => {
-              let fileData = this.fileList.find((file) => {
-                file.name === item.originFileName;
-                file.fileName === item.originFileName;
-              });
+              let fileData = this.fileList.find(
+                (file) => file.name === item.originFileName
+              );
+              fileData.fileName = item.originFileName;
               fileData.url = item.fileUrl;
               this.uploadFileList.push(fileData);
             });

+ 0 - 2
src/views/modules/common/user-component.vue

@@ -1,6 +1,5 @@
 <!-- 用户组件(单选) -->
 <template>
-    <div>
       <el-select
         v-model="value"
         ref="select"
@@ -21,7 +20,6 @@
         </el-option>
         <el-option v-if="options.length > 0" label="加载更多" style="font-style: italic; color: #8a979e" value="undefined" @click.native="handleClick()"></el-option>
       </el-select>
-    </div>
 </template>
 
 <script>

+ 0 - 152
src/views/modules/contact/manage-add-or-update.vue

@@ -1,152 +0,0 @@
-<template>
-  <div>
-    <div class="my-title">{{ !id ? "新增" : "修改" }}</div>
-    <el-form
-      :model="dataForm"
-      :rules="dataRule"
-      ref="dataForm"
-      @keyup.enter.native="dataFormSubmit()"
-      label-width="100px"
-    >
-      <el-row class="my-row">
-        <el-col :span="6">
-          <el-form-item label="客户名称" prop="optionCode">
-            <el-input
-              v-model="dataForm.optionCode"
-              placeholder="方案编码"
-            ></el-input>
-          </el-form-item>
-        </el-col>
-        <el-col :span="6">
-          <el-form-item label="客户联系人" prop="optionCode">
-            <el-input
-              v-model="dataForm.optionCode"
-              placeholder="方案编码"
-            ></el-input>
-          </el-form-item>
-        </el-col>
-        <el-col :span="6">
-          <el-form-item label="客户联系电话" prop="optionCode">
-            <el-input
-              v-model="dataForm.optionCode"
-              placeholder="方案编码"
-            ></el-input>
-          </el-form-item>
-        </el-col>
-        <el-col :span="6">
-          <el-form-item label="沟通方式" prop="optionCode">
-            <el-input
-              v-model="dataForm.optionCode"
-              placeholder="方案编码"
-            ></el-input>
-          </el-form-item>
-        </el-col>
-      </el-row>
-      <el-row class="my-row">
-        <el-col :span="6">
-          <el-form-item label="沟通类别" prop="optionCode">
-            <el-input
-              v-model="dataForm.optionCode"
-              placeholder="方案编码"
-            ></el-input>
-          </el-form-item>
-        </el-col>
-      </el-row>
-      <el-row class="my-row">
-        <el-col :span="12">
-          <el-form-item label="沟通主要内容" prop="optionCode">
-            <el-input
-              v-model="dataForm.optionCode"
-              placeholder=""
-              type="textarea"
-            ></el-input>
-          </el-form-item>
-        </el-col>
-        <el-col :span="12">
-          <el-form-item label="备注" prop="optionCode">
-            <el-input
-              v-model="dataForm.optionCode"
-              placeholder=""
-              type="textarea"
-            ></el-input>
-          </el-form-item>
-        </el-col>
-      </el-row>
-      <el-row class="my-row">
-        <el-col :span="12">
-          <upload-component
-            :title="'技术资料'"
-            :accept="'*'"
-            :file-obj-list="fileList"
-            @uploadSuccess="uploadSuccess"
-          />
-        </el-col>
-        <el-col :span="12">
-          <upload-component
-            :title="'数模/图纸'"
-            :accept="'*'"
-            :file-obj-list="fileList"
-            @uploadSuccess="uploadSuccess"
-          />
-        </el-col>
-      </el-row>
-      <el-row class="my-row">
-        <el-col :span="12">
-          <upload-component
-            :title="'沟通表原件'"
-            :accept="'*'"
-            :file-obj-list="fileList"
-            @uploadSuccess="uploadSuccess"
-          />
-        </el-col>
-        <el-col :span="12">
-          <upload-component
-            :title="'其他附件'"
-            :accept="'*'"
-            :file-obj-list="fileList"
-            @uploadSuccess="uploadSuccess"
-          />
-        </el-col>
-      </el-row>
-    </el-form>
-    <span slot="footer" class="dialog-footer">
-      <el-button @click="onChose">取消</el-button>
-      <el-button type="primary" @click="dataFormSubmit()">确定</el-button>
-    </span>
-  </div>
-</template>
-
-<script>
-import UploadComponent from "../common/upload-component";
-export default {
-  name: "manage-add-or-update",
-  components: { UploadComponent },
-  data() {
-    return {
-      id: 0,
-      dataForm: {},
-      fileList: [],
-      dataRule: {},
-    };
-  },
-  created() {},
-  methods: {
-    onChose() {
-      this.$emit("onChose");
-    },
-    async init(id, display) {
-      this.id = id || 0;
-      this.fileList = [];
-      this.$refs["dataForm"].resetFields();
-
-      if (!id) return;
-    },
-    uploadSuccess(fileList) {
-      this.fileList = fileList;
-    },
-    dataFormSubmit(){}
-  },
-};
-</script>
-
-<style></style>

+ 0 - 282
src/views/modules/contact/manage.vue

@@ -1,282 +0,0 @@
-<template>
-  <div class="stock">
-    <template v-if="!addOrUpdateVisible">
-      <el-form :inline="true" :model="dataForm" @keyup.enter.native="search()">
-        <el-form-item label="客户名称">
-          <el-input
-            v-model="dataForm.customerName"
-            placeholder=""
-            clearable
-          />
-        </el-form-item>
-       <el-form-item label="内容">
-          <el-input
-            v-model="dataForm.optionName"
-            placeholder=""
-            clearable
-          />
-        </el-form-item>
-        <el-form-item label="部门">
-          <org-component v-model="dataForm.orgId"/>
-        </el-form-item>
-        <el-form-item label="沟通类别">
-          <el-select v-model="dataForm.productId" filterable remote clearable placeholder="请选择">
-            <el-option
-                v-for="item in typeList"
-                :key="item.id"
-                :label="item.name"
-                :value="item.id"
-              >
-              </el-option>
-            </el-option>
-          </el-select>
-        </el-form-item>
-        <el-form-item>
-          <el-button @click="search()">查询</el-button>
-          <el-button
-            v-if="isAuth('cus:customer:save')"
-            type="primary"
-            @click="addOrUpdateHandle(0, false)"
-            >录入</el-button
-          >
-        </el-form-item>
-      </el-form>
-      <el-table
-        :data="dataList"
-        border
-        v-loading="dataListLoading"
-        style="width: 100%"
-      >
-        <el-table-column label="序号" type="index" width="50" align="center">
-        </el-table-column>
-        <el-table-column
-          prop="coCode"
-          header-align="center"
-          align="center"
-          min-width="120"
-          :show-tooltip-when-overflow="true"
-          label="沟通编码"
-        >
-        </el-table-column>
-        <el-table-column
-          prop="customerName"
-          header-align="center"
-          align="center"
-          min-width="120"
-          label="客户名称"
-        >
-        </el-table-column>
-        <el-table-column
-          prop="contact"
-          header-align="center"
-          align="center"
-          min-width="120"
-          label="客户联系人"
-        > </el-table-column>
-        <el-table-column
-          prop="contactTel"
-          header-align="center"
-          align="center"
-          min-width="120"
-          label="客户联系人电话"
-        > </el-table-column>
-        <el-table-column
-          prop="way"
-          header-align="center"
-          align="center"
-          label="沟通方式"
-        > </el-table-column>
-        <el-table-column
-          prop="coTypeValue"
-          header-align="center"
-          align="center"
-          label="沟通类别"
-        > </el-table-column>
-        <el-table-column
-          prop="content"
-          header-align="center"
-          align="center"
-          label="内容"
-          :show-tooltip-when-overflow="true"
-        > </el-table-column>
-        <el-table-column
-          prop="notes"
-          header-align="center"
-          align="center"
-          label="备注"
-          :show-tooltip-when-overflow="true"
-        > </el-table-column>
-        <el-table-column
-          prop="creatorId"
-          header-align="center"
-          align="center"
-          label="沟通人"
-        > </el-table-column>
-        <el-table-column
-          prop="orgName"
-          header-align="center"
-          align="center"
-          label="部门"
-        > </el-table-column>
-        <el-table-column
-          prop="state"
-          header-align="center"
-          align="center"
-          label="审核状态"
-        > </el-table-column>
-        </el-table-column>
-        <el-table-column
-          fixed="right"
-          header-align="center"
-          align="center"
-          width="170"
-          min-width="170"
-          label="操作"
-        >
-          <template slot-scope="scope">
-            <el-button
-              v-if="isAuth('cus:customer:info')"
-              type="text"
-              size="small"
-              @click="detailHandle(scope.row.optionId)"
-              >查看</el-button
-            >
-            <el-button
-              v-if="isAuth('cus:customer:info')"
-              type="text"
-              size="small"
-              @click="detailHandle(scope.row.optionId)"
-              >撤回</el-button
-            >
-            <el-button
-              v-if="isAuth('cus:customer:update')"
-              type="text"
-              size="small"
-              @click="addOrUpdateHandle(scope.row.optionId, false)"
-              >编辑</el-button
-            >
-            <el-button
-              v-if="isAuth('cus:customer:update')"
-              type="text"
-              size="small"
-              @click="addOrUpdateHandle(scope.row.optionId, false)"
-              >导出</el-button
-            >
-          </template>
-        </el-table-column>
-      </el-table>
-      <el-pagination
-        @size-change="sizeChangeHandle"
-        @current-change="currentChangeHandle"
-        :current-page="pageIndex"
-        :page-sizes="[10, 20, 50, 100]"
-        :page-size="pageSize"
-        :total="totalPage"
-        layout="total, sizes, prev, pager, next, jumper"
-      >
-      </el-pagination>
-    </template>
-    <add-or-update ref="addOrUpdate" v-if="addOrUpdateVisible" @onChose="onChose"></add-or-update>
-  </div>
-</template>
-
-<script>
-import AddOrUpdate from "./manage-add-or-update.vue";
-import OrgComponent from '../common/org-component'
-import { getCusCommunicationTypeList } from "@/api/contact";
-export default {
-  name: "contact-manage",
-  components: {AddOrUpdate,OrgComponent},
-  data() {
-    return {
-      addOrUpdateVisible: false,
-      detailVisible: false,
-      noteChangeVisible: false,
-      attachVisible: false,
-      materialList: [],
-      dataForm: {
-        customerName: "",
-orgId:''
-      },
-      options: [],
-      dataList: [],
-      typeList: [],
-      pageIndex: 1,
-      pageSize: 10,
-      totalPage: 0,
-      dataListLoading: false,
-    };
-  },
-  created() {
-    this.getDataList();
-    this.getCusCommunicationTypeList();
-  },
-  methods: {
-    onChose() {
-      this.addOrUpdateVisible = false;
-      this.detailVisible = false;
-      this.noteChangeVisible = false;
-      this.attachVisible = false;
-    },
-    //沟通类别列表
-    getCusCommunicationTypeList(){
-        getCusCommunicationTypeList().then(({data}) => {
-            if (data && data.code === "200") {
-                this.typeList = data.data;
-                } 
-        })
-    },
-    // 查询
-    search() {
-      this.pageIndex = 1;
-      this.getDataList();
-    },
-    // 获取数据列表
-    getDataList() {
-      this.addOrUpdateVisible = false;
-      this.dataListLoading = true;
-      this.$http({
-        url: this.$http.adornUrl("/biz-service/cusCommunication/list"),
-        method: "get",
-        params: this.$http.adornParams({
-          current: this.pageIndex,
-          size: this.pageSize,
-          customerName: this.dataForm.customerName,
-          orgId: this.dataForm.orgId,
-          coType: this.dataForm.coType,
-          content: this.dataForm.content
-        }),
-      }).then(({ data }) => {
-        if (data && data.code === "200") {
-          this.dataList = data.data.records;
-          this.totalPage = Number(data.data.total);
-        } else {
-          this.dataList = [];
-          this.totalPage = 0;
-        }
-        this.dataListLoading = false;
-      });
-    },
-    // 每页数
-    sizeChangeHandle(val) {
-      this.pageSize = val;
-      this.pageIndex = 1;
-      this.getDataList();
-    },
-    // 当前页
-    currentChangeHandle(val) {
-      this.pageIndex = val;
-      this.getDataList();
-    },
-    addOrUpdateHandle(id, disabled){
-      this.addOrUpdateVisible = true;
-      this.$nextTick(() => {
-        this.$refs.addOrUpdate.init(id, disabled);
-      });
-    }
-  },
-};
-</script>
-
-<style>
-</style>

+ 1 - 1
src/views/modules/cus/communicate-add-or-update.vue

@@ -173,7 +173,7 @@
             >
             </el-table-column>
             <el-table-column
-              prop="cnt"
+              prop="deliveryDate"
               header-align="center"
               align="center"
               min-width="100"

+ 8 - 1
src/views/modules/cus/communicate.vue

@@ -65,6 +65,7 @@
           header-align="center"
           align="center"
           label="客户联系人">
+          :show-tooltip-when-overflow="true"
         </el-table-column>
          <el-table-column
           prop="contactTel"
@@ -72,12 +73,14 @@
           align="center"
           min-width="120"
           label="客户联系人电话"
+          :show-tooltip-when-overflow="true"
         > </el-table-column>
         <el-table-column
           prop="way"
           header-align="center"
           align="center"
           label="沟通方式"
+          :show-tooltip-when-overflow="true"
         > </el-table-column>
         <el-table-column
           prop="coType"
@@ -85,6 +88,7 @@
           header-align="center"
           align="center"
           label="沟通类别">
+          :show-tooltip-when-overflow="true"
         </el-table-column>
          <el-table-column
           prop="content"
@@ -101,22 +105,25 @@
           :show-tooltip-when-overflow="true"
         > </el-table-column>
         <el-table-column
-          prop="creatorId"
+          prop="creatorName"
           header-align="center"
           align="center"
           label="沟通人"
+          :show-tooltip-when-overflow="true"
         > </el-table-column>
         <el-table-column
           prop="orgName"
           header-align="center"
           align="center"
           label="部门"
+          :show-tooltip-when-overflow="true"
         > </el-table-column>
         <el-table-column
           prop="state"
           header-align="center"
           align="center"
           label="审核状态"
+          :show-tooltip-when-overflow="true"
         > </el-table-column>
         <el-table-column
           fixed="right"

+ 18 - 25
src/views/modules/works/handover-records.vue

@@ -25,67 +25,60 @@
             align="center">
           </el-table-column>
           <el-table-column
-            prop="productName"
+            prop="taskName"
             header-align="center"
             align="center"
-            width="160"
-            :show-overflow-tooltip="true"
-            label="产品名称">
-          </el-table-column>
-          <el-table-column
-            prop="prodCode"
-            header-align="center"
-            align="center"
-            width="160"
+            min-width="180"
             :show-overflow-tooltip="true"
-            label="产品编号">
+            label="工单名称">
           </el-table-column>
           <el-table-column
-            prop="techName"
+            prop="transferType"
             header-align="center"
             align="center"
-            width="160"
+            width="120"
             :show-overflow-tooltip="true"
-            label="工艺名称">
+            label="转单类型">
           </el-table-column>
           <el-table-column
-            prop="nodeName"
+            prop="content"
             header-align="center"
             align="center"
-            width="160"
+            min-width="160"
             :show-overflow-tooltip="true"
-            label="工序名称">
+            label="工单内容">
           </el-table-column>
           <el-table-column
             prop="transferUserName"
             header-align="center"
             align="center"
-            width="120"
+            width="160"
             :show-overflow-tooltip="true"
-            label="移交接收人">
+            label="转单接受人">
           </el-table-column>
           <el-table-column
             prop="creatorName"
             header-align="center"
             align="center"
-            min-width="120"
+            width="120"
             :show-overflow-tooltip="true"
-            label="移交发起人">
+            label="转单发起人">
           </el-table-column>
           <el-table-column
             prop="transferExplain"
             header-align="center"
             align="center"
-            min-width="160"
+            min-width="120"
             :show-overflow-tooltip="true"
-            label="移交说明">
+            label="转单原因">
           </el-table-column>
           <el-table-column
             prop="createTime"
             header-align="center"
             align="center"
-            min-width="160"
-            label="移交时间">
+            width="180"
+            :show-overflow-tooltip="true"
+            label="转单时间">
           </el-table-column>
           <el-table-column
             v-if="isAuth('prod:transfer:info')"

+ 210 - 210
src/views/modules/works/work.vue

@@ -1,7 +1,7 @@
 <!-- 我的工作台 -->
 <template>
   <div class="works">
-    <el-form label-width="auto">
+    <el-form :model="dataForm" :inline="true">
       <el-form-item label="选择用户">
         <user-component
           v-model="dataForm.userId"
@@ -9,6 +9,9 @@
           @userSelected="userChanged"
         />
       </el-form-item>
+      <el-form-item>
+        <el-button @click="queryData()">查询</el-button>
+      </el-form-item>
     </el-form>
     <el-radio-group @change="queryData" v-model="dataForm.state">
       <el-radio-button
@@ -18,11 +21,6 @@
         >{{ item.value }}</el-radio-button
       >
     </el-radio-group>
-    <el-form style="margin-top: 10px" label-width="auto">
-      <el-form-item>
-        <el-button @click="queryData()">查询</el-button>
-      </el-form-item>
-    </el-form>
     <el-table
       :data="dataList"
       border
@@ -155,7 +153,7 @@
             type="text"
             size="small"
             @click="transferTask(scope.row.taskId, scope.row.workTypeId)"
-            >移交</el-button
+            >转单</el-button
           >
           <el-button
             v-if="
@@ -376,7 +374,9 @@
             <el-table-column prop="remarks" label="备注">
               <template slot-scope="scope">
                 <el-form-item
-                  :prop="'prodProductionRequireList.' + scope.$index + '.remarks'"
+                  :prop="
+                    'prodProductionRequireList.' + scope.$index + '.remarks'
+                  "
                   label-width="0px"
                 >
                   <el-input v-model="scope.row.remarks"></el-input>
@@ -458,40 +458,40 @@ import {
   completeTask,
   checkTask,
   damageTask,
-  getTaskDetail
-} from '@/api/task'
-import { workTypeMasterList } from '@/api/worktype'
-import templateList from '../warehouse/template-list'
-import PreviewComponent from '../common/preview-component'
-import UserComponent from '@/views/modules/common/user-component'
+  getTaskDetail,
+} from "@/api/task";
+import { workTypeMasterList } from "@/api/worktype";
+import templateList from "../warehouse/template-list";
+import PreviewComponent from "../common/preview-component";
+import UserComponent from "@/views/modules/common/user-component";
 export default {
   components: { UserComponent, PreviewComponent, templateList },
-  name: 'work',
+  name: "work",
   computed: {
     userId: {
-      get () {
-        return this.$store.state.user.id
-      }
-    }
+      get() {
+        return this.$store.state.user.id;
+      },
+    },
   },
   watch: {
-    'dataForm.userId' (value) {
+    "dataForm.userId"(value) {
       this.opColVisible =
-        Number(this.dataForm.state) !== 3 && value === this.userId
+        Number(this.dataForm.state) !== 3 && value === this.userId;
     },
-    'dataForm.state' (value) {
+    "dataForm.state"(value) {
       this.opColVisible = this.dataForm.userId
         ? Number(value) !== 3 && this.dataForm.userId === this.userId
-        : Number(value) !== 3
-    }
+        : Number(value) !== 3;
+    },
   },
-  data () {
+  data() {
     return {
       previewVisible: false,
       addOrUpdateVisible: false,
       opColVisible: true,
       dataForm: {
-        state: '1'
+        state: "1",
       },
       dataList: [],
       pageIndex: 1,
@@ -501,17 +501,17 @@ export default {
       dataListSelections: [],
       optionsState: [
         {
-          code: '1',
-          value: '未开始'
+          code: "1",
+          value: "未开始",
         },
         {
-          code: '2',
-          value: '待操作'
+          code: "2",
+          value: "待操作",
         },
         {
-          code: '3',
-          value: '已完成'
-        }
+          code: "3",
+          value: "已完成",
+        },
       ],
       transferDialogFormVisible: false,
       transferDialogForm: {},
@@ -519,311 +519,311 @@ export default {
       finishDialogForm: {},
       finishDialogFormRules: {
         operationRecords: [
-          { required: true, message: '完成记录说明不能为空', trigger: 'blur' }
-        ]
+          { required: true, message: "完成记录说明不能为空", trigger: "blur" },
+        ],
       },
       transferUserList: [],
       transferDialogFormRules: {
         transferType: [
-          { required: true, message: '请选择移交类型', trigger: 'blur' }
+          { required: true, message: "请选择移交类型", trigger: "blur" },
         ],
         transferUserId: [
-          { required: true, message: '请选择移交用户', trigger: 'blur' }
-        ]
+          { required: true, message: "请选择移交用户", trigger: "blur" },
+        ],
       },
       checkDialogFormVisible: false,
       checkDialogForm: {
-        checkType: '',
-        operationRecords: '',
-        notes: '',
-        prodProductionRecordList: []
+        checkType: "",
+        operationRecords: "",
+        notes: "",
+        prodProductionRecordList: [],
       },
       checkDialogFormRules: {
         operationRecords: [
-          { required: true, message: '完成记录说明不能为空', trigger: 'blur' }
+          { required: true, message: "完成记录说明不能为空", trigger: "blur" },
         ],
-        checkType: [{ required: true, message: '请选择', trigger: 'blur' }],
+        checkType: [{ required: true, message: "请选择", trigger: "blur" }],
         measureRecord1: [
-          { required: true, message: '请输入', trigger: 'blur' }
+          { required: true, message: "请输入", trigger: "blur" },
         ],
         measureRecord2: [
-          { required: true, message: '请输入', trigger: 'blur' }
-        ]
+          { required: true, message: "请输入", trigger: "blur" },
+        ],
       },
       damageDialogFormVisible: false,
       damageDialogForm: {},
       damageDialogFormRules: {
-        damageReason: [{ required: true, message: '请输入', trigger: 'blur' }]
+        damageReason: [{ required: true, message: "请输入", trigger: "blur" }],
       },
       // 是否显示进度条列
       showProgress: true,
       inspectionMethodOptions: {
-        1: '游标卡尺',
-        2: '千分尺',
-        3: '高度尺',
-        4: '百分表',
-        5: 'R规',
-        6: '环规、塞规',
-        7: '游标角度尺',
-        8: '三坐标',
-        9: '模具',
-        10: '样板',
-        11: '夹具',
-        12: '目测',
-        13: '组合测量',
-        14: '精密测量',
-        15: '敲击',
-        16: '测厚仪',
-        17: '其他'
-      }
-    }
+        1: "游标卡尺",
+        2: "千分尺",
+        3: "高度尺",
+        4: "百分表",
+        5: "R规",
+        6: "环规、塞规",
+        7: "游标角度尺",
+        8: "三坐标",
+        9: "模具",
+        10: "样板",
+        11: "夹具",
+        12: "目测",
+        13: "组合测量",
+        14: "精密测量",
+        15: "敲击",
+        16: "测厚仪",
+        17: "其他",
+      },
+    };
   },
-  created () {
-    this.getDataList()
+  created() {
+    this.getDataList();
   },
   methods: {
     // 查询
-    queryData () {
-      this.pageIndex = 1
-      this.showProgress = this.dataForm.state !== '2'
-      this.getDataList()
+    queryData() {
+      this.pageIndex = 1;
+      this.showProgress = this.dataForm.state !== "2";
+      this.getDataList();
     },
     // 获取数据列表
-    getDataList () {
-      this.dataListLoading = true
+    getDataList() {
+      this.dataListLoading = true;
       let params = {
         current: this.pageIndex,
         size: this.pageSize,
         state: this.dataForm.state,
-        userId: this.dataForm.userId ? this.dataForm.userId : null
-      }
+        userId: this.dataForm.userId ? this.dataForm.userId : null,
+      };
       getTaskList(params).then(({ data }) => {
-        if (data && data.code === '200') {
-          this.dataList = data.data.records
-          this.totalPage = Number(data.data.total)
+        if (data && data.code === "200") {
+          this.dataList = data.data.records;
+          this.totalPage = Number(data.data.total);
         } else {
-          this.dataList = []
-          this.totalPage = 0
+          this.dataList = [];
+          this.totalPage = 0;
         }
-        this.dataListLoading = false
-      })
+        this.dataListLoading = false;
+      });
     },
     // 每页数
-    sizeChangeHandle (val) {
-      this.pageSize = val
-      this.pageIndex = 1
-      this.getDataList()
+    sizeChangeHandle(val) {
+      this.pageSize = val;
+      this.pageIndex = 1;
+      this.getDataList();
     },
     // 当前页
-    currentChangeHandle (val) {
-      this.pageIndex = val
-      this.getDataList()
+    currentChangeHandle(val) {
+      this.pageIndex = val;
+      this.getDataList();
     },
     // 多选
-    selectionChangeHandle (val) {
-      this.dataListSelections = val
+    selectionChangeHandle(val) {
+      this.dataListSelections = val;
     },
     // 开始
-    startTask (taskId) {
-      this.$confirm('是否开始任务?', '提示', {
-        confirmButtonText: '确定',
-        cancelButtonText: '取消',
-        type: 'warning'
+    startTask(taskId) {
+      this.$confirm("是否开始任务?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
       })
         .then(() => {
           startTask({ taskId }).then(({ data }) => {
-            if (data && data.code === '200') {
+            if (data && data.code === "200") {
               this.$message({
-                type: 'success',
-                message: '操作成功!'
-              })
-              this.getDataList()
+                type: "success",
+                message: "操作成功!",
+              });
+              this.getDataList();
             } else {
               this.$message({
-                type: 'error',
-                message: data.msg
-              })
+                type: "error",
+                message: data.msg,
+              });
             }
-          })
+          });
         })
         .catch(() => {
           this.$message({
-            type: 'info',
-            message: '已取消'
-          })
-        })
+            type: "info",
+            message: "已取消",
+          });
+        });
     },
     // 移交
-    transferTask (taskId, workTypeId) {
-      this.transferDialogFormVisible = true
-      this.transferDialogForm.taskId = taskId
+    transferTask(taskId, workTypeId) {
+      this.transferDialogFormVisible = true;
+      this.transferDialogForm.taskId = taskId;
 
       workTypeMasterList(workTypeId).then(({ data }) => {
-        if (data && data.code === '200') {
-          this.transferUserList = data.data
+        if (data && data.code === "200") {
+          this.transferUserList = data.data;
         }
-      })
+      });
     },
     // 确认移交
-    transferSubmit () {
-      this.$refs['transferDialogForm'].validate((valid) => {
+    transferSubmit() {
+      this.$refs["transferDialogForm"].validate((valid) => {
         if (valid) {
           transferTask(this.transferDialogForm).then(({ data }) => {
-            if (data && data.code === '200') {
+            if (data && data.code === "200") {
               this.$message({
-                type: 'success',
-                message: '移交成功!'
-              })
-              this.transferDialogFormVisible = false
-              this.getDataList()
+                type: "success",
+                message: "移交成功!",
+              });
+              this.transferDialogFormVisible = false;
+              this.getDataList();
             } else {
               this.$message({
-                type: 'error',
-                message: data.msg
-              })
+                type: "error",
+                message: data.msg,
+              });
             }
-          })
+          });
         }
-      })
+      });
     },
     // 完成
-    completeTask (taskId) {
-      this.finishDialogFormVisible = true
-      this.finishDialogForm.taskId = taskId
+    completeTask(taskId) {
+      this.finishDialogFormVisible = true;
+      this.finishDialogForm.taskId = taskId;
     },
     // 确认完成
-    finishSubmit () {
-      this.$refs['finishDialogForm'].validate((valid) => {
+    finishSubmit() {
+      this.$refs["finishDialogForm"].validate((valid) => {
         if (valid) {
-          let submitData = this.finishDialogForm
+          let submitData = this.finishDialogForm;
           completeTask(submitData).then(({ data }) => {
-            if (data && data.code === '200') {
+            if (data && data.code === "200") {
               this.$message({
-                type: 'success',
-                message: '操作成功!'
-              })
-              this.finishDialogFormVisible = false
-              this.getDataList()
+                type: "success",
+                message: "操作成功!",
+              });
+              this.finishDialogFormVisible = false;
+              this.getDataList();
             } else {
               this.$message({
-                type: 'error',
-                message: data.msg
-              })
+                type: "error",
+                message: data.msg,
+              });
             }
-          })
+          });
         }
-      })
+      });
     },
     // 检验
-    checkTask (taskId, checkType) {
-      this.checkDialogForm.taskId = taskId
+    checkTask(taskId, checkType) {
+      this.checkDialogForm.taskId = taskId;
 
       if (checkType === 1) {
         // 查询工艺详情
         getTaskDetail(this.checkDialogForm.taskId).then(({ data }) => {
-          if (data && data.code === '200') {
-            let list = data.data.prodProductionRequireList
+          if (data && data.code === "200") {
+            let list = data.data.prodProductionRequireList;
             if (list && list.length > 0) {
               list.map((item) => {
-                item.requireId = item.id
-              })
+                item.requireId = item.id;
+              });
             }
-            this.checkDialogForm.prodProductionRecordList = list
+            this.checkDialogForm.prodProductionRecordList = list;
           }
-        })
+        });
 
-        this.checkDialogForm.checkType = checkType
-        this.passTask()
+        this.checkDialogForm.checkType = checkType;
+        this.passTask();
       } else {
-        this.checkDialogForm.checkType = null
-        this.refuseTask()
+        this.checkDialogForm.checkType = null;
+        this.refuseTask();
       }
     },
     // 通过
-    passTask () {
-      this.checkDialogFormVisible = true
+    passTask() {
+      this.checkDialogFormVisible = true;
     },
     // 不通过
-    refuseTask () {
-      this.checkDialogFormVisible = true
+    refuseTask() {
+      this.checkDialogFormVisible = true;
     },
     // 确认检验
-    checkSubmit () {
-      this.$refs['checkDialogForm'].validate((valid) => {
+    checkSubmit() {
+      this.$refs["checkDialogForm"].validate((valid) => {
         if (valid) {
-          let submitData = this.checkDialogForm
+          let submitData = this.checkDialogForm;
           // console.log(submitData);
           checkTask(submitData).then(({ data }) => {
-            if (data && data.code === '200') {
+            if (data && data.code === "200") {
               this.$message({
-                type: 'success',
-                message: '检验成功!'
-              })
-              this.checkDialogFormVisible = false
-              this.getDataList()
+                type: "success",
+                message: "检验成功!",
+              });
+              this.checkDialogFormVisible = false;
+              this.getDataList();
             } else {
               this.$message({
-                type: 'error',
-                message: data.msg
-              })
+                type: "error",
+                message: data.msg,
+              });
             }
-          })
+          });
         }
-      })
+      });
     },
     // 操作损坏
-    damageTask (nodeId, productionId) {
-      this.damageDialogFormVisible = true
-      this.damageDialogForm.nodeId = nodeId
-      this.damageDialogForm.productionId = productionId
+    damageTask(nodeId, productionId) {
+      this.damageDialogFormVisible = true;
+      this.damageDialogForm.nodeId = nodeId;
+      this.damageDialogForm.productionId = productionId;
     },
     // 确认操作损坏
-    damageSubmit () {
-      this.$refs['damageDialogForm'].validate((valid) => {
+    damageSubmit() {
+      this.$refs["damageDialogForm"].validate((valid) => {
         if (valid) {
-          let submitData = this.damageDialogForm
+          let submitData = this.damageDialogForm;
           damageTask(submitData).then(({ data }) => {
-            if (data && data.code === '200') {
+            if (data && data.code === "200") {
               this.$message({
-                type: 'success',
-                message: '操作成功!'
-              })
-              this.damageDialogFormVisible = false
-              this.getDataList()
+                type: "success",
+                message: "操作成功!",
+              });
+              this.damageDialogFormVisible = false;
+              this.getDataList();
             } else {
               this.$message({
-                type: 'error',
-                message: data.msg
-              })
+                type: "error",
+                message: data.msg,
+              });
             }
-          })
+          });
         }
-      })
+      });
     },
     // 预览
-    previewFile (fileName, url) {
-      this.previewVisible = true
+    previewFile(fileName, url) {
+      this.previewVisible = true;
       this.$nextTick(() => {
-        this.$refs.preview.init(fileName, url)
-      })
+        this.$refs.preview.init(fileName, url);
+      });
     },
     // 计算进度百分比,返回0到100的整数
-    getPercentage (completeNum, totalNum) {
-      completeNum = completeNum == null ? 0 : parseInt(completeNum)
-      totalNum = totalNum == null ? 100 : parseInt(totalNum)
+    getPercentage(completeNum, totalNum) {
+      completeNum = completeNum == null ? 0 : parseInt(completeNum);
+      totalNum = totalNum == null ? 100 : parseInt(totalNum);
       if (totalNum === 0) {
-        return 100
+        return 100;
       }
 
-      return (completeNum / totalNum).toFixed(2) * 100
+      return (completeNum / totalNum).toFixed(2) * 100;
     },
     // 用户选择
-    userChanged (val) {
-      this.dataForm.userId = val
-      this.getDataList()
-    }
-  }
-}
+    userChanged(val) {
+      this.dataForm.userId = val;
+      this.getDataList();
+    },
+  },
+};
 </script>
 
 <style scoped></style>