- commit
- d181cafc7b609ebe070737b7382e49805fd8a95d
- parent
- 351734b3180d872950bac650eaa15aded202ed87
- author
- Dami <dami.etoile@gmail.com>
| M | internal/ | 11 | ++++------- |
@@ -68,10 +68,6 @@ func importXLSXExcelize(ctx context.Context, name string, opt Options) (*Result,
6868 if err != nil {6969 return nil, err7070 }71- excelizePanes(x, ws, next)72- if err := excelizeNotes(x, ws, next); err != nil {73- return nil, err74- }7571 done += rows7672 }7773 filters, protected, err := referenceAutoFilters(name)@@ -93,11 +89,12 @@ func importXLSXExcelize(ctx context.Context, name string, opt Options) (*Result,
9389 return &Result{Sheet: s, Rows: done, Notes: append(notes, applyFilters(book, filters)...)}, nil9490 }9591 96-// excelizePanes freezes s as sheet ws is frozen.97-func excelizePanes(x *excelize.File, ws string, s *sheet.Sheet) {92+// excelizeView freezes s as sheet ws is frozen and loads its notes.93+func excelizeView(x *excelize.File, ws string, s *sheet.Sheet) error {9894 if p, err := x.GetPanes(ws); err == nil && p.Freeze {9995 s.LoadFrozen(p.YSplit, p.XSplit)10096 }97+ return excelizeNotes(x, ws, s)10198 }10299 103100 // excelizeNotes loads sheet ws's notes (Excel's legacy comments) into s.@@ -283,7 +280,7 @@ func excelizeSheet(ctx context.Context, x *excelize.File, b *builder, ws string,
283280 }284281 b.s.LoadColWidth(c, max(int(math.Round(w))+excelPadding, 1))285282 }286- return row, nil283+ return row, excelizeView(x, ws, b.s)287284 }288285 289286 // excelizeNames defines the workbook's named ranges that are a range on