aboutsummaryrefslogtreecommitdiffstats
path: root/internal/chore/model
diff options
context:
space:
mode:
authorLibravatar Mo Tarbin <mhed.t91@gmail.com>2024-07-06 02:36:14 -0400
committerLibravatar Mo Tarbin <mhed.t91@gmail.com>2024-07-06 02:36:14 -0400
commit45e18c8edd55e98712d5f175ecaaae86fde4d933 (patch)
treee7364d8e48a85c897de019f0786eff4c6dc2a990 /internal/chore/model
parentf115d70c49048e3ec3ee768bd9cd85f9b06c1631 (diff)
downloaddonetick-45e18c8edd55e98712d5f175ecaaae86fde4d933.tar.gz
donetick-45e18c8edd55e98712d5f175ecaaae86fde4d933.tar.bz2
donetick-45e18c8edd55e98712d5f175ecaaae86fde4d933.zip
Add GetChoreDetail endpoint to retrieve detailed chore information
Diffstat (limited to 'internal/chore/model')
-rw-r--r--internal/chore/model/model.go12
1 files changed, 12 insertions, 0 deletions
diff --git a/internal/chore/model/model.go b/internal/chore/model/model.go
index 09cc658..2e7ee90 100644
--- a/internal/chore/model/model.go
+++ b/internal/chore/model/model.go
@@ -70,3 +70,15 @@ type Tag struct {
// CircleID int `json:"circleId" gorm:"primaryKey;autoIncrement:false"`
// TagID int `json:"tagId" gorm:"primaryKey;autoIncrement:false"`
// }
+
+type ChoreDetail struct {
+ ID int `json:"id" gorm:"column:id"`
+ Name string `json:"name" gorm:"column:name"`
+ FrequencyType string `json:"frequencyType" gorm:"column:frequency_type"`
+ NextDueDate *time.Time `json:"nextDueDate" gorm:"column:next_due_date"`
+ AssignedTo int `json:"assignedTo" gorm:"column:assigned_to"`
+ LastCompletedDate *time.Time `json:"lastCompletedDate" gorm:"column:last_completed_date"`
+ LastCompletedBy *int `json:"lastCompletedBy" gorm:"column:last_completed_by"`
+ TotalCompletedCount int `json:"totalCompletedCount" gorm:"column:total_completed"`
+ CreatedBy int `json:"createdBy" gorm:"column:created_by"`
+}