123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596 |
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using EMIS.ViewModel.EducationManage;
- using EMIS.ViewModel.CacheManage;
- using EMIS.ViewModel.CalendarManage;
- namespace EMIS.ViewModel.EducationSchedule
- {
- public class MobileUserEducationScheduleView
- {
- /// <summary>
- /// 学年学期
- /// </summary>
- public Nullable<System.Guid> SchoolyearID { get; set; }
- /// <summary>
- /// 学年学期
- /// </summary>
- public string SchoolyearCode { get; set; }
- /// <summary>
- /// 课程ID
- /// </summary>
- public Guid? CoursematerialID { get; set; }
- /// <summary>
- /// 课程名称
- /// </summary>
- public string CoursematerialName { get; set; }
- /// <summary>
- /// 授课方式
- /// </summary>
- public int? TeachingModeID { get; set; }
- public string TeachingModeName
- {
- get
- {
- return IdNameExt.GetDictionaryItem(DictionaryItem.CF_TeachingMode.ToString())
- .Where(x => x.Value == TeachingModeID)
- .Select(x => x.Name).FirstOrDefault();
- }
- }
- /// <summary>
- /// 星期
- /// </summary>
- public Nullable<int> Weekday { get; set; }
- /// <summary>
- /// 课程时间
- /// </summary>
- public Nullable<int> TimeGroup { get; set; }
- /// <summary>
- /// 课程时间
- /// </summary>
- public List<BaseWorkTimeView> CoursesTimeList { get; set; }
- public string TimeGroupName
- {
- get
- {
- return "<" + CoursesTimeList.Min(x => x.StartTimes).ToString() + "-" + CoursesTimeList.Max(x => x.EndTimes).ToString() + "节>";
- }
- }
- /// <summary>
- /// 课程时间视图
- /// </summary>
- public string TimeName
- {
- get
- {
- return CoursesTimeList.Min(x => new TimeSpan(x.StartHour, x.StartMinutes, 0)).ToString(@"hh\:mm")
- + "-" + CoursesTimeList.Max(x => new TimeSpan(x.EndHour, x.EndMinutes, 0)).ToString(@"hh\:mm");
- }
- }
- /// <summary>
- /// ClassroomID
- /// </summary>
- public Nullable<System.Guid> ClassroomID { get; set; }
- public string ClassroomName { get; set; }
- ///// <summary>
- ///// 教师列表
- ///// </summary>
- //public List<BaseTeacherTeachingView> TeacherTeachingViewList { get; set; }
- //public string TeacherNames
- //{
- // get
- // {
- // return string.Join(",", TeacherTeachingViewList.Select(x => x.Name).Distinct().ToList());
- // }
- //}
- }
- }
|