Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add notice about running votes for public access users #4485

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,12 @@
}
· 
</span>
<span>
{{ poll.stateVerbose | translate }}
<span class="break-word">
@if (isAnonymous && poll.canBeVotedFor()) {
{{ 'Voting in progress' | translate }}
} @else {
{{ poll.stateVerbose | translate }}
}
</span>
</div>
<!-- Menu -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,10 @@ export class AssignmentPollComponent extends BasePollComponent implements OnInit
return (!this.poll.stateHasVotes && !this.votingService.canVote(this.poll)) || this.poll.isListPoll;
}

public get isAnonymous(): boolean {
return this.operator.isAnonymousLoggedIn;
}

public constructor(
protected override translate: TranslateService,
private formBuilder: UntypedFormBuilder,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,12 @@
</p>

@if (poll.canBeVotedFor()) {
<os-poll-progress [poll]="poll"></os-poll-progress>
<div class="type-and-state italic spacer-bottom-20 break-word">
<!-- State -->
<i>
{{ 'Voting in progress' | translate }}
</i>
</div>
}
@if (poll.isMotionPoll) {
<div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,11 @@
</span>
<!-- State -->
<span class="break-word">
{{ poll.stateVerbose | translate }}
@if (isAnonymous && poll.canBeVotedFor()) {
{{ 'Voting in progress' | translate }}
} @else {
{{ poll.stateVerbose | translate }}
}
</span>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@ export class MotionPollComponent extends BasePollComponent {
return false;
}

public get isAnonymous(): boolean {
return this.operator.isAnonymousLoggedIn;
}

public get canSeeVotes(): boolean {
const option = this.poll.options[0];
return (
Expand Down
Loading