Documentation ¶
Index ¶
- Variables
- type Notification
- func (*Notification) Descriptor() ([]byte, []int)deprecated
- func (x *Notification) GetCreatedAt() *timestamppb.Timestamp
- func (x *Notification) GetID() string
- func (x *Notification) GetId() string
- func (x *Notification) GetMessage() string
- func (x *Notification) GetOrderId() int64
- func (x *Notification) GetSenderId() string
- func (x *Notification) GetStatus() string
- func (x *Notification) GetType() string
- func (x *Notification) GetUpdatedAt() *timestamppb.Timestamp
- func (x *Notification) GetUserId() string
- func (x *Notification) MarshalBSON() ([]byte, error)
- func (*Notification) ProtoMessage()
- func (x *Notification) ProtoReflect() protoreflect.Message
- func (x *Notification) Reset()
- func (x *Notification) SetCreatedAt(t *timestamppb.Timestamp)
- func (x *Notification) SetID(id primitive.ObjectID)
- func (x *Notification) SetUpdatedAt(t *timestamppb.Timestamp)
- func (x *Notification) String() string
- func (x *Notification) UnmarshalBSON(bytes []byte) error
Constants ¶
This section is empty.
Variables ¶
View Source
var File_domain_notification_model_notification_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type Notification ¶
type Notification struct { // ID is the unique identifier of the notification. // @gotags: bson:"_id,omitempty" Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty" bson:"_id,omitempty"` // SenderID is the identifier of the user who sent the notification. // @gotags: bson:"sender_id" SenderId string `protobuf:"bytes,2,opt,name=sender_id,json=senderId,proto3" json:"sender_id,omitempty" bson:"sender_id"` // UserID is the identifier of the user to whom the notification is sent. // @gotags: bson:"user_id" UserId string `protobuf:"bytes,3,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty" bson:"user_id"` // OrderID is the identifier of the order associated with the notification. // @gotags: bson:"order_id" OrderId int64 `protobuf:"varint,4,opt,name=order_id,json=orderId,proto3" json:"order_id,omitempty" bson:"order_id"` // Type represents the type of notification (e.g., order_status, delivery_status). // @gotags: bson:"type" Type string `protobuf:"bytes,5,opt,name=type,proto3" json:"type,omitempty" bson:"type"` // Message is the content of the notification. // @gotags: bson:"message" Message string `protobuf:"bytes,6,opt,name=message,proto3" json:"message,omitempty" bson:"message"` // Status is the current status of the notification (e.g., pending, sent). // @gotags: bson:"status" Status string `protobuf:"bytes,7,opt,name=status,proto3" json:"status,omitempty" bson:"status"` // CreatedAt is the timestamp when the notification was created. // @gotags: bson:"created_at" CreatedAt *timestamppb.Timestamp `protobuf:"bytes,8,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty" bson:"created_at"` // UpdatedAt is the timestamp when the notification was last updated. // @gotags: bson:"updated_at" UpdatedAt *timestamppb.Timestamp `protobuf:"bytes,9,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty" bson:"updated_at"` // contains filtered or unexported fields }
Notification is an entity that represents a notification.
func NewNotification ¶
func NewNotification(from, to string, orderID int64, message string) *Notification
NewNotification creates a new notification entity.
func (*Notification) Descriptor
deprecated
func (*Notification) Descriptor() ([]byte, []int)
Deprecated: Use Notification.ProtoReflect.Descriptor instead.
func (*Notification) GetCreatedAt ¶
func (x *Notification) GetCreatedAt() *timestamppb.Timestamp
func (*Notification) GetID ¶
func (x *Notification) GetID() string
func (*Notification) GetId ¶
func (x *Notification) GetId() string
func (*Notification) GetMessage ¶
func (x *Notification) GetMessage() string
func (*Notification) GetOrderId ¶
func (x *Notification) GetOrderId() int64
func (*Notification) GetSenderId ¶
func (x *Notification) GetSenderId() string
func (*Notification) GetStatus ¶
func (x *Notification) GetStatus() string
func (*Notification) GetType ¶
func (x *Notification) GetType() string
func (*Notification) GetUpdatedAt ¶
func (x *Notification) GetUpdatedAt() *timestamppb.Timestamp
func (*Notification) GetUserId ¶
func (x *Notification) GetUserId() string
func (*Notification) MarshalBSON ¶
func (x *Notification) MarshalBSON() ([]byte, error)
func (*Notification) ProtoMessage ¶
func (*Notification) ProtoMessage()
func (*Notification) ProtoReflect ¶
func (x *Notification) ProtoReflect() protoreflect.Message
func (*Notification) Reset ¶
func (x *Notification) Reset()
func (*Notification) SetCreatedAt ¶
func (x *Notification) SetCreatedAt(t *timestamppb.Timestamp)
func (*Notification) SetID ¶
func (x *Notification) SetID(id primitive.ObjectID)
func (*Notification) SetUpdatedAt ¶
func (x *Notification) SetUpdatedAt(t *timestamppb.Timestamp)
func (*Notification) String ¶
func (x *Notification) String() string
func (*Notification) UnmarshalBSON ¶
func (x *Notification) UnmarshalBSON(bytes []byte) error
Click to show internal directories.
Click to hide internal directories.