qushaowei
2023-08-21 f5e8a1a00baf276c281d4a6335b2d39a8beba91a
src/views/eam/modules/equipment/EquipmentModel.vue
@@ -215,14 +215,22 @@
                placeholder="请输入所有组织"
                v-decorator="['affiliationId', validatorRules.affiliationId]"
              /> -->
              <a-select
              <!-- <a-select
                :placeholder="disableSubmit?'':'请选择所有组织'"
                :options="this.departs"
                style="width: 100%"
                :disabled="disableSubmit"
                v-decorator="['affiliationId', validatorRules.affiliationId]"
              />
              /> -->
              <!-- @change="(e)=>handle1Change(e)" -->
              <a-tree-select
                style="width: 100%"
                :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }"
                :tree-data="treeData"
                placeholder="请选择管理组织"
                tree-default-expand-all
                v-decorator="['affiliationId', validatorRules.affiliationId]"
              />
            </a-form-item>
          </a-col>
          <a-col :span="24 / 3">
@@ -249,14 +257,22 @@
                placeholder="请输入管理组织"
                v-decorator="['manageId', validatorRules.manageId]"
              /> -->
              <a-select
              <!-- <a-select
                :placeholder="disableSubmit?'':'请选择管理组织'"
                :options="this.departs"
                style="width: 100%"
                :disabled="disableSubmit"
                v-decorator="['manageId', validatorRules.manageId]"
              />
              /> -->
              <!-- @change="(e)=>handle3Change(e)" -->
              <a-tree-select
                style="width: 100%"
                :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }"
                :tree-data="treeData"
                placeholder="请选择管理组织"
                tree-default-expand-all
                v-decorator="['manageId', validatorRules.manageId]"
              />
            </a-form-item>
          </a-col>
          <a-col :span="24 / 3">
@@ -299,23 +315,23 @@
              :wrapperCol="wrapperCol"
              label="使用部门"
            >
              <!-- <j-dict-select-tag
                allow-clear
                :disabled="disableSubmit"
                :placeholder="disableSubmit?'':'请选择使用组织'"
                :triggerChange="true"
                dictCode="sys_depart,depart_name,id,version = '7' and del_flag!='1'"
              <a-tree-select
                style="width: 100%"
                :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }"
                :tree-data="treeData"
                placeholder="请选择部门"
                tree-default-expand-all
                v-decorator="['useId', validatorRules.useId]"
              /> -->
              <a-select
              />
              <!-- <a-select
                :placeholder="disableSubmit?'':'请选择使用部门'"
                :options="this.departs"
                style="width: 100%"
                :disabled="disableSubmit"
                v-decorator="['useId', validatorRules.useId]"
              />
              <!-- @change="(e)=>handle2Change(e)" -->
              /> -->
            </a-form-item>
          </a-col>
          <a-col :span="24 / 3">
@@ -330,7 +346,7 @@
                :placeholder="disableSubmit?'':'请选择责任班组'"
                :triggerChange="true"
                dictCode="mom_base_team,name,id,status='1' and del_flag='0'"
                v-decorator="['teamId', validatorRules.teamId]"
                v-decorator="['teamId', {}]"
              />
            </a-form-item>
          </a-col>
@@ -553,7 +569,6 @@
        关闭
      </a-button>
      <a-button
        hidden
        v-if="!this.model.id"
        :disabled="disableSubmit || confirmLoading"
        :loading="confirmLoading"
@@ -610,6 +625,7 @@
      precisionParametersTemplateId: '',
      equipmentPhoto: '',
      departs: [],
      treeData: [],
      model: {},
      headers: {},
      labelCol: {
@@ -662,6 +678,7 @@
        add: "/eam/equipment/add",
        edit: "/eam/equipment/edit",
        getSysDeparts: "/eam/equipment/getSysDeparts",
        loadOptions: '/sys/sysDepart/loadDepartTreeOptions',
      },
      //新增、编辑、删除、批量删除操作改变数据后刷新关联的组件的监听属性
      alterFlag: "",
@@ -669,6 +686,7 @@
  },
  created() {
    this.getSysDeparts()
  },
  methods: {
    moment,
@@ -683,6 +701,7 @@
      this.visible = true;
      this.disableSubmit = false;
      this.fileList = [];
      this.initOptions();
      this.precisionParametersTemplateId = record.precisionParametersTemplateId
      this.processParametersTemplateId = record.processParametersTemplateId
      this.$nextTick(() => {
@@ -937,6 +956,16 @@
      }
    },
    initOptions() {
      getAction(this.url.loadOptions).then(res => {
        if (res.success) {
          this.treeData = res.result
        } else {
          this.$message.warning(res.message)
        }
      })
    },
    onSearchProcessParametersTemplate() {
      this.$refs.ProcessParametersTemplateList.list();