@@ -8,10 +8,12 @@ defmodule GroupherServer.CMS do
8
8
alias GroupherServer.CMS.Delegate
9
9
10
10
alias Delegate . {
11
+ AbuseReport ,
11
12
ArticleCURD ,
12
13
ArticleOperation ,
13
14
ArticleReaction ,
14
15
FavoritedContents ,
16
+ ArticleComment ,
15
17
CommentCURD ,
16
18
CommunitySync ,
17
19
CommentReaction ,
@@ -106,22 +108,44 @@ defmodule GroupherServer.CMS do
106
108
defdelegate unset_community ( community , thread , content_id ) , to: ArticleOperation
107
109
108
110
# Comment CURD
111
+ defdelegate list_article_comments ( thread , article_id , filters ) , to: ArticleComment
112
+ defdelegate list_article_comments ( thread , article_id , filters , user ) , to: ArticleComment
113
+ defdelegate list_folded_article_comments ( thread , article_id , filters ) , to: ArticleComment
114
+ defdelegate list_folded_article_comments ( thread , article_id , filters , user ) , to: ArticleComment
115
+ defdelegate list_reported_article_comments ( thread , article_id , filters ) , to: ArticleComment
116
+
117
+ defdelegate list_reported_article_comments ( thread , article_id , filters , user ) ,
118
+ to: ArticleComment
119
+
120
+ defdelegate list_comment_replies ( comment_id , filters ) , to: ArticleComment
121
+
109
122
defdelegate list_comments ( thread , content_id , filters ) , to: CommentCURD
110
123
defdelegate list_comments_participators ( thread , content_id , filters ) , to: CommentCURD
111
124
125
+ defdelegate create_article_comment ( thread , article_id , args , user ) , to: ArticleComment
126
+ defdelegate upvote_article_comment ( comment_id , user ) , to: ArticleComment
127
+ defdelegate delete_article_comment ( comment_id , user ) , to: ArticleComment
128
+ defdelegate reply_article_comment ( comment_id , args , user ) , to: ArticleComment
129
+
130
+ defdelegate make_emotion ( comment_id , args , user ) , to: ArticleComment
131
+ defdelegate fold_article_comment ( comment_id , user ) , to: ArticleComment
132
+ defdelegate unfold_article_comment ( comment_id , user ) , to: ArticleComment
133
+ defdelegate report_article_comment ( comment_id , user ) , to: ArticleComment
134
+ defdelegate unreport_article_comment ( comment_id , user ) , to: ArticleComment
135
+
112
136
defdelegate create_comment ( thread , content_id , args , user ) , to: CommentCURD
113
137
defdelegate update_comment ( thread , id , args , user ) , to: CommentCURD
114
138
defdelegate delete_comment ( thread , content_id ) , to: CommentCURD
115
139
defdelegate list_replies ( thread , comment , user ) , to: CommentCURD
116
140
defdelegate reply_comment ( thread , comment , args , user ) , to: CommentCURD
117
141
142
+ # report
143
+ defdelegate create_report ( type , content_id , args , user ) , to: AbuseReport
144
+
118
145
# Comment Reaction
119
146
# >> like / undo like
120
147
defdelegate like_comment ( thread , comment , user ) , to: CommentReaction
121
148
defdelegate undo_like_comment ( thread , comment , user ) , to: CommentReaction
122
- # >> dislike / undo dislike
123
- defdelegate dislike_comment ( thread , comment , user ) , to: CommentReaction
124
- defdelegate undo_dislike_comment ( thread , comment , user ) , to: CommentReaction
125
149
126
150
# Passport CURD
127
151
defdelegate stamp_passport ( rules , user ) , to: PassportCURD
0 commit comments