sep24migrations.ViewModels.Repo_Subject.GetList C# (CSharp) Method

GetList() public method

Get all, for a lookup list
public GetList ( ) : IEnumerable
return IEnumerable
        public IEnumerable<SubjectList> GetList()
        {
            var subjects = ds.Subjects.OrderBy(o => o.Code);
            // There's probably a better way to sort these
            // Maybe by semester (the first digit, or digits), then alpha code

            return Mapper.Map<IEnumerable<SubjectList>>(subjects);
        }