Skip to content

Commit

Permalink
Unread comments
Browse files Browse the repository at this point in the history
  • Loading branch information
folix-01 committed Jul 29, 2024
1 parent 4e0d5fe commit 8ca28cc
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/collective/feedback/restapi/services/get.py
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,11 @@ def get_data(self):
data["vote_num"] += 1
data["vote_sum"] += vote

# Sign if page has unread comments
data["has_unread"] = data.get("has_unread", False) or feedback._attrs.get(
"read", False
)

# number of comment
comment = feedback._attrs.get("comment", "")
answer = feedback._attrs.get("answer", "")
Expand Down

0 comments on commit 8ca28cc

Please sign in to comment.