diff --git a/action_create.go b/action_create.go index e7854d6..d8440ec 100644 --- a/action_create.go +++ b/action_create.go @@ -13,6 +13,7 @@ type CreatePayload struct { TargetID string Action string Data string + Message string Author CreatePayloadAuthor } @@ -38,6 +39,7 @@ func (s Service) Create(payload CreatePayload) { Name: payload.Author.Name, }, CreatedAt: now(), + Message: payload.Message, } // Insert to db diff --git a/db_model.go b/db_model.go index e0aaecf..139905e 100644 --- a/db_model.go +++ b/db_model.go @@ -15,6 +15,7 @@ type Audit struct { Data string `bson:"data" json:"data"` Author Author `bson:"author" json:"author"` CreatedAt time.Time `bson:"createdAt" json:"createdAt"` + Message string `bson:"message" json:"message"` } // Author ...