Example #1
0
        public IEnumerable <PresentationLayer.Model.Personel> ScoreBoard()
        {
            List <PresentationLayer.Model.Personel> scoreList = new List <PresentationLayer.Model.Personel>();
            DataAccess da = new DataAccess();

            foreach (var item in da.ScoreBoard())
            {
                PresentationLayer.Model.Personel temp = new Model.Personel();
                temp.PersonelID   = item.PersonelID;
                temp.PersonelName = item.PersonelName;
                temp.SolvedCount  = item.SolvedCount;
                scoreList.Add(temp);
            }
            return(scoreList);
        }
Example #2
0
        public IEnumerable <PresentationLayer.Model.Personel> GetAllPersonels()
        {
            List <PresentationLayer.Model.Personel> personelList = new List <PresentationLayer.Model.Personel>();
            var da = new DataAccess();

            foreach (var item in da.GetPersonels())
            {
                PresentationLayer.Model.Personel temp = new Model.Personel();
                temp.PersonelID   = item.PersonelID;
                temp.Password     = item.Password;
                temp.PersonelName = item.PersonelName;
                temp.SolvedCount  = item.SolvedCount;
                personelList.Add(temp);
            }
            return(personelList);
        }