Commit 70614668 by 张杰

修复分页跳转

1 parent 3f80dbda
......@@ -129,7 +129,7 @@ export default {
label: "当前电量",
prop: "soc",
formatter: (row) => {
return `${(row.soc || row.soc==0)?row.soc + '%':'--'}`;
return `${row.soc || row.soc == 0 ? row.soc + "%" : "--"}`;
},
},
],
......@@ -169,7 +169,7 @@ export default {
acceptFile: ".xlsx,.xls",
};
},
mounted() {
let token = localStorage.getItem("token");
this.uploadHeaders = { Authorization: token };
......@@ -179,13 +179,21 @@ export default {
// 获取查询参数
getParams() {
let oParams = deepClone(this.searchForm);
if ((oParams.minBattery||oParams.minBattery == 0) && !oParams.maxBattery && oParams.maxBattery !== 0) {
if (
(oParams.minBattery || oParams.minBattery == 0) &&
!oParams.maxBattery &&
oParams.maxBattery !== 0
) {
showToast({
message: "请输入最大电量",
});
return false;
}
if (!oParams.minBattery && oParams.minBattery !== 0 && (oParams.maxBattery|| oParams.maxBattery==0)) {
if (
!oParams.minBattery &&
oParams.minBattery !== 0 &&
(oParams.maxBattery || oParams.maxBattery == 0)
) {
showToast({
message: "请输入最小电量",
});
......
......@@ -156,7 +156,7 @@ export default {
// 获取列表
getList(options) {
let oParams = this.getParams();
oParams.pageSize = this.$refs.glsxTable.pageSize;
oParams.pageSize = options?options.pageSize:this.$refs.glsxTable.pageSizeNum;
oParams.pageNumber = options ? options.pageNumber || 1 : 1;
this.loading = true;
GET_JOURNEYS_SEARCH(oParams)
......@@ -254,8 +254,9 @@ export default {
this.searchText = "";
this.preText = "orderNo";
this.mileageDate = []
this.getList();
this.$refs.glsxTable.rest();
this.getList();
},
},
};
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!