2 aggregates::structs::{CommentAggregates, CommunityAggregates, PersonAggregates},
5 community::CommunitySafe,
6 person::{PersonSafe, PersonSafeAlias1},
7 person_mention::PersonMention,
12 use serde::{Deserialize, Serialize};
14 #[derive(Debug, Serialize, Deserialize, Clone)]
15 pub struct CommunityBlockView {
16 pub person: PersonSafe,
17 pub community: CommunitySafe,
20 #[derive(Debug, Serialize, Deserialize, Clone)]
21 pub struct CommunityFollowerView {
22 pub community: CommunitySafe,
23 pub follower: PersonSafe,
26 #[derive(Debug, Serialize, Deserialize, Clone)]
27 pub struct CommunityModeratorView {
28 pub community: CommunitySafe,
29 pub moderator: PersonSafe,
32 #[derive(Debug, Serialize, Deserialize, Clone)]
33 pub struct CommunityPersonBanView {
34 pub community: CommunitySafe,
35 pub person: PersonSafe,
38 #[derive(Debug, Serialize, Deserialize, Clone)]
39 pub struct CommunityView {
40 pub community: CommunitySafe,
41 pub subscribed: SubscribedType,
43 pub counts: CommunityAggregates,
46 #[derive(Debug, Serialize, Deserialize, Clone)]
47 pub struct PersonBlockView {
48 pub person: PersonSafe,
49 pub target: PersonSafeAlias1,
52 #[derive(Debug, PartialEq, Serialize, Deserialize, Clone)]
53 pub struct PersonMentionView {
54 pub person_mention: PersonMention,
56 pub creator: PersonSafe,
58 pub community: CommunitySafe,
59 pub recipient: PersonSafeAlias1,
60 pub counts: CommentAggregates,
61 pub creator_banned_from_community: bool, // Left Join to CommunityPersonBan
62 pub subscribed: SubscribedType, // Left join to CommunityFollower
63 pub saved: bool, // Left join to CommentSaved
64 pub creator_blocked: bool, // Left join to PersonBlock
65 pub my_vote: Option<i16>, // Left join to CommentLike
68 #[derive(Debug, Serialize, Deserialize, Clone)]
69 pub struct PersonViewSafe {
70 pub person: PersonSafe,
71 pub counts: PersonAggregates,