support two digits year

This commit is contained in:
MaysWind
2025-02-13 23:30:43 +08:00
parent 306da60752
commit 7a1b27927f
2 changed files with 39 additions and 3 deletions
@@ -3,6 +3,7 @@ package iif
import (
"fmt"
"strings"
"time"
"github.com/mayswind/ezbookkeeping/pkg/converters/datatable"
"github.com/mayswind/ezbookkeeping/pkg/core"
@@ -316,6 +317,10 @@ func (t *iifTransactionDataRowIterator) parseTransactionTime(dataset *iifTransac
day = dateParts[2]
}
if len(year) == 2 {
year = utils.IntToString(time.Now().Year()/100) + year
}
if len(month) < 2 {
month = "0" + month
}