gaoluyang
5 天以前 af4f913751c08fd6ef70cb183de2fb3c604bab38
src/views/procurementManagement/paymentHistory/index.vue
@@ -32,6 +32,7 @@
        >
          搜索
        </el-button>
        <el-button @click="handleExport">导出</el-button>
      </el-form-item>
    </el-form>
    <div class="table_list">
@@ -53,7 +54,7 @@
</template>
<script setup>
import { ref } from "vue";
import { ref, reactive, getCurrentInstance, onMounted } from "vue";
import { Search } from "@element-plus/icons-vue";
import { paymentHistoryListPage } from "@/api/procurementManagement/paymentEntry.js";
import useFormData from "@/hooks/useFormData";
@@ -106,12 +107,9 @@
const total = ref(0);
const { form: searchForm } = useFormData({
  searchText: undefined,
  paymentDate: [
    dayjs().startOf("month").format("YYYY-MM-DD"),
    dayjs().endOf("month").format("YYYY-MM-DD"),
  ],
  paymentDateStart: dayjs().startOf("month").format("YYYY-MM-DD"),
  paymentDateEnd: dayjs().endOf("month").format("YYYY-MM-DD"),
  paymentDate: [],
  paymentDateStart: undefined,
  paymentDateEnd: undefined,
});
// 查询列表
@@ -161,6 +159,12 @@
  getList();
};
// 导出
const handleExport = () => {
  const { paymentDate, ...rest } = searchForm;
  proxy.download("/purchase/paymentRegistration/export", { ...rest, ...page }, "付款流水.xlsx");
};
onMounted(() => {
  getList();
});