mirror of
https://gitlab.com/comunic/comunicmobile
synced 2025-06-19 08:15:16 +00:00
Do not render survey pie chart which have not response
This commit is contained in:
@ -33,6 +33,9 @@ class Survey {
|
||||
|
||||
bool get hasResponded => this.userChoice != null && this.userChoice > 0;
|
||||
|
||||
bool get hasResponses =>
|
||||
this.choices.where((f) => f.responses > 0).length > 0;
|
||||
|
||||
SurveyChoice get userResponse {
|
||||
if (!hasResponded) return null;
|
||||
|
||||
|
Reference in New Issue
Block a user