summaryrefslogtreecommitdiff
path: root/page.go
diff options
context:
space:
mode:
authorJulian Jørgensen <julian@jtle.dk>2024-05-24 21:30:23 +0200
committerJulian Jørgensen <julian@jtle.dk>2024-05-24 21:30:23 +0200
commit2f83424ce8a0653e6e158318df1511daecf1a42d (patch)
treeb29c1b5c8df940873521d013697209195956151e /page.go
parent19f8454a680c5231df68fee36ed9758587df316c (diff)
Time format rework
Diffstat (limited to 'page.go')
-rw-r--r--page.go14
1 files changed, 7 insertions, 7 deletions
diff --git a/page.go b/page.go
index 384ca57..c3ab160 100644
--- a/page.go
+++ b/page.go
@@ -5,14 +5,14 @@ type Service struct {
}
type EntryPage struct {
- Task *Task
+ Entry *Entry
Detached bool
- Tracking *Task
+ Tracking *Entry
}
type RootPage struct {
Entry *EntryPage
- Tasks []*Task
+ Entries []*Entry
}
func NewService(db Database) *Service {
@@ -21,20 +21,20 @@ func NewService(db Database) *Service {
}
}
-func (srv *Service) GetEntryPage(detached *Task) (*EntryPage, error) {
+func (srv *Service) GetEntryPage(detached *Entry) (*EntryPage, error) {
tracking, err := srv.Db.GetTracking()
if err != nil {
return nil, err
}
page := &EntryPage {
- Task: tracking,
+ Entry: tracking,
Detached: false,
Tracking: tracking,
}
if detached != nil {
- page.Task = detached
+ page.Entry = detached
page.Detached = true
}
@@ -54,6 +54,6 @@ func (srv *Service) GetRootPage() (*RootPage, error) {
return &RootPage {
Entry: entry,
- Tasks: tasks,
+ Entries: tasks,
}, nil
}