diff options
author | Dessalines <happydooby@gmail.com> | 2019-04-03 13:59:37 -0700 |
---|---|---|
committer | Dessalines <happydooby@gmail.com> | 2019-04-03 13:59:37 -0700 |
commit | 81da0853aa460da0e277edfccfde9fcdf9334f31 (patch) | |
tree | 37f7bf5629f1a5fd01442df2bd3a35c705b40f54 /ui/src/interfaces.ts | |
parent | ba5c93c8da599c0697883b3bd1673a584660ea34 (diff) |
Adding post editing.
- Adding post editing. Fixes #23
- Making SQL versions of comment and post fetching. Fixes #21
- Starting to add forum categories. #17
Diffstat (limited to 'ui/src/interfaces.ts')
-rw-r--r-- | ui/src/interfaces.ts | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/ui/src/interfaces.ts b/ui/src/interfaces.ts index 56d860bd..e21edf77 100644 --- a/ui/src/interfaces.ts +++ b/ui/src/interfaces.ts @@ -1,5 +1,5 @@ export enum UserOperation { - Login, Register, CreateCommunity, CreatePost, ListCommunities, GetPost, GetCommunity, CreateComment, EditComment, CreateCommentLike, GetPosts, CreatePostLike + Login, Register, CreateCommunity, CreatePost, ListCommunities, GetPost, GetCommunity, CreateComment, EditComment, CreateCommentLike, GetPosts, CreatePostLike, EditPost, EditCommunity } export interface User { @@ -56,19 +56,26 @@ export interface PostForm { body?: string; community_id: number; updated?: number; + edit_id?: number; auth: string; } -export interface PostResponse { +export interface GetPostResponse { op: string; post: Post; comments: Array<Comment>; } +export interface PostResponse { + op: string; + post: Post; +} + export interface Comment { id: number; content: string; creator_id: number; + creator_name: string; post_id: number, parent_id?: number; published: string; @@ -99,11 +106,6 @@ export interface CommentLikeForm { auth?: string; } -export interface CreateCommentLikeResponse { - op: string; - comment: Comment; -} - export interface GetPostsForm { type_: string; sort: string; |