refactor(FE): Refactor getDetailData to remove unused parameters

This commit is contained in:
rstubryan
2026-02-10 13:37:34 +07:00
parent 4775c1e115
commit 2af83bed8a
@@ -203,11 +203,7 @@ const getDetailColumns = (): PdfColumn[] => [
},
];
const getDetailData = (
rows: HppPerKandangRow[],
allFeedSuppliers: string,
allDocSuppliers: string
): PdfTbodyCell[][] => {
const getDetailData = (rows: HppPerKandangRow[]): PdfTbodyCell[][] => {
return rows.map((item, index) => [
{ key: 'no', value: index + 1 },
{ key: 'kandang', value: item.kandang?.name || '-' },
@@ -370,11 +366,7 @@ const createPDFDocument = (
</PdfTypography>
<PdfTable
columns={getDetailColumns()}
data={getDetailData(
params.data.rows,
allFeedSuppliers,
allDocSuppliers
)}
data={getDetailData(params.data.rows)}
footer={
params.data.summary
? getDetailFooter(