service backend
All checks were successful
ci/woodpecker/push/db Pipeline was successful
ci/woodpecker/push/nats Pipeline was successful

This commit is contained in:
Stephan D
2025-11-07 18:35:26 +01:00
parent 20e8f9acc4
commit 62a6631b9a
537 changed files with 48453 additions and 0 deletions

26
api/pkg/model/task.go Normal file
View File

@@ -0,0 +1,26 @@
package model
import (
"time"
"github.com/tech/sendico/pkg/mservice"
"go.mongodb.org/mongo-driver/bson/primitive"
)
type Task struct {
PermissionBound `bson:",inline" json:",inline"`
Describable `bson:",inline" json:",inline"`
Indexable `bson:",inline" json:",inline"`
Taggable `bson:",inline" json:",inline"`
StatusRef primitive.ObjectID `bson:"statusRef" json:"statusRef"` // Reference to the current Step
ReporterRef primitive.ObjectID `bson:"reporterRef" json:"reporterRef"` // Reference to the task reporter
AssigneeRef *primitive.ObjectID `bson:"assigneeRef,omitempty" json:"assigneeRef,omitempty"` // Reference to the user assigned
ProjectRef primitive.ObjectID `bson:"projectRef" json:"projectRef"` // Reference to the project
PriorityRef primitive.ObjectID `bson:"priorityRef" json:"priorityRef"` // Reference to dynamic priority
DueDate *time.Time `bson:"dueDate" json:"dueDate"`
Number int `bson:"number" json:"number"`
}
func (*Task) Collection() string {
return mservice.Tasks
}