Switch user operations to string type
This commit is contained in:
parent
7fc04591ba
commit
6074dcd419
173
types/others.go
173
types/others.go
@ -1,97 +1,90 @@
|
|||||||
package types
|
package types
|
||||||
|
|
||||||
/*type SiteMetadata struct {
|
type UserOperation string
|
||||||
Title Optional[string] `json:"title" url:"title,omitempty"`
|
|
||||||
Description Optional[string] `json:"description" url:"description,omitempty"`
|
|
||||||
Image Optional[string] `json:"image" url:"image,omitempty"`
|
|
||||||
HTML Optional[string] `json:"html" url:"html,omitempty"`
|
|
||||||
}*/
|
|
||||||
|
|
||||||
type UserOperation int
|
|
||||||
|
|
||||||
const (
|
const (
|
||||||
LoginOp UserOperation = iota
|
UserOpLogin UserOperation = "Login"
|
||||||
RegisterOp
|
UserOpRegister UserOperation = "Register"
|
||||||
GetCaptchaOp
|
UserOpGetCaptcha UserOperation = "GetCaptcha"
|
||||||
CreateCommunityOp
|
UserOpCreateCommunity UserOperation = "CreateCommunity"
|
||||||
CreatePostOp
|
UserOpCreatePost UserOperation = "CreatePost"
|
||||||
ListCommunitiesOp
|
UserOpListCommunities UserOperation = "ListCommunities"
|
||||||
GetPostOp
|
UserOpGetPost UserOperation = "GetPost"
|
||||||
GetCommunityOp
|
UserOpGetCommunity UserOperation = "GetCommunity"
|
||||||
CreateCommentOp
|
UserOpCreateComment UserOperation = "CreateComment"
|
||||||
EditCommentOp
|
UserOpEditComment UserOperation = "EditComment"
|
||||||
DeleteCommentOp
|
UserOpDeleteComment UserOperation = "DeleteComment"
|
||||||
RemoveCommentOp
|
UserOpRemoveComment UserOperation = "RemoveComment"
|
||||||
SaveCommentOp
|
UserOpSaveComment UserOperation = "SaveComment"
|
||||||
CreateCommentLikeOp
|
UserOpCreateCommentLike UserOperation = "CreateCommentLike"
|
||||||
GetPostsOp
|
UserOpGetPosts UserOperation = "GetPosts"
|
||||||
CreatePostLikeOp
|
UserOpCreatePostLike UserOperation = "CreatePostLike"
|
||||||
EditPostOp
|
UserOpEditPost UserOperation = "EditPost"
|
||||||
DeletePostOp
|
UserOpDeletePost UserOperation = "DeletePost"
|
||||||
RemovePostOp
|
UserOpRemovePost UserOperation = "RemovePost"
|
||||||
LockPostOp
|
UserOpLockPost UserOperation = "LockPost"
|
||||||
StickyPostOp
|
UserOpFeaturePost UserOperation = "FeaturePost"
|
||||||
MarkPostAsReadOp
|
UserOpMarkPostAsRead UserOperation = "MarkPostAsRead"
|
||||||
SavePostOp
|
UserOpSavePost UserOperation = "SavePost"
|
||||||
EditCommunityOp
|
UserOpEditCommunity UserOperation = "EditCommunity"
|
||||||
DeleteCommunityOp
|
UserOpDeleteCommunity UserOperation = "DeleteCommunity"
|
||||||
RemoveCommunityOp
|
UserOpRemoveCommunity UserOperation = "RemoveCommunity"
|
||||||
FollowCommunityOp
|
UserOpFollowCommunity UserOperation = "FollowCommunity"
|
||||||
GetPersonDetailsOp
|
UserOpGetPersonDetails UserOperation = "GetPersonDetails"
|
||||||
GetRepliesOp
|
UserOpGetReplies UserOperation = "GetReplies"
|
||||||
GetPersonMentionsOp
|
UserOpGetPersonMentions UserOperation = "GetPersonMentions"
|
||||||
MarkPersonMentionAsReadOp
|
UserOpMarkPersonMentionAsRead UserOperation = "MarkPersonMentionAsRead"
|
||||||
MarkCommentReplyAsReadOp
|
UserOpMarkCommentReplyAsRead UserOperation = "MarkCommentReplyAsRead"
|
||||||
GetModlogOp
|
UserOpGetModlog UserOperation = "GetModlog"
|
||||||
BanFromCommunityOp
|
UserOpBanFromCommunity UserOperation = "BanFromCommunity"
|
||||||
AddModToCommunityOp
|
UserOpAddModToCommunity UserOperation = "AddModToCommunity"
|
||||||
CreateSiteOp
|
UserOpCreateSite UserOperation = "CreateSite"
|
||||||
EditSiteOp
|
UserOpEditSite UserOperation = "EditSite"
|
||||||
GetSiteOp
|
UserOpGetSite UserOperation = "GetSite"
|
||||||
AddAdminOp
|
UserOpAddAdmin UserOperation = "AddAdmin"
|
||||||
GetUnreadRegistrationApplicationCountOp
|
UserOpGetUnreadRegistrationApplicationCount UserOperation = "GetUnreadRegistrationApplicationCount"
|
||||||
ListRegistrationApplicationsOp
|
UserOpListRegistrationApplications UserOperation = "ListRegistrationApplications"
|
||||||
ApproveRegistrationApplicationOp
|
UserOpApproveRegistrationApplication UserOperation = "ApproveRegistrationApplication"
|
||||||
BanPersonOp
|
UserOpBanPerson UserOperation = "BanPerson"
|
||||||
GetBannedPersonsOp
|
UserOpGetBannedPersons UserOperation = "GetBannedPersons"
|
||||||
SearchOp
|
UserOpSearch UserOperation = "Search"
|
||||||
ResolveObjectOp
|
UserOpResolveObject UserOperation = "ResolveObject"
|
||||||
MarkAllAsReadOp
|
UserOpMarkAllAsRead UserOperation = "MarkAllAsRead"
|
||||||
SaveUserSettingsOp
|
UserOpSaveUserSettings UserOperation = "SaveUserSettings"
|
||||||
TransferCommunityOp
|
UserOpTransferCommunity UserOperation = "TransferCommunity"
|
||||||
LeaveAdminOp
|
UserOpLeaveAdmin UserOperation = "LeaveAdmin"
|
||||||
DeleteAccountOp
|
UserOpDeleteAccount UserOperation = "DeleteAccount"
|
||||||
PasswordResetOp
|
UserOpPasswordReset UserOperation = "PasswordReset"
|
||||||
PasswordChangeOp
|
UserOpPasswordChange UserOperation = "PasswordChange"
|
||||||
CreatePrivateMessageOp
|
UserOpCreatePrivateMessage UserOperation = "CreatePrivateMessage"
|
||||||
EditPrivateMessageOp
|
UserOpEditPrivateMessage UserOperation = "EditPrivateMessage"
|
||||||
DeletePrivateMessageOp
|
UserOpDeletePrivateMessage UserOperation = "DeletePrivateMessage"
|
||||||
MarkPrivateMessageAsReadOp
|
UserOpMarkPrivateMessageAsRead UserOperation = "MarkPrivateMessageAsRead"
|
||||||
CreatePrivateMessageReportOp
|
UserOpCreatePrivateMessageReport UserOperation = "CreatePrivateMessageReport"
|
||||||
ResolvePrivateMessageReportOp
|
UserOpResolvePrivateMessageReport UserOperation = "ResolvePrivateMessageReport"
|
||||||
ListPrivateMessageReportsOp
|
UserOpListPrivateMessageReports UserOperation = "ListPrivateMessageReports"
|
||||||
GetPrivateMessagesOp
|
UserOpGetPrivateMessages UserOperation = "GetPrivateMessages"
|
||||||
UserJoinOp
|
UserOpUserJoin UserOperation = "UserJoin"
|
||||||
GetCommentsOp
|
UserOpGetComments UserOperation = "GetComments"
|
||||||
PostJoinOp
|
UserOpPostJoin UserOperation = "PostJoin"
|
||||||
CommunityJoinOp
|
UserOpCommunityJoin UserOperation = "CommunityJoin"
|
||||||
ChangePasswordOp
|
UserOpChangePassword UserOperation = "ChangePassword"
|
||||||
GetSiteMetadataOp
|
UserOpGetSiteMetadata UserOperation = "GetSiteMetadata"
|
||||||
BlockCommunityOp
|
UserOpBlockCommunity UserOperation = "BlockCommunity"
|
||||||
BlockPersonOp
|
UserOpBlockPerson UserOperation = "BlockPerson"
|
||||||
PurgePersonOp
|
UserOpPurgePerson UserOperation = "PurgePerson"
|
||||||
PurgeCommunityOp
|
UserOpPurgeCommunity UserOperation = "PurgeCommunity"
|
||||||
PurgePostOp
|
UserOpPurgePost UserOperation = "PurgePost"
|
||||||
PurgeCommentOp
|
UserOpPurgeComment UserOperation = "PurgeComment"
|
||||||
CreateCommentReportOp
|
UserOpCreateCommentReport UserOperation = "CreateCommentReport"
|
||||||
ResolveCommentReportOp
|
UserOpResolveCommentReport UserOperation = "ResolveCommentReport"
|
||||||
ListCommentReportsOp
|
UserOpListCommentReports UserOperation = "ListCommentReports"
|
||||||
CreatePostReportOp
|
UserOpCreatePostReport UserOperation = "CreatePostReport"
|
||||||
ResolvePostReportOp
|
UserOpResolvePostReport UserOperation = "ResolvePostReport"
|
||||||
ListPostReportsOp
|
UserOpListPostReports UserOperation = "ListPostReports"
|
||||||
GetReportCountOp
|
UserOpGetReportCount UserOperation = "GetReportCount"
|
||||||
GetUnreadCountOp
|
UserOpGetUnreadCount UserOperation = "GetUnreadCount"
|
||||||
VerifyEmailOp
|
UserOpVerifyEmail UserOperation = "VerifyEmail"
|
||||||
)
|
)
|
||||||
|
|
||||||
type SortType string
|
type SortType string
|
||||||
|
Loading…
Reference in New Issue
Block a user