spring
2025-04-22 df559fa4353e312782841302d0281c7c98a81edb
修改检验任务
已修改4个文件
58 ■■■■■ 文件已修改
src/views/CNAS/resourceDemand/device/component/acquisitionConfig.vue 42 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/business/inspectionTask/components/InspectionWord.vue 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/business/inspectionTask/components/NetworkAnalyzerDataAcquisition.vue 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/business/inspectionTask/inspection.vue 5 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/CNAS/resourceDemand/device/component/acquisitionConfig.vue
@@ -148,7 +148,7 @@
        </div>
        <el-input size="small" placeholder="请输入" clearable v-model="configForm.collectUrl"></el-input>
      </div>
      <div class="search_thing" style="margin-bottom: 14px;" v-if="deviceName && deviceName.includes('网络分析')">
      <!-- <div class="search_thing" style="margin-bottom: 14px;" v-if="deviceName && deviceName.includes('网络分析')">
        <div class="search_label" style="width: 130px;">
          <span style="color:red;margin-right: 4px;">*</span>网分仪采集通道:
        </div>
@@ -156,7 +156,7 @@
          <el-option v-for="(item, index) in channelList" :key="index" :label="item" :value="item">
          </el-option>
        </el-select>
      </div>
      </div> -->
      <div class="search_thing" style="margin-bottom: 14px;" v-if="deviceName && !deviceName.includes('网络分析')">
        <div class="search_label">储存地址:</div>
        <el-input size="small" placeholder="请输入" clearable v-model="configForm.storageUrl"></el-input>
@@ -455,9 +455,9 @@
          this.tableList[0].fiberOpticRibbon
        )
        this.$set(this.configForm, "port", this.tableList[0].port);
        let arr = this.tableList[0].channel ? this.tableList[0].channel.split(',') : []
        this.$set(this.configForm, "channel", arr);
        this.channelList = arr
        // let arr = this.tableList[0].channel ? this.tableList[0].channel.split(',') : []
        // this.$set(this.configForm, "channel", arr);
        // this.channelList = arr
      }
    },
    init() {
@@ -514,18 +514,18 @@
            "fiberOpticRibbon",
            this.tableList[0].fiberOpticRibbon
          )
          let arr = this.tableList[0].channel ? this.tableList[0].channel.split(',') : []
          this.$set(
            this.configForm,
            "channel",
            arr
          )
          this.$set(
            this.configForm,
            "port",
            this.tableList[0].port
          )
          this.channelList = arr;
          // let arr = this.tableList[0].channel ? this.tableList[0].channel.split(',') : []
          // this.$set(
          //   this.configForm,
          //   "channel",
          //   arr
          // )
          // this.$set(
          //   this.configForm,
          //   "port",
          //   this.tableList[0].port
          // )
          // this.channelList = arr;
        }
        // 一般的合并行
        if (
@@ -582,15 +582,15 @@
        dbFileName: this.configForm.dbFileName,
        fiberOpticRibbon: this.configForm.fiberOpticRibbon,
        port: this.configForm.port,
        channel: this.configForm.channel
        // channel: this.configForm.channel
      });
      if (this.deviceName && this.deviceName.includes('网络分析')) {
        if (!this.configForm.port) {
          return this.$message.error("请填写端口");
        }
        if (!this.configForm.channel || !this.configForm.channel.length) {
          return this.$message.error("请填写网分仪采集通道");
        }
        // if (!this.configForm.channel || !this.configForm.channel.length) {
        //   return this.$message.error("请填写网分仪采集通道");
        // }
      }
      this.upLoad4 = true;
      saveDataAcquisitionConfiguration({ deviceId: this.deviceId, ...obj }).then(res => {
src/views/business/inspectionTask/components/InspectionWord.vue
@@ -1403,6 +1403,9 @@
        // 定义一个函数来验证分数是否有效
        if (typeof n.v.v == 'string') {
          function isValidFraction(fraction) {
            if (typeof fraction == 'number') {
              return true
            }
            const [numerator, denominator] = fraction.split('/'); // 分子和分母
            return !(!denominator || !numerator);
          }
src/views/business/inspectionTask/components/NetworkAnalyzerDataAcquisition.vue
@@ -12,7 +12,8 @@
        </el-form-item>
        <el-form-item label="通道" prop="memoryDir">
          <el-select v-model="form.memoryDir" placeholder="请选择">
            <el-option :label="item" :value="item" v-for="(item, index) in channel" :key="index"></el-option>
            <el-option v-for="(a, ai) in dict.type.domestic_network_analyzers" :key="ai" :label="a.label"
              :value="a.value"></el-option>
          </el-select>
        </el-form-item>
      </el-form>
@@ -32,6 +33,7 @@
  getTCPValuesNew
} from "@/api/business/inspectionTask.js";
export default {
  dicts: ['domestic_network_analyzers'],
  props: ['itemList', 'param', 'equipOptions'],
  data() {
    return {
@@ -39,7 +41,7 @@
      itemListNew: [],
      dialogVisible: false,
      form: {},
      channel: [],
      // channel: [],
      rules: {
        memoryDir: [
          { required: true, message: '请选择通道', trigger: 'change' }
@@ -87,7 +89,7 @@
          serverPort: equip.port,
          memoryDir: null
        }
        this.channel = equip.channel ? equip.channel.split(',') : []
        // this.channel = equip.channel ? equip.channel.split(',') : []
        this.dialogVisible = true
      }
    },
src/views/business/inspectionTask/inspection.vue
@@ -290,7 +290,7 @@
                      state == 1
                    "><span :style="`font-family:${n.v.ff} !important;`">{{
                      toFixed(n.v.v, n.v.ct)
                        }}</span></template>
                    }}</span></template>
                    <template v-else-if="
                      n.v.ps != undefined &&
                      n.v.ps.value === '最终值' &&
@@ -2277,6 +2277,9 @@
        // 定义一个函数来验证分数是否有效
        if (typeof n.v.v == "string") {
          function isValidFraction(fraction) {
            if (typeof fraction == 'number') {
              return true
            }
            const [numerator, denominator] = fraction.split("/"); // 分子和分母
            return !(!denominator || !numerator);
          }