''
liukangdong
2024-06-11 f49cf1c04d06333ace67926430c651ca3cc1752f
admin/src/views/task/index.vue
@@ -5,7 +5,20 @@
      :query-form-config="queryFormConfig"
      @handleQuery="getList(1)"
      @clear="clear"
    />
      @changeForm='changeForm'
    >
      <template #fastdate>
        <el-radio-group
          v-model="filters.fastdate"
          size="small"
          @input="changeRadio"
        >
          <el-radio-button label="0">当天</el-radio-button>
          <el-radio-button label="6">近7天</el-radio-button>
          <el-radio-button label="29">近30天</el-radio-button>
        </el-radio-group>
      </template>
    </QueryForm>
    <!--  -->
    <el-tabs v-model="filters.queryType" @tab-click="(e) => getList(1)">
      <el-tab-pane label="待处理" name="0">
@@ -129,6 +142,7 @@
import OperaCarUseBookWindow from '@/components/business/OperaCarUseBookWindow'
import OperaHiddenDangerWindow from '@/components/business/OperaHiddenDangerWindow'
import OperaVisitsDesWindow from '@/components/business/OperaVisitsDesWindow'
import dayjs from 'dayjs'
import {
  taskCenterHead,
  taskCenterPage
@@ -150,7 +164,8 @@
      isShowReport: false,
      isShowDanger: false,
      filters: {
        queryType: '0'
        queryType: '0',
        fastdate: 0
      },
      queryFormConfig: {
        formItems: [
@@ -170,6 +185,11 @@
          {
            filed: 'selDate',
            type: 'daterange',
            label: '起始日期'
          },
          {
            type: 'slot',
            filed: 'fastdate',
            label: ''
          }
        ],
@@ -195,9 +215,14 @@
  },
  created () {
    this.getHeadData()
    this.getList()
    this.changeRadio('0')
  },
  methods: {
    changeRadio (day) {
      const arr = [dayjs().subtract(day, 'day').format('YYYY-MM-DD'), dayjs().format('YYYY-MM-DD')]
      this.$set(this.filters, 'selDate', arr)
      this.getList()
    },
    handleDetail (row) {
      if (row.objType === 2) {
        this.$refs.OperaDetailsWindow.open('公务车申请详情', row)
@@ -226,6 +251,12 @@
          this.$refs.DetailRef.getDetail()
          this.$refs.DetailRef.isShowModal = true
        })
      }
    },
    changeForm (str) {
      if (str === 'selDate') {
        this.$set(this.filters, 'fastdate', null)
        this.getList()
      }
    },
    getList (page) {
@@ -259,7 +290,8 @@
    },
    clear () {
      this.filters = {
        queryType: '0'
        queryType: '0',
        fastdate: 0
      }
      this.getList(0)
    },