schangxiang@126.com
2024-06-08 d939d095aa38879953884ea263eb45984b3876e7
iwara-scada-web/src/views/main/EquipmentWorkingLog/index.vue
@@ -29,15 +29,15 @@
                </a-select>
              </a-form-item>
            </a-col>
            <a-col :md="colMd" :sm="colSm">
              <a-form-item label="新增时间">
            <a-col :md="colMd2" :sm="colSm2">
              <a-form-item label="发生时间">
                <a-range-picker v-model="queryParam.logAddTimeRange" :placeholder="['开始日期', '结束日期']" />
              </a-form-item>
            </a-col>
            <a-col :md="colMd" :sm="colSm">
              <span class="table-page-search-submitButtons">
                <a-button type="primary" @click="$refs.table.refresh(true)">查询</a-button>
                <a-button style="margin-left: 8px" @click="() => (queryParam = {})">重置</a-button>
                <a-button style="margin-left: 8px" @click="resetQueryData">重置</a-button>
                <!-- <a @click="toggleAdvanced" style="margin-left: 8px"> {{ advanced ? '收起' : '展开' }}
                    <a-icon :type="advanced ? 'up' : 'down'" />
                  </a> -->
@@ -73,7 +73,7 @@
<script>
import { STable, XCard } from '@/components'
import { downloadFile } from '@/utils/util'
import { downloadFile,getThisWeekRange } from '@/utils/util'
import moment from 'moment'
import { EquipmentWorkingLogPage, equipmentWorkingLogToExcel } from '@/api/modular/main/EquipmentWorkingLogManage'
@@ -89,6 +89,8 @@
      gutter: 36,
      colMd: 6,
      colSm: 18,
      colMd2: 10,
      colSm2: 24,
      labelCol: {
        xs: { span: 24 },
        sm: { span: 8 }
@@ -161,7 +163,7 @@
          dataIndex: 'equipmentStateTimeHand'
        },
        {
          title: '新增时间',
          title: '发生时间',
          align: 'center',
          sorter: true,
          dataIndex: 'logAddTime'
@@ -190,9 +192,19 @@
  },
  created() {
    this.getEquipmentName()
    this.initData();
  },
  methods: {
    initData(){
      this.queryParam.logAddTimeRange = [];
      this.queryParam.logAddTimeRange = getThisWeekRange();
    },
     //重置
    resetQueryData(){
      this.queryParam = { logAddTimeRange:[] }
      this.initData();
    },
    moment,
    /**
     * 查询参数组装