quanyawei
2024-09-12 9251f709dc2a0d278ef2c0cdd76a244bfefc5784
src/views/toCarryOutLegislativeReforms/reform/index.vue
@@ -7,6 +7,7 @@
      <searchBar
        v-if="searchType"
        :search-type="'reform'"
        :initialization-data="initializationData"
        @handleSearch="handleSearchBut"
        @handleAdd="handleOpenDialog(null, 'add')"
      />
@@ -566,6 +567,9 @@
          parseInt(item.dataKey) === this.editEscalationUnitData.polluteType
      )
      return data ? data.dataValue : ''
    },
    initializationData () {
      return this.$route.query
    }
  },
  watch: {
@@ -574,10 +578,32 @@
    }
  },
  created () {
    if (Object.entries(this.$route.query).length === 0) {
    this.handleSearch({ isInvalid: 0, state: [9, 20, 30] })
    } else {
      let state = []
      let changeType = null
      let startTime = this.initializationData.startTime
      let endTime = this.initializationData.endTime
      if (this.initializationData.type === 'total') {
        state = []
      } else if (this.initializationData.type === 'unComplete') {
        state = [9, 20, 30]
      } else if (this.initializationData.type === 'complete') {
        state = [40]
      } else if (this.initializationData.type === 'overdue') {
        state = []
        changeType = 2
      }
      this.handleSearch({ isInvalid: 0, state: state, changeType: changeType, startTime: startTime, endTime: endTime })
    }
    this.getUnitList()
    this.getContaminateList()
  },
  // mounted () {
  //   console.log('this.$route.query', this.$route.query)
  //   this.initializationData = this.$route.query
  // },
  methods: {
    getaddressAndLnt (position, address) {
      if (this.mapType === 'edit') {