mirror of
https://gitlab.com/comunic/comunicmobile
synced 2025-09-20 06:18:51 +00:00
Ready to build presence section
This commit is contained in:
@@ -17,6 +17,7 @@ class AdvancedGroupInfo extends Group implements LikeElement {
|
||||
int likes;
|
||||
bool userLike;
|
||||
List<Conversation> conversations;
|
||||
bool isForezGroup;
|
||||
|
||||
AdvancedGroupInfo({
|
||||
@required int id,
|
||||
@@ -36,7 +37,9 @@ class AdvancedGroupInfo extends Group implements LikeElement {
|
||||
@required this.likes,
|
||||
@required this.userLike,
|
||||
@required this.conversations,
|
||||
}) : super(
|
||||
@required this.isForezGroup,
|
||||
}) : assert(isForezGroup != null),
|
||||
super(
|
||||
id: id,
|
||||
name: name,
|
||||
iconURL: iconURL,
|
||||
|
@@ -19,7 +19,7 @@ enum GroupRegistrationLevel { OPEN, MODERATED, CLOSED }
|
||||
|
||||
enum GroupPostCreationLevel { MODERATORS, MEMBERS }
|
||||
|
||||
class Group {
|
||||
class Group implements Comparable<Group> {
|
||||
final int id;
|
||||
String name;
|
||||
final String iconURL;
|
||||
@@ -70,4 +70,7 @@ class Group {
|
||||
membershipLevel == GroupMembershipLevel.MODERATOR ||
|
||||
(membershipLevel == GroupMembershipLevel.MEMBER &&
|
||||
postCreationLevel == GroupPostCreationLevel.MEMBERS);
|
||||
|
||||
@override
|
||||
int compareTo(Group other) => id.compareTo(other.id);
|
||||
}
|
||||
|
Reference in New Issue
Block a user