diff options
author | Matias Linares <matias@deprecated.org> | 2024-10-21 09:57:10 -0300 |
---|---|---|
committer | Matias Linares <matias.linares@comprandoengrupo.net> | 2024-10-29 18:11:18 -0300 |
commit | a88655cd202dc43a64a7107f6f533bd386079386 (patch) | |
tree | ae6038d67657aa5bf1c18f2e2d1e6dc0bb1558ac /kodereviewer/models/comments.py | |
parent | d349e5014fc60a8ae140a56c457c3f3258959582 (diff) | |
download | kodereviewer-a88655cd202dc43a64a7107f6f533bd386079386.tar.gz |
Add reviews view :D
Diffstat (limited to 'kodereviewer/models/comments.py')
-rw-r--r-- | kodereviewer/models/comments.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/kodereviewer/models/comments.py b/kodereviewer/models/comments.py index 0d92e23..bc7eee0 100644 --- a/kodereviewer/models/comments.py +++ b/kodereviewer/models/comments.py @@ -60,17 +60,17 @@ class CommentModel(QAbstractListModel): comment: Comment = self._pull_request._comments[index.row()] if role == self.Roles.Body: - return comment.body + return comment._body if role == self.Roles.CreatedAt: - return comment.created_at.strftime("%Y-%M-%d %H:%m") + return comment._created_at.strftime("%Y-%M-%d %H:%m") if role == self.Roles.UpdatedAt: - return comment.updated_at.strftime("%Y-%M-%d %H:%m") + return comment._updated_at.strftime("%Y-%M-%d %H:%m") if role == self.Roles.Username: - return comment.user.username + return comment._user._username if role == self.Roles.AvatarUrl: - return comment.user.avatar_url + return comment._user._avatar_url if role == Qt.ItemDataRole.DisplayRole: - return comment.body + return comment._body return None def rowCount(self, parent: QModelIndex | QPersistentModelIndex = QModelIndex()) -> int: |