Documentation ¶
Index ¶
- type RevisionService
- func (rs *RevisionService) AddRevision(ctx context.Context, req *schema.AddRevisionDTO, autoUpdateRevisionID bool) (revisionID string, err error)
- func (rs *RevisionService) ExistUnreviewedByObjectID(ctx context.Context, objectID string) (revision *entity.Revision, exist bool, err error)
- func (rs *RevisionService) GetRevision(ctx context.Context, revisionID string) (revision *entity.Revision, err error)
- func (rs *RevisionService) GetUnreviewedRevisionCount(ctx context.Context, req *schema.RevisionSearch) (count int64, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RevisionService ¶
type RevisionService struct {
// contains filtered or unexported fields
}
RevisionService user service
func NewRevisionService ¶
func NewRevisionService(revisionRepo revision.RevisionRepo, userRepo usercommon.UserRepo, ) *RevisionService
func (*RevisionService) AddRevision ¶
func (rs *RevisionService) AddRevision(ctx context.Context, req *schema.AddRevisionDTO, autoUpdateRevisionID bool) ( revisionID string, err error)
AddRevision add revision
autoUpdateRevisionID bool : if autoUpdateRevisionID is true , the object.revision_id will be updated, if not need auto update object.revision_id, it must be false. example: user can edit the object, but need audit, the revision_id will be updated when admin approved
func (*RevisionService) ExistUnreviewedByObjectID ¶ added in v0.5.0
func (rs *RevisionService) ExistUnreviewedByObjectID(ctx context.Context, objectID string) (revision *entity.Revision, exist bool, err error)
ExistUnreviewedByObjectID
func (*RevisionService) GetRevision ¶ added in v0.5.0
func (rs *RevisionService) GetRevision(ctx context.Context, revisionID string) ( revision *entity.Revision, err error)
GetRevision get revision
func (*RevisionService) GetUnreviewedRevisionCount ¶ added in v0.5.0
func (rs *RevisionService) GetUnreviewedRevisionCount(ctx context.Context, req *schema.RevisionSearch) (count int64, err error)
Click to show internal directories.
Click to hide internal directories.