Reverted odd method removal.

This commit is contained in:
Andrei Smirnov 2021-08-31 17:27:08 +03:00 committed by Iuri Matias
parent 8ae050b642
commit 21059919b1
1 changed files with 11 additions and 0 deletions

View File

@ -118,6 +118,17 @@ QtObject:
of CommunityMembersRoles.Online: result = newQVariant(self.isOnline(communityMemberPubkey))
of CommunityMembersRoles.SortKey: result = newQVariant(self.sortKey(communityMemberPubkey))
proc rowData(self: CommunityMembersView, index: int, column: string): string {.slot.} =
if (index >= self.community.members.len):
return
let communityMemberPubkey = self.community.members[index]
case column:
of "alias": result = self.alias(communityMemberPubkey)
of "publicKey": result = communityMemberPubkey
of "identicon": result = self.identicon(communityMemberPubkey)
of "localName": result = self.localNickname(communityMemberPubkey)
of "userName": result = self.userName(communityMemberPubkey, self.alias(communityMemberPubkey))
method roleNames(self: CommunityMembersView): Table[int, string] =
{
CommunityMembersRoles.UserName.int:"userName",