fix(web-admin): 运输归档合计行与可见表头列对齐。
planNo 可隐藏后不再硬编码插入,避免统计行按索引错位。 Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
1 parent
82c21262ed
commit
04450fff88
2 files changed
+76
-17
No files matched your search
@@ -970,7 +970,7 @@ import {
|
||||
overflowExportPlaceholder
|
||||
} from '@/utils/list-toolbar-overflow-items'
|
||||
import ListColumnStatsRow from '@/components/business/list-column-stats-row/index.vue'
|
||||
import type { StatsRowColumn } from '@/utils/list-column-stats'
|
||||
import { buildStatsRowColumns, type StatsRowColumn } from '@/utils/list-column-stats'
|
||||
import { useContractDetailDialog } from '@/composables/useContractDetailDialog'
|
||||
import { usePersistedListColumns } from '@/composables/usePersistedListColumns'
|
||||
import { useListTableViewportHeight } from '@/composables/useListTableViewportHeight'
|
||||
@@ -1287,22 +1287,15 @@ const {
|
||||
|
||||
const archiveStatsRowRef = ref<{ resync?: () => void } | null>(null)
|
||||
|
||||
const archiveStatsRowColumns = computed((): StatsRowColumn[] => {
|
||||
const cols: StatsRowColumn[] = [
|
||||
{ key: '__selection', interactive: false },
|
||||
{ key: '__index', interactive: false },
|
||||
{ key: 'planNo', interactive: true, prop: 'planNo' }
|
||||
]
|
||||
for (const def of listColumnDefs.value) {
|
||||
if (!isArchiveColumnVisible(def.prop)) continue
|
||||
cols.push({
|
||||
key: def.prop,
|
||||
interactive: true,
|
||||
prop: def.prop
|
||||
})
|
||||
}
|
||||
return cols
|
||||
})
|
||||
/** 与表头可见列一一对应:勾选/序号占位 + 可见业务列(含可隐藏的 planNo) */
|
||||
const archiveStatsRowColumns = computed((): StatsRowColumn[] =>
|
||||
buildStatsRowColumns({
|
||||
leadingSpacers: 2,
|
||||
optionalDefs: listColumnDefs.value,
|
||||
isColumnVisible: isArchiveColumnVisible,
|
||||
moneyProps: PRICE_COLUMN_PROPS
|
||||
})
|
||||
)
|
||||
|
||||
function getArchiveStatCellValue(row: PlPlanListDisplayRow, prop: string): unknown {
|
||||
const plan = row.plan
|
||||
|
||||
Reference in new issue
Block a user