Implemented GetFilteredEntries and extended export command

This commit is contained in:
マリウス
2020-10-17 15:32:41 +01:00
parent 64a17e4db9
commit df06d63fa8
4 changed files with 87 additions and 6 deletions
+2 -2
View File
@@ -5,7 +5,7 @@ import (
// "fmt"
"os"
"github.com/shopspring/decimal"
// "time"
"time"
)
var formatTymeJson bool
@@ -50,7 +50,7 @@ func (tyme *Tyme) Load(filename string) error {
return nil
}
func (tyme *Tyme) FromEntries(entries []Entry) error {
func (tyme *Tyme) FromEntries(entries []*Entry) error {
for _, entry := range entries {
duration := decimal.NewFromFloat(entry.Finish.Sub(entry.Begin).Minutes())