王震
2023-12-04 8afbe0b83915dc417cea62221782e7ce15c00c78
src/views/technology/operation/operation-form.vue
@@ -188,7 +188,7 @@
      <div class="operation-detail">
        <el-tabs type="card" style="width: 100%;height: 100%">
          <el-tab-pane label="基础" style="height: 100%">
          <!-- <el-tab-pane label="基础" style="height: 100%">
            <el-card class="operation-capacity" header="工序能力">
              <el-transfer
                filterable
@@ -226,7 +226,7 @@
                </div>
              </el-upload>
            </el-card>
          </el-tab-pane>
          </el-tab-pane> -->
          <el-tab-pane label="参数" style="height: 100%">
            <el-card class="operation-capacity" header="工序参数集模板">
              <div slot="header">
@@ -448,7 +448,7 @@
        laborRunFactor: 0,
        laborSetupTime: 0,
        runTimeCodeDb: '2',
        crewSize: 1,
        crewSize: null,
        outsideOpItem:null
      },
      operationTemplateList: [],
@@ -592,8 +592,8 @@
      // }
    },
    init() {
      this.operationId = this.dataForm.id
      this.fetchCapabilityForOperation()
      // this.operationId = this.dataForm.id
      // this.fetchCapabilityForOperation()
      if (this.dataForm.id) {
        getObj(this.dataForm.id).then((response) => {
          this.dataForm = response.data.data
@@ -724,7 +724,7 @@
      this.dataForm.laborRunFactor = 0
      this.dataForm.laborSetupTime = 0
      this.dataForm.runTimeCodeDb = '2'
      this.dataForm.crewSize = 1
      this.dataForm.crewSize = null
      this.fileList = []
      this.operationTemplateList = []
      this.stepList = []
@@ -751,17 +751,17 @@
      this.$refs.dataForm.validate((valid) => {
        if (valid) {
          // 校验【机器运转因素】、【机器设置时间】、【劳力运转因素】、【劳力设置时间】中至少有一个字段的值须大于0
          if (
            this.dataForm.machRunFactor == 0 &&
            this.dataForm.machSetupTime == 0 &&
            this.dataForm.laborRunFactor == 0 &&
            this.dataForm.laborSetupTime == 0
          ) {
            this.$message.error(
              '【机器运转因素】、【机器设置时间】、【劳力运转因素】、【劳力设置时间】中至少有一个字段的值须大于0'
            )
            this.isSubmit = false
          } else {
          // if (
          //   this.dataForm.machRunFactor == 0 &&
          //   this.dataForm.machSetupTime == 0 &&
          //   this.dataForm.laborRunFactor == 0 &&
          //   this.dataForm.laborSetupTime == 0
          // ) {
          //   this.$message.error(
          //     '【机器运转因素】、【机器设置时间】、【劳力运转因素】、【劳力设置时间】中至少有一个字段的值须大于0'
          //   )
          //   this.isSubmit = false
          // } else {
            // 【人工类别】为空时【班组人员】必须为空,否则必须大于0
            let remindInfo = ''
            let remindFlag = false
@@ -828,7 +828,7 @@
                  })
              }
            }
          }
          // }
        } else {
          this.isSubmit = false
        }