维修丢失报表修复

This commit is contained in:
syruan 2025-08-29 18:22:00 +08:00
parent 79b064b554
commit a4ad662cab
2 changed files with 7 additions and 11 deletions

View File

@ -285,9 +285,9 @@ export default {
{ key: 'modelName', title: '规格型号' }, { key: 'modelName', title: '规格型号' },
{ key: 'mtUnitName', title: '单位' }, { key: 'mtUnitName', title: '单位' },
{ key: 'num', title: '维修数量' }, { key: 'num', title: '维修数量' },
{ key: 'cost', title: '维修费用(元)' }, { key: 'costs', title: '维修费用(元)' },
{ key: 'repairDate', title: '维修日期' }, { key: 'repairType', title: '维修方式' },
{ key: 'createTime', title: '创建时间' }, { key: 'partType', title: '费用类型' },
{ key: 'remark', title: '备注' } { key: 'remark', title: '备注' }
]; ];
@ -303,9 +303,9 @@ export default {
const dataRow = columns.map(col => { const dataRow = columns.map(col => {
if (col.key === 'index') { if (col.key === 'index') {
return (this.queryParams.pageNum - 1) * this.queryParams.pageSize + index + 1; return (this.queryParams.pageNum - 1) * this.queryParams.pageSize + index + 1;
} else if (col.key === 'cost') { } else if (col.key === 'costs') {
// //
return row.cost ? parseFloat(row.cost.toFixed(2)) : 0.00; return row.costs ? parseFloat(row.costs.toFixed(2)) : 0.00;
} else { } else {
return row[col.key] || ''; return row[col.key] || '';
} }
@ -328,8 +328,8 @@ export default {
{ wch: 8 }, // { wch: 8 }, //
{ wch: 10 }, // { wch: 10 }, //
{ wch: 15 }, // { wch: 15 }, //
{ wch: 12 }, // { wch: 12 }, //
{ wch: 15 }, // { wch: 12 }, //
{ wch: 20 } // { wch: 20 } //
]; ];
worksheet['!cols'] = columnWidths; worksheet['!cols'] = columnWidths;

View File

@ -284,8 +284,6 @@ export default {
{ key: 'mtUnitName', title: '单位' }, { key: 'mtUnitName', title: '单位' },
{ key: 'num', title: '报废数量' }, { key: 'num', title: '报废数量' },
{ key: 'cost', title: '报废费用(元)' }, { key: 'cost', title: '报废费用(元)' },
{ key: 'scrapDate', title: '报废日期' },
{ key: 'createTime', title: '创建时间' },
{ key: 'remark', title: '备注' } { key: 'remark', title: '备注' }
]; ];
@ -326,8 +324,6 @@ export default {
{ wch: 8 }, // { wch: 8 }, //
{ wch: 10 }, // { wch: 10 }, //
{ wch: 15 }, // { wch: 15 }, //
{ wch: 12 }, //
{ wch: 15 }, //
{ wch: 20 } // { wch: 20 } //
]; ];
worksheet['!cols'] = columnWidths; worksheet['!cols'] = columnWidths;