fix(测试跟踪): 测试计划报告列表按名称排序结果不对

--bug=1025040 --user=陈建星 测试跟踪-测试报告-按名称大小排序-未按照名称大小排序 https://www.tapd.cn/55049933/s/1358600
This commit is contained in:
chenjianxing 2023-04-03 14:41:22 +08:00 committed by jianxing
parent acbea85d98
commit bc471a2fe4
2 changed files with 1 additions and 64 deletions

View File

@ -8,7 +8,7 @@
:prop="prop"
:column-key="columnKey ? columnKey : prop"
:label="label"
:sortable="sortable"
:sortable="sortable ? 'custom' : false"
:filter-method="filterMethod"
:filtered-value="filteredValue "
:render-header="renderHeader"

View File

@ -169,18 +169,9 @@ import { TEST_PLAN_REPORT_CONFIGS } from "metersphere-frontend/src/components/se
import ReportTriggerModeItem from "metersphere-frontend/src/components/tableItem/ReportTriggerModeItem";
import MsTag from "metersphere-frontend/src/components/MsTag";
import ShowMoreBtn from "metersphere-frontend/src/components/table/ShowMoreBtn";
import MsTableSelectAll from "metersphere-frontend/src/components/table/MsTableSelectAll";
import {
_filter,
_handleSelect,
_handleSelectAll,
_sort,
getLastTableSortField,
getSelectDataCounts,
initCondition,
saveLastTableSortField,
setUnSelectIds,
toggleAllSelection,
getCustomTableWidth,
getCustomTableHeader,
} from "metersphere-frontend/src/utils/tableUtils";
@ -210,7 +201,6 @@ export default {
ReportTriggerModeItem,
MsTag,
ShowMoreBtn,
MsTableSelectAll,
MsTableColumn,
MsTable,
MsRenameReportDialog,
@ -339,24 +329,6 @@ export default {
this.tableData = data.listObject;
});
},
handleSelect(selection, row) {
_handleSelect(this, selection, row, this.selectRows);
setUnSelectIds(this.tableData, this.condition, this.selectRows);
this.selectDataCounts = getSelectDataCounts(
this.condition,
this.total,
this.selectRows
);
},
handleSelectAll(selection) {
_handleSelectAll(this, selection, this.tableData, this.selectRows);
setUnSelectIds(this.tableData, this.condition, this.selectRows);
this.selectDataCounts = getSelectDataCounts(
this.condition,
this.total,
this.selectRows
);
},
handleDelete(testPlanReport) {
this.$alert(
this.$t("report.delete_confirm") + " " + testPlanReport.name + " ",
@ -401,19 +373,6 @@ export default {
let ids = rowArray.map((s) => s.id);
return ids;
},
filter(filters) {
_filter(filters, this.condition);
this.initTableData();
},
sort(column) {
//
if (this.condition.orders) {
this.condition.orders = [];
}
_sort(column, this.condition);
this.saveSortField(this.tableHeaderKey, this.condition.orders);
this.initTableData();
},
openReport(report) {
if (report.id) {
if (report.isNew) {
@ -423,28 +382,6 @@ export default {
}
}
},
isSelectDataAll(data) {
this.condition.selectAll = data;
//
toggleAllSelection(
this.$refs.testPlanReportTable,
this.tableData,
this.selectRows
);
//
_handleSelectAll(this, this.tableData, this.tableData, this.selectRows);
//ID()
this.condition.unSelectIds = [];
//
this.selectDataCounts = getSelectDataCounts(
this.condition,
this.total,
this.selectRows
);
},
saveSortField(key, orders) {
saveLastTableSortField(key, JSON.stringify(orders));
},
openReNameDialog($event) {
this.$refs.renameDialog.open($event);
},