fix: issues

This commit is contained in:
Rogee
2025-02-10 15:10:39 +08:00
parent eb13231e9e
commit 266c2c4767
8 changed files with 91 additions and 15 deletions

View File

@@ -0,0 +1,22 @@
package publishers
import (
"encoding/json"
"{{.ModuleName}}/app/events"
"{{.ModuleName}}/pkg/atom/contracts"
)
var _ contracts.EventPublisher = (*UserRegister)(nil)
type UserRegister struct {
ID int64 `json:"id"`
}
func (e *UserRegister) Marshal() ([]byte, error) {
return json.Marshal(e)
}
func (e *UserRegister) Topic() string {
return events.TopicUserRegister
}