Skip to content

Commit

Permalink
Merge pull request #6 from tomtwinkle/fix/set-cell-value-override-style
Browse files Browse the repository at this point in the history
fix: setCellValue() override cell style
  • Loading branch information
tomtwinkle authored Aug 22, 2022
2 parents 25365da + 3c8b122 commit ec31cce
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions excelizeam.go
Original file line number Diff line number Diff line change
Expand Up @@ -202,13 +202,14 @@ func (e *excelizeam) setCellValue(colIndex, rowIndex int, value interface{}, sty
return err
}
cell.StyleID = styleID
} else {
styleID, err := e.getStyleID(style)
if err != nil {
return err
}
cell.StyleID = styleID
return nil
}
styleID, err := e.getStyleID(style)
if err != nil {
return err
}
cell.StyleID = styleID
return nil
}
styleID, err := e.getStyleID(style)
if err != nil {
Expand Down Expand Up @@ -525,7 +526,7 @@ func (e *excelizeam) setBorderRange(startColIndex, startRowIndex, endColIndex, e
if err != nil {
return err
}
e.cellStore.Store(key, &Cell{
e.cellStore.Store(colIdx, &Cell{
StyleID: styleID,
Value: nil,
})
Expand Down

0 comments on commit ec31cce

Please sign in to comment.