diff options
author | xuri <xuri.me@gmail.com> | 2020-05-27 00:02:29 +0800 |
---|---|---|
committer | xuri <xuri.me@gmail.com> | 2020-05-27 00:02:29 +0800 |
commit | c168233e70db8f220bd07d9d6d277ae9e2a4a73f (patch) | |
tree | b5bba69c6bc4fc0b2a1429d3893d7a84eff6360b /rows.go | |
parent | 5c99300ee44de15e92bd8c5a92f2183c804d1379 (diff) |
speedup get cell value from shared string table
Diffstat (limited to 'rows.go')
-rw-r--r-- | rows.go | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -292,6 +292,11 @@ func (f *File) sharedStringsReader() *xlsxSST { log.Printf("xml decode error: %s", err) } f.SharedStrings = &sharedStrings + for i := range sharedStrings.SI { + if sharedStrings.SI[i].T != "" { + f.sharedStringsMap[sharedStrings.SI[i].T] = i + } + } f.addContentTypePart(0, "sharedStrings") rels := f.relsReader("xl/_rels/workbook.xml.rels") for _, rel := range rels.Relationships { |