田源
2024-01-15 6649a2f438efba0e3371a00c3b3dbe3d54310be7
Source/UBCS-WEB/src/components/FormTemplate/ThemeChildren.vue
@@ -5,7 +5,7 @@
        <el-select v-model="SelectValue" placeholder="请选择" style="width: 135px">
          <el-option
            v-for="item in SelectOption"
            :key="item.value"
            :key="item.key"
            :label="item.label"
            :value="item.value"
            style="width: 150px">
@@ -16,7 +16,7 @@
        <el-button plain size="small" style="margin-left: 20px" type="primary" @click="SelectSearchHandler">查询
        </el-button>
      </template>
      <avue-crud :data="TableData" :option="this.codeType === 'btmCode' ? this.btmOption : this.option" @row-click="rowHandlerClick">
      <avue-crud :data="TableData" :option="this.codeType === 'btmCode' ? this.btmOption : this.option" @row-click="rowHandlerClick" :table-loading="loading">
        <template slot="radio" slot-scope="{row}">
          <el-radio v-model="radioValue" :label="row.$index" style="padding-left: 10px !important;">{{ '' }}
          </el-radio>
@@ -74,6 +74,7 @@
      crudName: '',
      crudOid: '',
      TableData: [],
      loading:false,
      option: {
        addBtn: false,
        index: true,
@@ -82,6 +83,7 @@
        border: true,
        menu: false,
        height: 380,
        rowKey: "oid",
        column: [
          {
            label: '',
@@ -111,6 +113,7 @@
        border: true,
        menu: false,
        height:380,
        rowKey: "oid",
        column:[
          {
            label: '',
@@ -135,6 +138,7 @@
    }
  },
  created() {
    this.loading = true;
  },
  mounted() {
  },
@@ -162,13 +166,13 @@
    },
    // 模糊查询
    SelectSearchHandler() {
      if (!this.SelectOption) {
        return; // 如果SelectOption数据不存在直接返回 避免报错
      this.loading = true;
      if (!this.SelectOption || this.SelectOption.length === 0) {
        this.loading = false;
        return;
      }
      const Parameter = {};
      Parameter[`conditionMap['${this.SelectValue}']`] = this.SelectSearchValue;
      if(this.codeType === "btmCode"){
        this.btmDefaultRend(Parameter)
      }else {
@@ -205,11 +209,13 @@
        ...Parameter
      }).then(res => {
        this.TableData = res.data.records;
        this.loading = false;
      })
    },
    btmDefaultRend(Parameter) {
      referDataGrid({valueField: 'id', isMuti: 'false', 'limit': '-1', ...Parameter}).then(res => {
        this.TableData = res.data.data.records
        this.TableData = res.data.data.records;
        this.loading = false;
      })
    },
  }