|
|
@@ -197,7 +197,6 @@
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-/* -------------- 以下为 script,仅把 ContentWrap 的 props 拿过来 -------------- */
|
|
|
import * as QueryManageApi from "@/api/mes/queryManage";
|
|
|
import { getQueryManageButtonPage } from "@/api/mes/queryManage/button";
|
|
|
import { saveAs } from "file-saver";
|
|
|
@@ -306,20 +305,30 @@ export default {
|
|
|
},
|
|
|
|
|
|
async getList() {
|
|
|
+ console.log("getList被调用,queryParamList:", this.queryParamList);
|
|
|
try {
|
|
|
+ this.loading = true;
|
|
|
+ console.log("调用QueryManageApi.loadTableData,参数:", {
|
|
|
+ pageNo: this.pageNo,
|
|
|
+ pageSize: this.pageSize,
|
|
|
+ paramList: this.queryParamList,
|
|
|
+ id: this.$route.query?.id,
|
|
|
+ });
|
|
|
const data = await QueryManageApi.loadTableData({
|
|
|
pageNo: this.pageNo,
|
|
|
pageSize: this.pageSize,
|
|
|
paramList: this.queryParamList,
|
|
|
id: this.$route.query?.id,
|
|
|
});
|
|
|
- console.log("后端返回", data); // ← 看这里
|
|
|
+ console.log("后端返回", data);
|
|
|
this.list = data?.data?.list || [];
|
|
|
console.log("赋值后 list =", this.list);
|
|
|
console.log("list.length =", this.list.length);
|
|
|
console.log("list 第一条 =", this.list[0]);
|
|
|
this.originalList = JSON.parse(JSON.stringify(data?.data?.list || []));
|
|
|
this.total = data?.data?.total || 0;
|
|
|
+ } catch (error) {
|
|
|
+ console.error("getList错误:", error);
|
|
|
} finally {
|
|
|
this.loading = false;
|
|
|
}
|
|
|
@@ -559,6 +568,7 @@ export default {
|
|
|
},
|
|
|
|
|
|
filterData(data, field, type, row) {
|
|
|
+ console.log("filterData被调用:", { data, field, type, row });
|
|
|
const { dataType } = row;
|
|
|
this.$set(this.customFilters, field, data);
|
|
|
const isDateRange = data[0]?.isRange;
|
|
|
@@ -575,6 +585,10 @@ export default {
|
|
|
value: valueList,
|
|
|
});
|
|
|
}
|
|
|
+ console.log(
|
|
|
+ "filterData - 日期范围筛选后queryParamList:",
|
|
|
+ this.queryParamList
|
|
|
+ );
|
|
|
this.getList();
|
|
|
return;
|
|
|
}
|
|
|
@@ -599,6 +613,7 @@ export default {
|
|
|
const idx = this.queryParamList.findIndex((item) => item.key === field);
|
|
|
if (idx > -1) this.queryParamList.splice(idx, 1);
|
|
|
}
|
|
|
+ console.log("filterData - 筛选后queryParamList:", this.queryParamList);
|
|
|
this.getList();
|
|
|
},
|
|
|
|
|
|
@@ -791,7 +806,7 @@ export default {
|
|
|
margin-bottom: 3px;
|
|
|
}
|
|
|
|
|
|
-/* ---------- 你原来的表格样式 ---------- */
|
|
|
+/* ---------- 原来的表格样式 ---------- */
|
|
|
:deep(.el-table__row) {
|
|
|
height: 15px !important;
|
|
|
}
|