using System; using System.Collections.Generic; using System.ComponentModel.DataAnnotations; using TEAMModelOS.SDK.Context.Attributes.Azure; using TEAMModelOS.SDK.DI; namespace TEAMModelFunction { /// /// 投票 /// //[CosmosDB(Database = "TEAMModelOS", Name = "School")] public class Vote : ID { [PartitionKey] [Required(ErrorMessage = "{0} 必须填写")] public string code { get; set; } public string pk { get; set; } public Vote() { options = new List(); } public string id { get; set; } /// /// 投票名称 /// public string name { get; set; } public string school { get; set; } public string creatorId { get; set; } public int year { get; set; } public string progress { get; set; } public List options { get; set; } public bool secret { get; set; } public int selectMax { get; set; } public int stuCount { get; set; } public string scope { get; set; } public List targetClassIds { get; set; } /// /// 发布模式 0 立即发布 1 定时 /// public string publishModel { get; set; } /// /// 开始时间 /// public long startTime { get; set; } public long createTime { get; set; } /// /// 结束时间 /// public long endTime { get; set; } /// /// 投票描述 /// public string description { get; set; } /* /// /// 投票附件 /// [ProtoMember(9)] public List resource { get; set; } */ /// /// 状态 (100:待发布 200:已发布 300:已结束) /// public int status { get; set; } /* /// /// 模式 /// [ProtoMember(11)] public List other { get; set; }*/ /* public string url { get; set; } /// /// 选项 /// [ProtoMember(12)] public List