| | |
| | | <el-form-item label="日期"> |
| | | <el-date-picker |
| | | style="width: 240px" |
| | | v-model="filters.dateRange" |
| | | v-model="filters.month" |
| | | value-format="YYYY-MM" |
| | | format="YYYY-MM" |
| | | type="month" |
| | |
| | | <el-form-item> |
| | | <el-button type="primary" @click="getTableData"> 搜索 </el-button> |
| | | <el-button @click="resetFilters"> 重置 </el-button> |
| | | <el-button @click="handleOut"> 导出 </el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div class="table_list"> |
| | |
| | | size: pagination.pageSize, |
| | | total: pagination.total, |
| | | }" |
| | | @pagination="onCurrentChange" |
| | | @pagination="changePage" |
| | | /> |
| | | </div> |
| | | </div> |
| | |
| | | |
| | | <script setup> |
| | | import { usePaginationApi } from "@/hooks/usePaginationApi"; |
| | | import { onMounted } from "vue"; |
| | | import { onMounted, getCurrentInstance } from "vue"; |
| | | import { getTaxList } from "@/api/procurementManagement/taxComparison"; |
| | | import { ElMessageBox } from "element-plus"; |
| | | |
| | | const { proxy } = getCurrentInstance(); |
| | | |
| | | defineOptions({ |
| | | name: "增值税比对", |
| | |
| | | } = usePaginationApi( |
| | | getTaxList, |
| | | { |
| | | dateRange: [], // 来票日期 |
| | | month: [], // 来票日期 |
| | | }, |
| | | [ |
| | | { |
| | |
| | | {} |
| | | ); |
| | | |
| | | const changePage = ({ page }) => { |
| | | pagination.currentPage = page; |
| | | onCurrentChange(page); |
| | | }; |
| | | |
| | | // 导出 |
| | | const handleOut = () => { |
| | | ElMessageBox.confirm("选中的内容将被导出,是否确认导出?", "导出", { |
| | | confirmButtonText: "确认", |
| | | cancelButtonText: "取消", |
| | | type: "warning", |
| | | }) |
| | | .then(() => { |
| | | proxy.download("/purchase/report/exportTwo", {}, "增值税比对.xlsx"); |
| | | }) |
| | | .catch(() => { |
| | | proxy.$modal.msg("已取消"); |
| | | }); |
| | | }; |
| | | |
| | | onMounted(() => { |
| | | getTableData(); |
| | | }); |