1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192 |
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using EMIS.DataLogic.Repositories;
- using EMIS.ViewModel;
- namespace EMIS.DataLogic.ScoreManage
- {
- public class ExamsStateSettingDAL
- {
- public ExamsStateSettingRepository ExamsStateSettingRepository { get; set; }
- public DictionaryItemRepository DictionaryItemRepository { get; set; }
- public int? GetExaminationSuspensionID()
- {
- var examinationSuspensionID = ExamsStateSettingRepository
- .GetList(x => x.IsSuspension == true)
- .Select(x => x.ExamsStateID)
- .FirstOrDefault();
- return examinationSuspensionID;
- }
- public int? GetNormalID()
- {
- var normalID = ExamsStateSettingRepository
- .GetList(x => x.IsNormal == true)
- .Select(x => x.ExamsStateID)
- .FirstOrDefault();
- return normalID;
- }
- public int? GetExaminationExemptionID()
- {
- var examinationExemptionID = ExamsStateSettingRepository
- .GetList(x => x.IsExemption == true)
- .Select(x => x.ExamsStateID)
- .FirstOrDefault();
- return examinationExemptionID;
- }
- //public decimal? GetExemptionScore()
- //{
- // var Score = ExamsStateSettingRepository
- // .GetList(x => x.IsExemption == true)
- // .Select(x => x.Score)
- // .FirstOrDefault();
- // return Score;
- //}
- public List<int?> GetMisconductIDList()
- {
- var q = ExamsStateSettingRepository
- .GetList(x => x.IsMisconduct == true)
- .Select(x => x.ExamsStateID)
- .ToList();
- return q.ToList();
- }
- public List<int?> GetResitIDList()
- {
- var q = ExamsStateSettingRepository
- .GetList(x => x.CanResit == true)
- .Select(x => x.ExamsStateID)
- .ToList();
- return q.ToList();
- }
- public int? GetSuspensionResitCategory()
- {
- var q = ExamsStateSettingRepository
- .GetList(x => x.ExamsStateID == (int)CF_ExamsState.Suspension)
- .Select(x => x.ResitCategory);
- return q.FirstOrDefault();
- }
- public List<int?> GetCanGraduateList()
- {
- var q = ExamsStateSettingRepository
- .GetList(x => x.CanGraduateResit == true)
- .Select(x => x.ExamsStateID)
- .ToList();
- return q.ToList();
- }
- }
- }
|