public bool IsSmallGroupFilled(IEnumerable <string> smallgroups) { if (!(Limit > 0)) { return(false); } var cnt = smallgroups.Count(mm => mm.trim() == SmallGroup.trim()); return(cnt >= Limit); }
public void WriteXml(APIWriter w) { w.Start("CheckboxItem") .Attr("Fee", Fee) .Attr("Limit", Limit) .Attr("Time", MeetingTime.ToString2("s")) .Add("Description", Description) .Add("SmallGroup", SmallGroup.trim()) .End(); }
public void AddToSmallGroup(CMSDataContext Db, OrganizationMember om, PythonModel pe) { if (om == null) { return; } if (pe != null) { pe.instance.AddToSmallGroup(SmallGroup.trim(), om); om.Person.LogChanges(Db, om.PeopleId); } om.AddToGroup(Db, SmallGroup.trim()); if (MeetingTime.HasValue) { Attend.MarkRegistered(Db, om.OrganizationId, om.PeopleId, MeetingTime.Value, 1); } }
public void RemoveFromSmallGroup(CMSDataContext Db, OrganizationMember om) { om.RemoveFromGroup(Db, SmallGroup.trim()); }