private string GetMeTxt(MeritRecord record) { string txt = ""; if (record.MeritA.HasValue && record.MeritA.Value > 0) { txt += "大功:" + record.MeritA.Value.ToString() + " "; } if (record.MeritB.HasValue && record.MeritB.Value > 0) { txt += "小功:" + record.MeritB.Value.ToString() + " "; } if (record.MeritC.HasValue && record.MeritC.Value > 0) { txt += "嘉獎:" + record.MeritC.Value.ToString() + " "; } return(txt); }
private int MeritSort(MeritRecord x, MeritRecord y) { return(x.OccurDate.CompareTo(y.OccurDate)); }