Show / Hide Table of Contents

Class Poll

Inheritance
object
Poll
Implements
IMultiTenant
Namespace: Volo.CmsKit.Polls
Assembly: Volo.CmsKit.Pro.Domain.dll
Syntax
public class Poll : FullAuditedAggregateRoot<Guid>, IMultiTenant

Constructors

Poll()

Declaration
protected Poll()

Poll(Guid, string, string, string, string, DateTime, bool, bool, bool, bool, DateTime?, DateTime?, Guid?)

Declaration
public Poll(Guid id, string question, string code, string widget, string name, DateTime startDate, bool allowMultipleVote = false, bool showVoteCount = true, bool showResultWithoutGivingVote = true, bool showHoursLeft = true, DateTime? endDate = null, DateTime? resultShowingEndDate = null, Guid? tenantId = null)
Parameters
Type Name Description
Guid id
string question
string code
string widget
string name
DateTime startDate
bool allowMultipleVote
bool showVoteCount
bool showResultWithoutGivingVote
bool showHoursLeft
DateTime? endDate
DateTime? resultShowingEndDate
Guid? tenantId

Properties

AllowMultipleVote

Declaration
public virtual bool AllowMultipleVote { get; protected set; }
Property Value
Type Description
bool

Code

Declaration
public virtual string Code { get; protected set; }
Property Value
Type Description
string

EndDate

Declaration
public virtual DateTime? EndDate { get; protected set; }
Property Value
Type Description
DateTime?

Name

Declaration
public virtual string Name { get; set; }
Property Value
Type Description
string

PollOptions

Declaration
public virtual Collection<PollOption> PollOptions { get; protected set; }
Property Value
Type Description
Collection<PollOption>

Question

Declaration
public virtual string Question { get; protected set; }
Property Value
Type Description
string

ResultShowingEndDate

Declaration
public virtual DateTime? ResultShowingEndDate { get; protected set; }
Property Value
Type Description
DateTime?

ShowHoursLeft

Declaration
public virtual bool ShowHoursLeft { get; set; }
Property Value
Type Description
bool

ShowResultWithoutGivingVote

Declaration
public virtual bool ShowResultWithoutGivingVote { get; set; }
Property Value
Type Description
bool

ShowVoteCount

Declaration
public virtual bool ShowVoteCount { get; set; }
Property Value
Type Description
bool

StartDate

Declaration
public virtual DateTime StartDate { get; protected set; }
Property Value
Type Description
DateTime

TenantId

Declaration
public virtual Guid? TenantId { get; protected set; }
Property Value
Type Description
Guid?

VoteCount

Declaration
public virtual int VoteCount { get; protected set; }
Property Value
Type Description
int

Widget

Declaration
public virtual string Widget { get; set; }
Property Value
Type Description
string

Methods

AddPollOption(Guid, string, int, Guid?)

Declaration
public virtual PollOption AddPollOption(Guid optionId, string text, int order, Guid? tenantId)
Parameters
Type Name Description
Guid optionId
string text
int order
Guid? tenantId
Returns
Type Description
PollOption

Decrease(int)

Declaration
public virtual void Decrease(int voteCount)
Parameters
Type Name Description
int voteCount

Increase()

Declaration
public virtual void Increase()

OrderPollOptions()

Declaration
public virtual void OrderPollOptions()

RemovePollOption(Guid)

Declaration
public virtual void RemovePollOption(Guid optionId)
Parameters
Type Name Description
Guid optionId

SetCode(string)

Declaration
public virtual void SetCode(string code)
Parameters
Type Name Description
string code

SetDates(DateTime, DateTime?, DateTime?)

Declaration
public virtual void SetDates(DateTime startDate, DateTime? endDate = null, DateTime? resultShowingEndDate = null)
Parameters
Type Name Description
DateTime startDate
DateTime? endDate
DateTime? resultShowingEndDate

SetQuestion(string)

Declaration
public virtual void SetQuestion(string question)
Parameters
Type Name Description
string question

UpdatePollOption(Guid, string, int, Guid?)

Declaration
public virtual void UpdatePollOption(Guid optionId, string text, int order, Guid? tenantId)
Parameters
Type Name Description
Guid optionId
string text
int order
Guid? tenantId

Implements

Volo.Abp.MultiTenancy.IMultiTenant
In this article
Back to top Powered by Volosoft