Пеервод моделей кафедры, первая итерация
This commit is contained in:
parent
7b682e50d7
commit
941794b273
@ -1,9 +1,9 @@
|
|||||||
namespace DepartmentBusinessLogic.Enums
|
namespace CoreModels.Enums.Department
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Типы аудиторий
|
/// Типы аудиторий
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public enum ClassroomType
|
public enum ClassroomType
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Класс для лабораторных занятий с компьютерами
|
/// Класс для лабораторных занятий с компьютерами
|
@ -0,0 +1,12 @@
|
|||||||
|
namespace CoreModels.Enums.Department
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Уровни обучения
|
||||||
|
/// </summary>
|
||||||
|
public enum EducationDirectionQualification
|
||||||
|
{
|
||||||
|
Бакалавриат = 0,
|
||||||
|
|
||||||
|
Магистратура = 1
|
||||||
|
}
|
||||||
|
}
|
@ -1,9 +1,9 @@
|
|||||||
namespace DepartmentBusinessLogic.Enums
|
namespace CoreModels.Enums.Department
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Семестр обучения
|
/// Семестр обучения
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public enum Semester
|
public enum Semester
|
||||||
{
|
{
|
||||||
Первый = 1,
|
Первый = 1,
|
||||||
|
|
@ -0,0 +1,17 @@
|
|||||||
|
using CoreModels.Tools;
|
||||||
|
using ModuleTools.Attributes;
|
||||||
|
using System;
|
||||||
|
|
||||||
|
namespace CoreModels.ModelsDepartment
|
||||||
|
{
|
||||||
|
[EntityDescription("AcademicPlan", "Учебный план кафедры (на каждый учебный год новый план)")]
|
||||||
|
[EntityDependency("EducationDirection", "EducationDirectionId", "Направление, к которму относится учебный план")]
|
||||||
|
public interface IAcademicPlanModel : IId
|
||||||
|
{
|
||||||
|
Guid? EducationDirectionId { get; }
|
||||||
|
|
||||||
|
int YearEntrance { get; }
|
||||||
|
|
||||||
|
int YearFinish { get; }
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,35 @@
|
|||||||
|
using CoreModels.Enums.Department;
|
||||||
|
using CoreModels.Tools;
|
||||||
|
using ModuleTools.Attributes;
|
||||||
|
using System;
|
||||||
|
|
||||||
|
namespace CoreModels.ModelsDepartment
|
||||||
|
{
|
||||||
|
[EntityDescription("AcademicPlanRecord", "Запись учебного плана кафедры")]
|
||||||
|
[EntityDependency("AcademicPlan", "AcademicPlanId", "Учебный план, к которму относится запись")]
|
||||||
|
[EntityDependency("Discipline", "DisciplineId", "Дисциплина, которая указана в записи плана")]
|
||||||
|
public interface IAcademicPlanRecordModel : IId
|
||||||
|
{
|
||||||
|
Guid AcademicPlanId { get; }
|
||||||
|
|
||||||
|
Guid DisciplineId { get; }
|
||||||
|
|
||||||
|
Semester Semester { get; }
|
||||||
|
|
||||||
|
int Zet { get; }
|
||||||
|
|
||||||
|
bool InDepartment { get; }
|
||||||
|
|
||||||
|
Guid? AcademicPlanRecordParentId { get; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Является родительской для дисциплин по выбору
|
||||||
|
/// </summary>
|
||||||
|
bool IsParent { get; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Является факультативной дисциплиной
|
||||||
|
/// </summary>
|
||||||
|
bool IsFacultative { get; }
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,18 @@
|
|||||||
|
using CoreModels.Tools;
|
||||||
|
using ModuleTools.Attributes;
|
||||||
|
using System;
|
||||||
|
|
||||||
|
namespace CoreModels.ModelsDepartment
|
||||||
|
{
|
||||||
|
[EntityDescription("AcademicPlanRecordTimeNormHour", "Часы нагрузки записи учебного плана")]
|
||||||
|
[EntityDependency("AcademicPlanRecord", "AcademicPlanRecordId", "Запись учебного плана, к которой относятся часы")]
|
||||||
|
[EntityDependency("TimeNorm", "TimeNormId", "Норма времени, к которой относятся часы")]
|
||||||
|
public interface IAcademicPlanRecordTimeNormHourModel : IId
|
||||||
|
{
|
||||||
|
Guid AcademicPlanRecordId { get; }
|
||||||
|
|
||||||
|
Guid TimeNormId { get; }
|
||||||
|
|
||||||
|
decimal PlanHours { get; }
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,32 @@
|
|||||||
|
using CoreModels.Enums.Department;
|
||||||
|
using CoreModels.Tools;
|
||||||
|
using ModuleTools.Attributes;
|
||||||
|
using System;
|
||||||
|
|
||||||
|
namespace CoreModels.ModelsDepartment
|
||||||
|
{
|
||||||
|
[EntityDescription("Classroom", "Аудитрия кафедры")]
|
||||||
|
[EntityDependency("Employee", "EmployeeId", "Сотрудник, отвечающий за аудиторию")]
|
||||||
|
public interface IClassroomModel : IId
|
||||||
|
{
|
||||||
|
string Number { get; }
|
||||||
|
|
||||||
|
string Title { get; }
|
||||||
|
|
||||||
|
Guid EmployeeId { get; }
|
||||||
|
|
||||||
|
ClassroomType ClassroomType { get; }
|
||||||
|
|
||||||
|
decimal Square { get; }
|
||||||
|
|
||||||
|
int Capacity { get; }
|
||||||
|
|
||||||
|
string SecurityCode { get; }
|
||||||
|
|
||||||
|
bool HaveProjector { get; }
|
||||||
|
|
||||||
|
string Description { get; }
|
||||||
|
|
||||||
|
byte[] Photo { get; }
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,17 @@
|
|||||||
|
using CoreModels.Tools;
|
||||||
|
using ModuleTools.Attributes;
|
||||||
|
|
||||||
|
namespace CoreModels.ModelsDepartment
|
||||||
|
{
|
||||||
|
[EntityDescription("DisciplineBlock", "Аудитрия кафедры")]
|
||||||
|
public interface IDisciplineBlockModel : IId
|
||||||
|
{
|
||||||
|
string Title { get; }
|
||||||
|
|
||||||
|
bool DisciplineBlockUseForGrouping { get; }
|
||||||
|
|
||||||
|
int DisciplineBlockOrder { get; }
|
||||||
|
|
||||||
|
string DisciplineBlockBlueAsteriskName { get; }
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,21 @@
|
|||||||
|
using CoreModels.Tools;
|
||||||
|
using ModuleTools.Attributes;
|
||||||
|
using System;
|
||||||
|
|
||||||
|
namespace CoreModels.ModelsDepartment
|
||||||
|
{
|
||||||
|
[EntityDescription("Discipline", "Дисципилна кафедры")]
|
||||||
|
[EntityDependency("DisciplineBlock", "DisciplineBlockId", "Блок дисцпилн, к которому относится дисциплина")]
|
||||||
|
public interface IDisciplineModel : IId
|
||||||
|
{
|
||||||
|
Guid DisciplineBlockId { get; }
|
||||||
|
|
||||||
|
string DisciplineName { get; }
|
||||||
|
|
||||||
|
string DisciplineShortName { get; }
|
||||||
|
|
||||||
|
string Description { get; }
|
||||||
|
|
||||||
|
string DisciplineBlueAsteriskName { get; }
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,26 @@
|
|||||||
|
using CoreModels.Enums.Department;
|
||||||
|
using CoreModels.Tools;
|
||||||
|
using ModuleTools.Attributes;
|
||||||
|
using System;
|
||||||
|
|
||||||
|
namespace CoreModels.ModelsDepartment
|
||||||
|
{
|
||||||
|
[EntityDescription("EducationDirection", "Направление обучения кафедры")]
|
||||||
|
[EntityDependency("Lecturer", "LecturerId", "Преподаватель, руководитель напарвления")]
|
||||||
|
public interface IEducationDirectionModel : IId
|
||||||
|
{
|
||||||
|
string Cipher { get; }
|
||||||
|
|
||||||
|
string ShortName { get; }
|
||||||
|
|
||||||
|
string Title { get; }
|
||||||
|
|
||||||
|
string Profile { get; }
|
||||||
|
|
||||||
|
EducationDirectionQualification Qualification { get; }
|
||||||
|
|
||||||
|
Guid LecturerId { get; }
|
||||||
|
|
||||||
|
string Description { get; }
|
||||||
|
}
|
||||||
|
}
|
@ -1,4 +1,4 @@
|
|||||||
using ModuleTools.Attributes;
|
using CoreModels.ModelsDepartment;
|
||||||
using ModuleTools.Interfaces;
|
using ModuleTools.Interfaces;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
@ -8,26 +8,18 @@ using System.Runtime.Serialization;
|
|||||||
|
|
||||||
namespace DatabaseCore.Models.Department
|
namespace DatabaseCore.Models.Department
|
||||||
{
|
{
|
||||||
/// <summary>
|
[DataContract]
|
||||||
/// Класс, описывающий учебный план кафедры
|
public class AcademicPlan : BaseEntity, IEntitySecurityExtenstion<AcademicPlan>, IAcademicPlanModel
|
||||||
/// </summary>
|
{
|
||||||
[DataContract]
|
|
||||||
[EntityDescription("AcademicPlan", "Учебный план кафедры")]
|
|
||||||
[EntityDependency("EducationDirection", "EducationDirectionId", "Направление, к которму относится учебный план")]
|
|
||||||
public class AcademicPlan : BaseEntity, IEntitySecurityExtenstion<AcademicPlan>
|
|
||||||
{
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[MapConfiguration("EducationDirectionId")]
|
|
||||||
public Guid? EducationDirectionId { get; set; }
|
public Guid? EducationDirectionId { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("YearEntrance")]
|
|
||||||
public int YearEntrance { get; set; }
|
public int YearEntrance { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("YearFinish")]
|
|
||||||
public int YearFinish { get; set; }
|
public int YearFinish { get; set; }
|
||||||
|
|
||||||
//-------------------------------------------------------------------------
|
//-------------------------------------------------------------------------
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
using ModuleTools.Attributes;
|
using CoreModels.Enums.Department;
|
||||||
|
using CoreModels.ModelsDepartment;
|
||||||
using ModuleTools.Interfaces;
|
using ModuleTools.Interfaces;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
@ -8,50 +9,36 @@ using System.Runtime.Serialization;
|
|||||||
|
|
||||||
namespace DatabaseCore.Models.Department
|
namespace DatabaseCore.Models.Department
|
||||||
{
|
{
|
||||||
/// <summary>
|
[DataContract]
|
||||||
/// Класс, описывающий запись учебного плана кафедры
|
public class AcademicPlanRecord : BaseEntity, IEntitySecurityExtenstion<AcademicPlanRecord>, IAcademicPlanRecordModel
|
||||||
/// </summary>
|
|
||||||
[DataContract]
|
|
||||||
[EntityDescription("AcademicPlanRecord", "Запись учебного плана кафедры")]
|
|
||||||
[EntityDependency("AcademicPlan", "AcademicPlanId", "Учебный план, к которму относится запись")]
|
|
||||||
[EntityDependency("Discipline", "DisciplineId", "Дисциплина, которая указана в записи плана")]
|
|
||||||
public class AcademicPlanRecord : BaseEntity, IEntitySecurityExtenstion<AcademicPlanRecord>
|
|
||||||
{
|
{
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("AcademicPlanId")]
|
|
||||||
public Guid AcademicPlanId { get; set; }
|
public Guid AcademicPlanId { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("DisciplineId")]
|
|
||||||
public Guid DisciplineId { get; set; }
|
public Guid DisciplineId { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("InDepartment")]
|
|
||||||
public bool InDepartment { get; set; }
|
public bool InDepartment { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("Semester")]
|
public Semester Semester { get; set; }
|
||||||
public int Semester { get; set; }
|
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("Zet")]
|
|
||||||
public int Zet { get; set; }
|
public int Zet { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[MapConfiguration("AcademicPlanRecordParentId")]
|
|
||||||
public Guid? AcademicPlanRecordParentId { get; set; }
|
public Guid? AcademicPlanRecordParentId { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[MapConfiguration("IsParent")]
|
|
||||||
public bool IsParent { get; set; }
|
public bool IsParent { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[MapConfiguration("IsFacultative")]
|
|
||||||
public bool IsFacultative { get; set; }
|
public bool IsFacultative { get; set; }
|
||||||
|
|
||||||
//-------------------------------------------------------------------------
|
//-------------------------------------------------------------------------
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
using ModuleTools.Attributes;
|
using CoreModels.ModelsDepartment;
|
||||||
using ModuleTools.Interfaces;
|
using ModuleTools.Interfaces;
|
||||||
using System;
|
using System;
|
||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations;
|
||||||
@ -6,28 +6,19 @@ using System.Runtime.Serialization;
|
|||||||
|
|
||||||
namespace DatabaseCore.Models.Department
|
namespace DatabaseCore.Models.Department
|
||||||
{
|
{
|
||||||
/// <summary>
|
[DataContract]
|
||||||
/// Класс, описывающий часы нагрузок записей учебных планов кафедры
|
public class AcademicPlanRecordTimeNormHour : BaseEntity, IEntitySecurityExtenstion<AcademicPlanRecordTimeNormHour>, IAcademicPlanRecordTimeNormHourModel
|
||||||
/// </summary>
|
|
||||||
[DataContract]
|
|
||||||
[EntityDescription("AcademicPlanRecordTimeNormHour", "Часы нагрузки записи учебного плана")]
|
|
||||||
[EntityDependency("AcademicPlanRecord", "AcademicPlanRecordId", "Запись учебного плана, к которой относятся часы")]
|
|
||||||
[EntityDependency("TimeNorm", "TimeNormId", "Норма времени, к которой относятся часы")]
|
|
||||||
public class AcademicPlanRecordTimeNormHour : BaseEntity, IEntitySecurityExtenstion<AcademicPlanRecordTimeNormHour>
|
|
||||||
{
|
{
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("AcademicPlanRecordId")]
|
|
||||||
public Guid AcademicPlanRecordId { get; set; }
|
public Guid AcademicPlanRecordId { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("TimeNormId")]
|
|
||||||
public Guid TimeNormId { get; set; }
|
public Guid TimeNormId { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("PlanHours")]
|
|
||||||
public decimal PlanHours { get; set; }
|
public decimal PlanHours { get; set; }
|
||||||
|
|
||||||
//-------------------------------------------------------------------------
|
//-------------------------------------------------------------------------
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
using ModuleTools.Attributes;
|
using CoreModels.Enums.Department;
|
||||||
|
using CoreModels.ModelsDepartment;
|
||||||
using ModuleTools.Interfaces;
|
using ModuleTools.Interfaces;
|
||||||
using System;
|
using System;
|
||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations;
|
||||||
@ -6,57 +7,42 @@ using System.Runtime.Serialization;
|
|||||||
|
|
||||||
namespace DatabaseCore.Models.Department
|
namespace DatabaseCore.Models.Department
|
||||||
{
|
{
|
||||||
/// <summary>
|
[DataContract]
|
||||||
/// Класс, описывающий аудиторию кафедры
|
public class Classroom : BaseEntity, IEntitySecurityExtenstion<Classroom>, IClassroomModel
|
||||||
/// </summary>
|
|
||||||
[DataContract]
|
|
||||||
[EntityDescription("Classroom", "Аудитрия кафедры")]
|
|
||||||
[EntityDependency("Employee", "EmployeeId", "Сотрудник, отвечающий за аудиторию")]
|
|
||||||
public class Classroom : BaseEntity, IEntitySecurityExtenstion<Classroom>
|
|
||||||
{
|
{
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("Number")]
|
|
||||||
public string Number { get; set; }
|
public string Number { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[MapConfiguration("Title")]
|
|
||||||
public string Title { get; set; }
|
public string Title { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("EmployeeId")]
|
|
||||||
public Guid EmployeeId { get; set; }
|
public Guid EmployeeId { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("ClassroomType")]
|
public ClassroomType ClassroomType { get; set; }
|
||||||
public int ClassroomType { get; set; }
|
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("Square")]
|
|
||||||
public decimal Square { get; set; }
|
public decimal Square { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("Capacity")]
|
|
||||||
public int Capacity { get; set; }
|
public int Capacity { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[MapConfiguration("SecurityCode")]
|
|
||||||
public string SecurityCode { get; set; }
|
public string SecurityCode { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[MapConfiguration("HaveProjector")]
|
|
||||||
public bool HaveProjector { get; set; }
|
public bool HaveProjector { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[MapConfiguration("Description")]
|
|
||||||
public string Description { get; set; }
|
public string Description { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[MapConfiguration("Photo")]
|
|
||||||
public byte[] Photo { get; set; }
|
public byte[] Photo { get; set; }
|
||||||
|
|
||||||
//-------------------------------------------------------------------------
|
//-------------------------------------------------------------------------
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
using ModuleTools.Attributes;
|
using CoreModels.ModelsDepartment;
|
||||||
using ModuleTools.Interfaces;
|
using ModuleTools.Interfaces;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
@ -8,33 +8,26 @@ using System.Runtime.Serialization;
|
|||||||
|
|
||||||
namespace DatabaseCore.Models.Department
|
namespace DatabaseCore.Models.Department
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Класс, описывающий дисципилну кафедры
|
/// Класс, описывающий дисципилну кафедры
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[DataContract]
|
[DataContract]
|
||||||
[EntityDescription("Discipline", "Дисципилна кафедры")]
|
public class Discipline : BaseEntity, IEntitySecurityExtenstion<Discipline>, IDisciplineModel
|
||||||
[EntityDependency("DisciplineBlock", "DisciplineBlockId", "Блок дисцпилн, к которому относится дисциплина")]
|
|
||||||
public class Discipline : BaseEntity, IEntitySecurityExtenstion<Discipline>
|
|
||||||
{
|
{
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("DisciplineBlockId")]
|
|
||||||
public Guid DisciplineBlockId { get; set; }
|
public Guid DisciplineBlockId { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("DisciplineName")]
|
|
||||||
public string DisciplineName { get; set; }
|
public string DisciplineName { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[MapConfiguration("DisciplineShortName")]
|
|
||||||
public string DisciplineShortName { get; set; }
|
public string DisciplineShortName { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[MapConfiguration("Description")]
|
|
||||||
public string Description { get; set; }
|
public string Description { get; set; }
|
||||||
|
|
||||||
[MapConfiguration("DisciplineBlueAsteriskName")]
|
|
||||||
public string DisciplineBlueAsteriskName { get; set; }
|
public string DisciplineBlueAsteriskName { get; set; }
|
||||||
|
|
||||||
//-------------------------------------------------------------------------
|
//-------------------------------------------------------------------------
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
using ModuleTools.Attributes;
|
using CoreModels.ModelsDepartment;
|
||||||
using ModuleTools.Interfaces;
|
using ModuleTools.Interfaces;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations;
|
||||||
@ -7,28 +7,20 @@ using System.Runtime.Serialization;
|
|||||||
|
|
||||||
namespace DatabaseCore.Models.Department
|
namespace DatabaseCore.Models.Department
|
||||||
{
|
{
|
||||||
/// <summary>
|
[DataContract]
|
||||||
/// Класс, описывающий блок дисциплин
|
public class DisciplineBlock : BaseEntity, IEntitySecurityExtenstion<DisciplineBlock>, IDisciplineBlockModel
|
||||||
/// </summary>
|
{
|
||||||
[DataContract]
|
|
||||||
[EntityDescription("DisciplineBlock", "Аудитрия кафедры")]
|
|
||||||
public class DisciplineBlock : BaseEntity, IEntitySecurityExtenstion<DisciplineBlock>
|
|
||||||
{
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("Title")]
|
|
||||||
public string Title { get; set; }
|
public string Title { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[MapConfiguration("DisciplineBlockUseForGrouping")]
|
|
||||||
public bool DisciplineBlockUseForGrouping { get; set; }
|
public bool DisciplineBlockUseForGrouping { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[MapConfiguration("DisciplineBlockOrder")]
|
|
||||||
public int DisciplineBlockOrder { get; set; }
|
public int DisciplineBlockOrder { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[MapConfiguration("DisciplineBlockBlueAsteriskName")]
|
|
||||||
public string DisciplineBlockBlueAsteriskName { get; set; }
|
public string DisciplineBlockBlueAsteriskName { get; set; }
|
||||||
|
|
||||||
//-------------------------------------------------------------------------
|
//-------------------------------------------------------------------------
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
using ModuleTools.Attributes;
|
using CoreModels.Enums.Department;
|
||||||
|
using CoreModels.ModelsDepartment;
|
||||||
using ModuleTools.Interfaces;
|
using ModuleTools.Interfaces;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
@ -8,43 +9,34 @@ using System.Runtime.Serialization;
|
|||||||
|
|
||||||
namespace DatabaseCore.Models.Department
|
namespace DatabaseCore.Models.Department
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Класс, описывающий направление обучения кафедры
|
/// Класс, описывающий направление обучения кафедры
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[DataContract]
|
[DataContract]
|
||||||
[EntityDescription("EducationDirection", "Направление обучения кафедры")]
|
public class EducationDirection : BaseEntity, IEntitySecurityExtenstion<EducationDirection>, IEducationDirectionModel
|
||||||
[EntityDependency("Lecturer", "LecturerId", "Преподаватель, руководитель напарвления")]
|
{
|
||||||
public class EducationDirection : BaseEntity, IEntitySecurityExtenstion<EducationDirection>
|
|
||||||
{
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("Cipher")]
|
|
||||||
public string Cipher { get; set; }
|
public string Cipher { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("ShortName")]
|
|
||||||
public string ShortName { get; set; }
|
public string ShortName { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("Title")]
|
|
||||||
public string Title { get; set; }
|
public string Title { get; set; }
|
||||||
|
|
||||||
[MapConfiguration("Profile")]
|
|
||||||
public string Profile { get; set; }
|
public string Profile { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("Qualification")]
|
public EducationDirectionQualification Qualification { get; set; }
|
||||||
public int Qualification { get; set; }
|
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("LecturerId")]
|
|
||||||
public Guid LecturerId { get; set; }
|
public Guid LecturerId { get; set; }
|
||||||
|
|
||||||
[MapConfiguration("Description")]
|
|
||||||
public string Description { get; set; }
|
public string Description { get; set; }
|
||||||
|
|
||||||
//-------------------------------------------------------------------------
|
//-------------------------------------------------------------------------
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
using ModuleTools.Attributes;
|
using CoreModels.Enums.Department;
|
||||||
|
using ModuleTools.Attributes;
|
||||||
using ModuleTools.Interfaces;
|
using ModuleTools.Interfaces;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
@ -38,7 +39,7 @@ namespace DatabaseCore.Models.Department
|
|||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[MapConfiguration("TimeNormEducationDirectionQualification")]
|
[MapConfiguration("TimeNormEducationDirectionQualification")]
|
||||||
public int? TimeNormEducationDirectionQualification { get; set; }
|
public EducationDirectionQualification? TimeNormEducationDirectionQualification { get; set; }
|
||||||
|
|
||||||
[DataMember]
|
[DataMember]
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
|
@ -1,14 +1,14 @@
|
|||||||
using ModuleTools.Attributes;
|
using CoreModels.ModelsDepartment;
|
||||||
using ModuleTools.BindingModels;
|
using ModuleTools.BindingModels;
|
||||||
using System;
|
using System;
|
||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations;
|
||||||
|
|
||||||
namespace DepartmentBusinessLogic.BindingModels
|
namespace DepartmentBusinessLogic.BindingModels
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Получение учебного года
|
/// Получение учебного года
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class AcademicPlanGetBindingModel : GetBindingModel
|
public class AcademicPlanGetBindingModel : GetBindingModel
|
||||||
{
|
{
|
||||||
public Guid? EducationDirectionId { get; set; }
|
public Guid? EducationDirectionId { get; set; }
|
||||||
}
|
}
|
||||||
@ -16,17 +16,14 @@ namespace DepartmentBusinessLogic.BindingModels
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Сохранение учебного года
|
/// Сохранение учебного года
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class AcademicPlanSetBindingModel : SetBindingModel
|
public class AcademicPlanSetBindingModel : SetBindingModel, IAcademicPlanModel
|
||||||
{
|
{
|
||||||
[MapConfiguration("EducationDirectionId")]
|
|
||||||
public Guid? EducationDirectionId { get; set; }
|
public Guid? EducationDirectionId { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("YearEntrance")]
|
|
||||||
public int YearEntrance { get; set; }
|
public int YearEntrance { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("YearFinish")]
|
|
||||||
public int YearFinish { get; set; }
|
public int YearFinish { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,15 +1,15 @@
|
|||||||
using DepartmentBusinessLogic.Enums;
|
using CoreModels.Enums.Department;
|
||||||
using ModuleTools.Attributes;
|
using CoreModels.ModelsDepartment;
|
||||||
using ModuleTools.BindingModels;
|
using ModuleTools.BindingModels;
|
||||||
using System;
|
using System;
|
||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations;
|
||||||
|
|
||||||
namespace DepartmentBusinessLogic.BindingModels
|
namespace DepartmentBusinessLogic.BindingModels
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Получение записи учебного плана
|
/// Получение записи учебного плана
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class AcademicPlanRecordGetBindingModel : GetBindingModel
|
public class AcademicPlanRecordGetBindingModel : GetBindingModel
|
||||||
{
|
{
|
||||||
public Guid? AcademicPlanId { get; set; }
|
public Guid? AcademicPlanId { get; set; }
|
||||||
|
|
||||||
@ -21,41 +21,27 @@ namespace DepartmentBusinessLogic.BindingModels
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Сохранение записи учебного плана
|
/// Сохранение записи учебного плана
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class AcademicPlanRecordSetBindingModel : SetBindingModel
|
public class AcademicPlanRecordSetBindingModel : SetBindingModel, IAcademicPlanRecordModel
|
||||||
{
|
{
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("AcademicPlanId")]
|
|
||||||
public Guid AcademicPlanId { get; set; }
|
public Guid AcademicPlanId { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("DisciplineId")]
|
|
||||||
public Guid DisciplineId { get; set; }
|
public Guid DisciplineId { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("InDepartment")]
|
|
||||||
public bool InDepartment { get; set; }
|
public bool InDepartment { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("Semester")]
|
|
||||||
public Semester Semester { get; set; }
|
public Semester Semester { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("Zet")]
|
|
||||||
public int Zet { get; set; }
|
public int Zet { get; set; }
|
||||||
|
|
||||||
[MapConfiguration("AcademicPlanRecordParentId")]
|
|
||||||
public Guid? AcademicPlanRecordParentId { get; set; }
|
public Guid? AcademicPlanRecordParentId { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Является родительской для дисциплин по выбору
|
|
||||||
/// </summary>
|
|
||||||
[MapConfiguration("IsParent")]
|
|
||||||
public bool IsParent { get; set; }
|
public bool IsParent { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Является факультативной дисциплиной
|
|
||||||
/// </summary>
|
|
||||||
[MapConfiguration("IsFacultative")]
|
|
||||||
public bool IsFacultative { get; set; }
|
public bool IsFacultative { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,4 +1,4 @@
|
|||||||
using ModuleTools.Attributes;
|
using CoreModels.ModelsDepartment;
|
||||||
using ModuleTools.BindingModels;
|
using ModuleTools.BindingModels;
|
||||||
using System;
|
using System;
|
||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations;
|
||||||
@ -18,18 +18,15 @@ namespace DepartmentBusinessLogic.BindingModels
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Сохранение часов по норме времени для записи учебного плана
|
/// Сохранение часов по норме времени для записи учебного плана
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class AcademicPlanRecordTimeNormHourSetBindingModel : SetBindingModel
|
public class AcademicPlanRecordTimeNormHourSetBindingModel : SetBindingModel, IAcademicPlanRecordTimeNormHourModel
|
||||||
{
|
{
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("AcademicPlanRecordId")]
|
|
||||||
public Guid AcademicPlanRecordId { get; set; }
|
public Guid AcademicPlanRecordId { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("TimeNormId")]
|
|
||||||
public Guid TimeNormId { get; set; }
|
public Guid TimeNormId { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("PlanHours")]
|
|
||||||
public decimal PlanHours { get; set; }
|
public decimal PlanHours { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,5 +1,5 @@
|
|||||||
using DepartmentBusinessLogic.Enums;
|
using CoreModels.Enums.Department;
|
||||||
using ModuleTools.Attributes;
|
using CoreModels.ModelsDepartment;
|
||||||
using ModuleTools.BindingModels;
|
using ModuleTools.BindingModels;
|
||||||
using System;
|
using System;
|
||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations;
|
||||||
@ -25,41 +25,31 @@ namespace DepartmentBusinessLogic.BindingModels
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Сохранение аудитории
|
/// Сохранение аудитории
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class ClassroomSetBindingModel : SetBindingModel
|
public class ClassroomSetBindingModel : SetBindingModel, IClassroomModel
|
||||||
{
|
{
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("Number")]
|
|
||||||
public string Number { get; set; }
|
public string Number { get; set; }
|
||||||
|
|
||||||
[MapConfiguration("Title")]
|
|
||||||
public string Title { get; set; }
|
public string Title { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("EmployeeId")]
|
|
||||||
public Guid EmployeeId { get; set; }
|
public Guid EmployeeId { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("ClassroomType")]
|
|
||||||
public ClassroomType ClassroomType { get; set; }
|
public ClassroomType ClassroomType { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("Square")]
|
|
||||||
public decimal Square { get; set; }
|
public decimal Square { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("Capacity")]
|
|
||||||
public int Capacity { get; set; }
|
public int Capacity { get; set; }
|
||||||
|
|
||||||
[MapConfiguration("SecurityCode")]
|
|
||||||
public string SecurityCode { get; set; }
|
public string SecurityCode { get; set; }
|
||||||
|
|
||||||
[MapConfiguration("HaveProjector")]
|
|
||||||
public bool HaveProjector { get; set; }
|
public bool HaveProjector { get; set; }
|
||||||
|
|
||||||
[MapConfiguration("Description")]
|
|
||||||
public string Description { get; set; }
|
public string Description { get; set; }
|
||||||
|
|
||||||
[MapConfiguration("Photo")]
|
|
||||||
public byte[] Photo { get; set; }
|
public byte[] Photo { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,14 +1,14 @@
|
|||||||
using ModuleTools.Attributes;
|
using CoreModels.ModelsDepartment;
|
||||||
using ModuleTools.BindingModels;
|
using ModuleTools.BindingModels;
|
||||||
using System;
|
using System;
|
||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations;
|
||||||
|
|
||||||
namespace DepartmentBusinessLogic.BindingModels
|
namespace DepartmentBusinessLogic.BindingModels
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Получение дисциплины
|
/// Получение дисциплины
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class DisciplineGetBindingModel : GetBindingModel
|
public class DisciplineGetBindingModel : GetBindingModel
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Выбрка по блокам
|
/// Выбрка по блокам
|
||||||
@ -24,36 +24,29 @@ namespace DepartmentBusinessLogic.BindingModels
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Сохранение дисциплины
|
/// Сохранение дисциплины
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class DisciplineSetBindingModel : SetBindingModel
|
public class DisciplineSetBindingModel : SetBindingModel, IDisciplineModel
|
||||||
{
|
{
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("DisciplineBlockId")]
|
|
||||||
public Guid DisciplineBlockId { get; set; }
|
public Guid DisciplineBlockId { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("DisciplineName")]
|
|
||||||
public string DisciplineName { get; set; }
|
public string DisciplineName { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("DisciplineShortName")]
|
|
||||||
public string DisciplineShortName { get; set; }
|
public string DisciplineShortName { get; set; }
|
||||||
|
|
||||||
[MapConfiguration("Description")]
|
|
||||||
public string Description { get; set; }
|
public string Description { get; set; }
|
||||||
|
|
||||||
[MapConfiguration("DisciplineBlueAsteriskName")]
|
|
||||||
public string DisciplineBlueAsteriskName { get; set; }
|
public string DisciplineBlueAsteriskName { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Используется только в расчетах, не сохраняется
|
/// Используется только в расчетах, не сохраняется
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[MapConfiguration("DisciplineBlueAsteriskCode")]
|
|
||||||
public string DisciplineBlueAsteriskCode { get; set; }
|
public string DisciplineBlueAsteriskCode { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Используется только в расчетах, не сохраняется
|
/// Используется только в расчетах, не сохраняется
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[MapConfiguration("DisciplineBlueAsteriskPracticCode")]
|
|
||||||
public string DisciplineBlueAsteriskPracticCode { get; set; }
|
public string DisciplineBlueAsteriskPracticCode { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,4 +1,4 @@
|
|||||||
using ModuleTools.Attributes;
|
using CoreModels.ModelsDepartment;
|
||||||
using ModuleTools.BindingModels;
|
using ModuleTools.BindingModels;
|
||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations;
|
||||||
|
|
||||||
@ -14,20 +14,16 @@ namespace DepartmentBusinessLogic.BindingModels
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Сохранение блока дисциплин
|
/// Сохранение блока дисциплин
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class DisciplineBlockSetBindingModel : SetBindingModel
|
public class DisciplineBlockSetBindingModel : SetBindingModel, IDisciplineBlockModel
|
||||||
{
|
{
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("Title")]
|
|
||||||
public string Title { get; set; }
|
public string Title { get; set; }
|
||||||
|
|
||||||
[MapConfiguration("DisciplineBlockUseForGrouping")]
|
|
||||||
public bool DisciplineBlockUseForGrouping { get; set; }
|
public bool DisciplineBlockUseForGrouping { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("DisciplineBlockOrder")]
|
|
||||||
public int DisciplineBlockOrder { get; set; }
|
public int DisciplineBlockOrder { get; set; }
|
||||||
|
|
||||||
[MapConfiguration("DisciplineBlockBlueAsteriskName")]
|
|
||||||
public string DisciplineBlockBlueAsteriskName { get; set; }
|
public string DisciplineBlockBlueAsteriskName { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,15 +1,15 @@
|
|||||||
using DepartmentBusinessLogic.Enums;
|
using CoreModels.Enums.Department;
|
||||||
using ModuleTools.Attributes;
|
using CoreModels.ModelsDepartment;
|
||||||
using ModuleTools.BindingModels;
|
using ModuleTools.BindingModels;
|
||||||
using System;
|
using System;
|
||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations;
|
||||||
|
|
||||||
namespace DepartmentBusinessLogic.BindingModels
|
namespace DepartmentBusinessLogic.BindingModels
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Получение направления обучения
|
/// Получение направления обучения
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class EducationDirectionGetBindingModel : GetBindingModel
|
public class EducationDirectionGetBindingModel : GetBindingModel
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Вывод направлений, закрепленных за преподавателем
|
/// Вывод направлений, закрепленных за преподавателем
|
||||||
@ -20,32 +20,25 @@ namespace DepartmentBusinessLogic.BindingModels
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Сохранение направления обучения
|
/// Сохранение направления обучения
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class EducationDirectionSetBindingModel : SetBindingModel
|
public class EducationDirectionSetBindingModel : SetBindingModel, IEducationDirectionModel
|
||||||
{
|
{
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("Cipher")]
|
|
||||||
public string Cipher { get; set; }
|
public string Cipher { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("ShortName")]
|
|
||||||
public string ShortName { get; set; }
|
public string ShortName { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("Title")]
|
|
||||||
public string Title { get; set; }
|
public string Title { get; set; }
|
||||||
|
|
||||||
[MapConfiguration("Profile")]
|
|
||||||
public string Profile { get; set; }
|
public string Profile { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("Qualification")]
|
|
||||||
public EducationDirectionQualification Qualification { get; set; }
|
public EducationDirectionQualification Qualification { get; set; }
|
||||||
|
|
||||||
[Required(ErrorMessage = "required")]
|
[Required(ErrorMessage = "required")]
|
||||||
[MapConfiguration("LecturerId")]
|
|
||||||
public Guid LecturerId { get; set; }
|
public Guid LecturerId { get; set; }
|
||||||
|
|
||||||
[MapConfiguration("Description")]
|
|
||||||
public string Description { get; set; }
|
public string Description { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,4 +1,4 @@
|
|||||||
using DepartmentBusinessLogic.Enums;
|
using CoreModels.Enums.Department;
|
||||||
using ModuleTools.Attributes;
|
using ModuleTools.Attributes;
|
||||||
using ModuleTools.BindingModels;
|
using ModuleTools.BindingModels;
|
||||||
using System;
|
using System;
|
||||||
|
@ -1,12 +0,0 @@
|
|||||||
namespace DepartmentBusinessLogic.Enums
|
|
||||||
{
|
|
||||||
/// <summary>
|
|
||||||
/// Уровни обучения
|
|
||||||
/// </summary>
|
|
||||||
public enum EducationDirectionQualification
|
|
||||||
{
|
|
||||||
Бакалавриат = 0,
|
|
||||||
|
|
||||||
Магистратура = 1
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,4 +1,5 @@
|
|||||||
using DepartmentBusinessLogic.Enums;
|
using CoreModels.Enums.Department;
|
||||||
|
using CoreModels.ModelsDepartment;
|
||||||
using ModuleTools.Attributes;
|
using ModuleTools.Attributes;
|
||||||
using ModuleTools.Enums;
|
using ModuleTools.Enums;
|
||||||
using ModuleTools.ViewModels;
|
using ModuleTools.ViewModels;
|
||||||
@ -6,19 +7,18 @@ using System;
|
|||||||
|
|
||||||
namespace DepartmentBusinessLogic.ViewModels
|
namespace DepartmentBusinessLogic.ViewModels
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Список часов по нагрузке для записи учебного плана
|
/// Список часов по нагрузке для записи учебного плана
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class AcademicPlanRecordTimeNormHourListViewModel : ListViewModel<AcademicPlanRecordTimeNormHourViewModel> { }
|
public class AcademicPlanRecordTimeNormHourListViewModel : ListViewModel<AcademicPlanRecordTimeNormHourViewModel> { }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Элемент часов по нагрузке для записи учебного плана
|
/// Элемент часов по нагрузке для записи учебного плана
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[ViewModelControlElementClass()]
|
[ViewModelControlElementClass()]
|
||||||
public class AcademicPlanRecordTimeNormHourViewModel : ElementViewModel
|
public class AcademicPlanRecordTimeNormHourViewModel : ElementViewModel, IAcademicPlanRecordTimeNormHourModel
|
||||||
{
|
{
|
||||||
[ViewModelControlElementProperty("Запись учебного плана", ControlType.ControlGuid, MustHaveValue = true, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlAcademicPlanRecordList, DepartmentWindowsDesktop")]
|
[ViewModelControlElementProperty("Запись учебного плана", ControlType.ControlGuid, MustHaveValue = true, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlAcademicPlanRecordList, DepartmentWindowsDesktop")]
|
||||||
[MapConfiguration("AcademicPlanRecordId")]
|
|
||||||
public Guid AcademicPlanRecordId { get; set; }
|
public Guid AcademicPlanRecordId { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Дисциплина")]
|
[ViewModelControlListProperty("Дисциплина")]
|
||||||
@ -32,7 +32,6 @@ namespace DepartmentBusinessLogic.ViewModels
|
|||||||
public string SemesterTitle => Semester.ToString("G");
|
public string SemesterTitle => Semester.ToString("G");
|
||||||
|
|
||||||
[ViewModelControlElementProperty("Норма времени", ControlType.ControlGuid, MustHaveValue = true, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlTimeNormList, DepartmentWindowsDesktop")]
|
[ViewModelControlElementProperty("Норма времени", ControlType.ControlGuid, MustHaveValue = true, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlTimeNormList, DepartmentWindowsDesktop")]
|
||||||
[MapConfiguration("TimeNormId")]
|
|
||||||
public Guid TimeNormId { get; set; }
|
public Guid TimeNormId { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Норма времени")]
|
[ViewModelControlListProperty("Норма времени")]
|
||||||
@ -41,7 +40,6 @@ namespace DepartmentBusinessLogic.ViewModels
|
|||||||
|
|
||||||
[ViewModelControlListProperty("Часы", ColumnWidth = 80)]
|
[ViewModelControlListProperty("Часы", ColumnWidth = 80)]
|
||||||
[ViewModelControlElementProperty("Часы", ControlType.ControlDecimal, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Часы", ControlType.ControlDecimal, MustHaveValue = true)]
|
||||||
[MapConfiguration("PlanHours")]
|
|
||||||
public decimal PlanHours { get; set; }
|
public decimal PlanHours { get; set; }
|
||||||
|
|
||||||
public override string ToString() => $"{DisciplineName}({Semester}) - {TimeNormName}";
|
public override string ToString() => $"{DisciplineName}({Semester}) - {TimeNormName}";
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
using DepartmentBusinessLogic.Enums;
|
using CoreModels.Enums.Department;
|
||||||
|
using CoreModels.ModelsDepartment;
|
||||||
using ModuleTools.Attributes;
|
using ModuleTools.Attributes;
|
||||||
using ModuleTools.Enums;
|
using ModuleTools.Enums;
|
||||||
using ModuleTools.ViewModels;
|
using ModuleTools.ViewModels;
|
||||||
@ -6,10 +7,10 @@ using System;
|
|||||||
|
|
||||||
namespace DepartmentBusinessLogic.ViewModels
|
namespace DepartmentBusinessLogic.ViewModels
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Список аудиторий
|
/// Список аудиторий
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class AcademicPlanRecordListViewModel : ListViewModel<AcademicPlanRecordViewModel> { }
|
public class AcademicPlanRecordListViewModel : ListViewModel<AcademicPlanRecordViewModel> { }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Элемент аудитории
|
/// Элемент аудитории
|
||||||
@ -17,14 +18,12 @@ namespace DepartmentBusinessLogic.ViewModels
|
|||||||
[ViewModelControlElementClass(HaveDependenceEntities = true, Width = 800, Height = 500)]
|
[ViewModelControlElementClass(HaveDependenceEntities = true, Width = 800, Height = 500)]
|
||||||
[ViewModelControlElementDependenceEntity(Title = "Часы по нагрузкам", Order = 1, ParentPropertyName = "AcademicPlanRecordId",
|
[ViewModelControlElementDependenceEntity(Title = "Часы по нагрузкам", Order = 1, ParentPropertyName = "AcademicPlanRecordId",
|
||||||
ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlAcademicPlanRecordTimeNormHourList, DepartmentWindowsDesktop")]
|
ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlAcademicPlanRecordTimeNormHourList, DepartmentWindowsDesktop")]
|
||||||
public class AcademicPlanRecordViewModel : ElementViewModel
|
public class AcademicPlanRecordViewModel : ElementViewModel, IAcademicPlanRecordModel
|
||||||
{
|
{
|
||||||
[ViewModelControlElementProperty("Учебный план", ControlType.ControlGuid, MustHaveValue = true, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlAcademicPlanList, DepartmentWindowsDesktop")]
|
[ViewModelControlElementProperty("Учебный план", ControlType.ControlGuid, MustHaveValue = true, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlAcademicPlanList, DepartmentWindowsDesktop")]
|
||||||
[MapConfiguration("AcademicPlanId")]
|
|
||||||
public Guid AcademicPlanId { get; set; }
|
public Guid AcademicPlanId { get; set; }
|
||||||
|
|
||||||
[ViewModelControlElementProperty("Дисциплина", ControlType.ControlGuid, MustHaveValue = true, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlDisciplineList, DepartmentWindowsDesktop")]
|
[ViewModelControlElementProperty("Дисциплина", ControlType.ControlGuid, MustHaveValue = true, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlDisciplineList, DepartmentWindowsDesktop")]
|
||||||
[MapConfiguration("DisciplineId")]
|
|
||||||
public Guid DisciplineId { get; set; }
|
public Guid DisciplineId { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Дисциплина")]
|
[ViewModelControlListProperty("Дисциплина")]
|
||||||
@ -32,14 +31,12 @@ namespace DepartmentBusinessLogic.ViewModels
|
|||||||
public string DisciplineName { get; set; }
|
public string DisciplineName { get; set; }
|
||||||
|
|
||||||
[ViewModelControlElementProperty("Преподается на кафедре", ControlType.ControlBool, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Преподается на кафедре", ControlType.ControlBool, MustHaveValue = true)]
|
||||||
[MapConfiguration("InDepartment")]
|
|
||||||
public bool InDepartment { get; set; }
|
public bool InDepartment { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("На кафедре", ColumnWidth = 100)]
|
[ViewModelControlListProperty("На кафедре", ColumnWidth = 100)]
|
||||||
public string InDepartmentValue => InDepartment ? "Да" : "Нет";
|
public string InDepartmentValue => InDepartment ? "Да" : "Нет";
|
||||||
|
|
||||||
[ViewModelControlElementProperty("Семестр", ControlType.ControlEnum, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Семестр", ControlType.ControlEnum, MustHaveValue = true)]
|
||||||
[MapConfiguration("Semester")]
|
|
||||||
public Semester Semester { get; set; }
|
public Semester Semester { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Семестр", ColumnWidth = 80)]
|
[ViewModelControlListProperty("Семестр", ColumnWidth = 80)]
|
||||||
@ -47,15 +44,12 @@ namespace DepartmentBusinessLogic.ViewModels
|
|||||||
|
|
||||||
[ViewModelControlListProperty("Зет", ColumnWidth = 60)]
|
[ViewModelControlListProperty("Зет", ColumnWidth = 60)]
|
||||||
[ViewModelControlElementProperty("Зет", ControlType.ControlInt, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Зет", ControlType.ControlInt, MustHaveValue = true)]
|
||||||
[MapConfiguration("Zet")]
|
|
||||||
public int Zet { get; set; }
|
public int Zet { get; set; }
|
||||||
|
|
||||||
[ViewModelControlElementProperty("Родитель", ControlType.ControlGuid, MustHaveValue = false, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlAcademicPlanRecordList, DepartmentWindowsDesktop")]
|
[ViewModelControlElementProperty("Родитель", ControlType.ControlGuid, MustHaveValue = false, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlAcademicPlanRecordList, DepartmentWindowsDesktop")]
|
||||||
[MapConfiguration("AcademicPlanRecordParentId")]
|
|
||||||
public Guid? AcademicPlanRecordParentId { get; set; }
|
public Guid? AcademicPlanRecordParentId { get; set; }
|
||||||
|
|
||||||
[ViewModelControlElementProperty("Является родительской", ControlType.ControlBool, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Является родительской", ControlType.ControlBool, MustHaveValue = true)]
|
||||||
[MapConfiguration("IsParent")]
|
|
||||||
public bool IsParent { get; set; }
|
public bool IsParent { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("ДВ", ColumnWidth = 50)]
|
[ViewModelControlListProperty("ДВ", ColumnWidth = 50)]
|
||||||
@ -64,11 +58,7 @@ namespace DepartmentBusinessLogic.ViewModels
|
|||||||
[ViewModelControlListProperty("По выбору", ColumnWidth = 100)]
|
[ViewModelControlListProperty("По выбору", ColumnWidth = 100)]
|
||||||
public string IsChildValue => AcademicPlanRecordParentId.HasValue ? "Да" : "Нет";
|
public string IsChildValue => AcademicPlanRecordParentId.HasValue ? "Да" : "Нет";
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Является факультативной дисциплиной
|
|
||||||
/// </summary>
|
|
||||||
[ViewModelControlElementProperty("Является факультативной", ControlType.ControlBool, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Является факультативной", ControlType.ControlBool, MustHaveValue = true)]
|
||||||
[MapConfiguration("IsFacultative")]
|
|
||||||
public bool IsFacultative { get; set; }
|
public bool IsFacultative { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Факульт", ColumnWidth = 80)]
|
[ViewModelControlListProperty("Факульт", ColumnWidth = 80)]
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
using ModuleTools.Attributes;
|
using CoreModels.ModelsDepartment;
|
||||||
|
using ModuleTools.Attributes;
|
||||||
using ModuleTools.Enums;
|
using ModuleTools.Enums;
|
||||||
using ModuleTools.ViewModels;
|
using ModuleTools.ViewModels;
|
||||||
using System;
|
using System;
|
||||||
@ -16,10 +17,9 @@ namespace DepartmentBusinessLogic.ViewModels
|
|||||||
[ViewModelControlElementClass(HaveDependenceEntities = true, Width = 1200, Height = 800)]
|
[ViewModelControlElementClass(HaveDependenceEntities = true, Width = 1200, Height = 800)]
|
||||||
[ViewModelControlElementDependenceEntity(Title = "Записи плана", Order = 1, ParentPropertyName = "AcademicPlanId",
|
[ViewModelControlElementDependenceEntity(Title = "Записи плана", Order = 1, ParentPropertyName = "AcademicPlanId",
|
||||||
ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlAcademicPlanRecordList, DepartmentWindowsDesktop")]
|
ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlAcademicPlanRecordList, DepartmentWindowsDesktop")]
|
||||||
public class AcademicPlanViewModel : ElementViewModel
|
public class AcademicPlanViewModel : ElementViewModel, IAcademicPlanModel
|
||||||
{
|
{
|
||||||
[ViewModelControlElementProperty("Направление", ControlType.ControlGuid, MustHaveValue = false, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlEducationDirectionList, DepartmentWindowsDesktop")]
|
[ViewModelControlElementProperty("Направление", ControlType.ControlGuid, MustHaveValue = false, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlEducationDirectionList, DepartmentWindowsDesktop")]
|
||||||
[MapConfiguration("EducationDirectionId")]
|
|
||||||
public Guid? EducationDirectionId { get; set; }
|
public Guid? EducationDirectionId { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Направление")]
|
[ViewModelControlListProperty("Направление")]
|
||||||
@ -32,12 +32,10 @@ namespace DepartmentBusinessLogic.ViewModels
|
|||||||
|
|
||||||
[ViewModelControlListProperty("Дата начала", ColumnWidth = 120)]
|
[ViewModelControlListProperty("Дата начала", ColumnWidth = 120)]
|
||||||
[ViewModelControlElementProperty("Дата начала", ControlType.ControlInt, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Дата начала", ControlType.ControlInt, MustHaveValue = true)]
|
||||||
[MapConfiguration("YearEntrance")]
|
|
||||||
public int YearEntrance { get; set; }
|
public int YearEntrance { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Дата окончания", ColumnWidth = 120)]
|
[ViewModelControlListProperty("Дата окончания", ColumnWidth = 120)]
|
||||||
[ViewModelControlElementProperty("Дата окончания", ControlType.ControlInt, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Дата окончания", ControlType.ControlInt, MustHaveValue = true)]
|
||||||
[MapConfiguration("YearFinish")]
|
|
||||||
public int YearFinish { get; set; }
|
public int YearFinish { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,4 +1,5 @@
|
|||||||
using DepartmentBusinessLogic.Enums;
|
using CoreModels.Enums.Department;
|
||||||
|
using CoreModels.ModelsDepartment;
|
||||||
using ModuleTools.Attributes;
|
using ModuleTools.Attributes;
|
||||||
using ModuleTools.Enums;
|
using ModuleTools.Enums;
|
||||||
using ModuleTools.ViewModels;
|
using ModuleTools.ViewModels;
|
||||||
@ -6,29 +7,26 @@ using System;
|
|||||||
|
|
||||||
namespace DepartmentBusinessLogic.ViewModels
|
namespace DepartmentBusinessLogic.ViewModels
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Список аудиторий
|
/// Список аудиторий
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class ClassroomListViewModel : ListViewModel<ClassroomViewModel> { }
|
public class ClassroomListViewModel : ListViewModel<ClassroomViewModel> { }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Элемент аудитории
|
/// Элемент аудитории
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[ViewModelControlElementClass()]
|
[ViewModelControlElementClass()]
|
||||||
public class ClassroomViewModel : ElementViewModel
|
public class ClassroomViewModel : ElementViewModel, IClassroomModel
|
||||||
{
|
{
|
||||||
[ViewModelControlListProperty("Номер", ColumnWidth = 80)]
|
[ViewModelControlListProperty("Номер", ColumnWidth = 80)]
|
||||||
[ViewModelControlElementProperty("Номер аудитории", ControlType.ControlString, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Номер аудитории", ControlType.ControlString, MustHaveValue = true)]
|
||||||
[MapConfiguration("Number")]
|
|
||||||
public string Number { get; set; }
|
public string Number { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Название")]
|
[ViewModelControlListProperty("Название")]
|
||||||
[ViewModelControlElementProperty("Название", ControlType.ControlString)]
|
[ViewModelControlElementProperty("Название", ControlType.ControlString)]
|
||||||
[MapConfiguration("Title")]
|
|
||||||
public string Title { get; set; }
|
public string Title { get; set; }
|
||||||
|
|
||||||
[ViewModelControlElementProperty("Сотрудник", ControlType.ControlGuid, MustHaveValue = true, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlEmployeeList, DepartmentWindowsDesktop")]
|
[ViewModelControlElementProperty("Сотрудник", ControlType.ControlGuid, MustHaveValue = true, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlEmployeeList, DepartmentWindowsDesktop")]
|
||||||
[MapConfiguration("EmployeeId")]
|
|
||||||
public Guid EmployeeId { get; set; }
|
public Guid EmployeeId { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Сотрудник")]
|
[ViewModelControlListProperty("Сотрудник")]
|
||||||
@ -36,7 +34,6 @@ namespace DepartmentBusinessLogic.ViewModels
|
|||||||
public string EmployeeName { get; set; }
|
public string EmployeeName { get; set; }
|
||||||
|
|
||||||
[ViewModelControlElementProperty("Тип", ControlType.ControlEnum, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Тип", ControlType.ControlEnum, MustHaveValue = true)]
|
||||||
[MapConfiguration("ClassroomType")]
|
|
||||||
public ClassroomType ClassroomType { get; set; }
|
public ClassroomType ClassroomType { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Тип", ColumnWidth = 120)]
|
[ViewModelControlListProperty("Тип", ColumnWidth = 120)]
|
||||||
@ -44,32 +41,26 @@ namespace DepartmentBusinessLogic.ViewModels
|
|||||||
|
|
||||||
[ViewModelControlListProperty("Площадь", ColumnWidth = 90)]
|
[ViewModelControlListProperty("Площадь", ColumnWidth = 90)]
|
||||||
[ViewModelControlElementProperty("Площадь", ControlType.ControlDecimal, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Площадь", ControlType.ControlDecimal, MustHaveValue = true)]
|
||||||
[MapConfiguration("Square")]
|
|
||||||
public decimal Square { get; set; }
|
public decimal Square { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Кол-во мест", ColumnWidth = 100)]
|
[ViewModelControlListProperty("Кол-во мест", ColumnWidth = 100)]
|
||||||
[ViewModelControlElementProperty("Кол-во мест", ControlType.ControlInt, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Кол-во мест", ControlType.ControlInt, MustHaveValue = true)]
|
||||||
[MapConfiguration("Capacity")]
|
|
||||||
public int Capacity { get; set; }
|
public int Capacity { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Код безоп.", ColumnWidth = 100)]
|
[ViewModelControlListProperty("Код безоп.", ColumnWidth = 100)]
|
||||||
[ViewModelControlElementProperty("Код безоп.", ControlType.ControlString, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Код безоп.", ControlType.ControlString, MustHaveValue = true)]
|
||||||
[MapConfiguration("SecurityCode")]
|
|
||||||
public string SecurityCode { get; set; }
|
public string SecurityCode { get; set; }
|
||||||
|
|
||||||
[ViewModelControlElementProperty("Есть проектор", ControlType.ControlBool, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Есть проектор", ControlType.ControlBool, MustHaveValue = true)]
|
||||||
[MapConfiguration("HaveProjector")]
|
|
||||||
public bool HaveProjector { get; set; }
|
public bool HaveProjector { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Есть проектор", ColumnWidth = 80)]
|
[ViewModelControlListProperty("Есть проектор", ColumnWidth = 80)]
|
||||||
public string IsHaveProjector => HaveProjector ? "Да" : "Нет";
|
public string IsHaveProjector => HaveProjector ? "Да" : "Нет";
|
||||||
|
|
||||||
[ViewModelControlElementProperty("Описание", ControlType.ControlText)]
|
[ViewModelControlElementProperty("Описание", ControlType.ControlText)]
|
||||||
[MapConfiguration("Description")]
|
|
||||||
public string Description { get; set; }
|
public string Description { get; set; }
|
||||||
|
|
||||||
[ViewModelControlElementProperty("Фото", ControlType.ControlImage, Width = 200, Height = 200)]
|
[ViewModelControlElementProperty("Фото", ControlType.ControlImage, Width = 200, Height = 200)]
|
||||||
[MapConfiguration("Photo")]
|
|
||||||
public byte[] Photo { get; set; }
|
public byte[] Photo { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,13 +1,14 @@
|
|||||||
using ModuleTools.Attributes;
|
using CoreModels.ModelsDepartment;
|
||||||
|
using ModuleTools.Attributes;
|
||||||
using ModuleTools.Enums;
|
using ModuleTools.Enums;
|
||||||
using ModuleTools.ViewModels;
|
using ModuleTools.ViewModels;
|
||||||
|
|
||||||
namespace DepartmentBusinessLogic.ViewModels
|
namespace DepartmentBusinessLogic.ViewModels
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Список блоков дисциплин
|
/// Список блоков дисциплин
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class DisciplineBlockListViewModel : ListViewModel<DisciplineBlockViewModel> { }
|
public class DisciplineBlockListViewModel : ListViewModel<DisciplineBlockViewModel> { }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Элемент блок дисциплины
|
/// Элемент блок дисциплины
|
||||||
@ -17,24 +18,20 @@ namespace DepartmentBusinessLogic.ViewModels
|
|||||||
ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlDisciplineList, DepartmentWindowsDesktop")]
|
ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlDisciplineList, DepartmentWindowsDesktop")]
|
||||||
[ViewModelControlElementDependenceEntity(Title = "Нормы времени", Order = 1, ParentPropertyName = "DisciplineBlockId",
|
[ViewModelControlElementDependenceEntity(Title = "Нормы времени", Order = 1, ParentPropertyName = "DisciplineBlockId",
|
||||||
ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlTimeNormList, DepartmentWindowsDesktop")]
|
ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlTimeNormList, DepartmentWindowsDesktop")]
|
||||||
public class DisciplineBlockViewModel : ElementViewModel
|
public class DisciplineBlockViewModel : ElementViewModel, IDisciplineBlockModel
|
||||||
{
|
{
|
||||||
[ViewModelControlListProperty("Название блока")]
|
[ViewModelControlListProperty("Название блока")]
|
||||||
[ViewModelControlElementProperty("Название блока", ControlType.ControlString, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Название блока", ControlType.ControlString, MustHaveValue = true)]
|
||||||
[MapConfiguration("Title")]
|
|
||||||
public string Title { get; set; }
|
public string Title { get; set; }
|
||||||
|
|
||||||
[ViewModelControlElementProperty("Используется для группровки в расчетах", ControlType.ControlBool, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Используется для группровки в расчетах", ControlType.ControlBool, MustHaveValue = true)]
|
||||||
[MapConfiguration("DisciplineBlockUseForGrouping")]
|
|
||||||
public bool DisciplineBlockUseForGrouping { get; set; }
|
public bool DisciplineBlockUseForGrouping { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Порядок", ColumnWidth = 100)]
|
[ViewModelControlListProperty("Порядок", ColumnWidth = 100)]
|
||||||
[ViewModelControlElementProperty("Порядок", ControlType.ControlInt, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Порядок", ControlType.ControlInt, MustHaveValue = true)]
|
||||||
[MapConfiguration("DisciplineBlockOrder")]
|
|
||||||
public int DisciplineBlockOrder { get; set; }
|
public int DisciplineBlockOrder { get; set; }
|
||||||
|
|
||||||
[ViewModelControlElementProperty("Назв. в планах", ControlType.ControlString)]
|
[ViewModelControlElementProperty("Назв. в планах", ControlType.ControlString)]
|
||||||
[MapConfiguration("DisciplineBlockBlueAsteriskName")]
|
|
||||||
public string DisciplineBlockBlueAsteriskName { get; set; }
|
public string DisciplineBlockBlueAsteriskName { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,14 +1,15 @@
|
|||||||
using ModuleTools.Attributes;
|
using CoreModels.ModelsDepartment;
|
||||||
|
using ModuleTools.Attributes;
|
||||||
using ModuleTools.Enums;
|
using ModuleTools.Enums;
|
||||||
using ModuleTools.ViewModels;
|
using ModuleTools.ViewModels;
|
||||||
using System;
|
using System;
|
||||||
|
|
||||||
namespace DepartmentBusinessLogic.ViewModels
|
namespace DepartmentBusinessLogic.ViewModels
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Список дисциплин
|
/// Список дисциплин
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class DisciplineListViewModel : ListViewModel<DisciplineViewModel> { }
|
public class DisciplineListViewModel : ListViewModel<DisciplineViewModel> { }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Элемент дисциплина
|
/// Элемент дисциплина
|
||||||
@ -16,29 +17,24 @@ namespace DepartmentBusinessLogic.ViewModels
|
|||||||
[ViewModelControlElementClass(HaveDependenceEntities = true, Width = 800, Height = 500)]
|
[ViewModelControlElementClass(HaveDependenceEntities = true, Width = 800, Height = 500)]
|
||||||
[ViewModelControlElementDependenceEntity(Title = "Записи учебного плана", Order = 1, ParentPropertyName = "DisciplineId",
|
[ViewModelControlElementDependenceEntity(Title = "Записи учебного плана", Order = 1, ParentPropertyName = "DisciplineId",
|
||||||
ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlAcademicPlanRecordList, DepartmentWindowsDesktop")]
|
ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlAcademicPlanRecordList, DepartmentWindowsDesktop")]
|
||||||
public class DisciplineViewModel : ElementViewModel
|
public class DisciplineViewModel : ElementViewModel, IDisciplineModel
|
||||||
{
|
{
|
||||||
[ViewModelControlElementProperty("Блок дисциплин", ControlType.ControlGuid, MustHaveValue = true, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlDisciplineBlockList, DepartmentWindowsDesktop")]
|
[ViewModelControlElementProperty("Блок дисциплин", ControlType.ControlGuid, MustHaveValue = true, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlDisciplineBlockList, DepartmentWindowsDesktop")]
|
||||||
[MapConfiguration("DisciplineBlockId")]
|
|
||||||
public Guid DisciplineBlockId { get; set; }
|
public Guid DisciplineBlockId { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Название дисциплины")]
|
[ViewModelControlListProperty("Название дисциплины")]
|
||||||
[ViewModelControlElementProperty("Название дисциплины", ControlType.ControlString, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Название дисциплины", ControlType.ControlString, MustHaveValue = true)]
|
||||||
[MapConfiguration("DisciplineName")]
|
|
||||||
public string DisciplineName { get; set; }
|
public string DisciplineName { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Краткое название дисциплины")]
|
[ViewModelControlListProperty("Краткое название дисциплины")]
|
||||||
[ViewModelControlElementProperty("Краткое нисциплины", ControlType.ControlString, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Краткое нисциплины", ControlType.ControlString, MustHaveValue = true)]
|
||||||
[MapConfiguration("DisciplineShortName")]
|
|
||||||
public string DisciplineShortName { get; set; }
|
public string DisciplineShortName { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Описание")]
|
[ViewModelControlListProperty("Описание")]
|
||||||
[ViewModelControlElementProperty("Описание", ControlType.ControlText, Height = 200, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Описание", ControlType.ControlText, Height = 200, MustHaveValue = true)]
|
||||||
[MapConfiguration("Description")]
|
|
||||||
public string Description { get; set; }
|
public string Description { get; set; }
|
||||||
|
|
||||||
[ViewModelControlElementProperty("Название в планах", ControlType.ControlString)]
|
[ViewModelControlElementProperty("Название в планах", ControlType.ControlString)]
|
||||||
[MapConfiguration("DisciplineBlueAsteriskName")]
|
|
||||||
public string DisciplineBlueAsteriskName { get; set; }
|
public string DisciplineBlueAsteriskName { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,4 +1,5 @@
|
|||||||
using DepartmentBusinessLogic.Enums;
|
using CoreModels.Enums.Department;
|
||||||
|
using CoreModels.ModelsDepartment;
|
||||||
using ModuleTools.Attributes;
|
using ModuleTools.Attributes;
|
||||||
using ModuleTools.Enums;
|
using ModuleTools.Enums;
|
||||||
using ModuleTools.ViewModels;
|
using ModuleTools.ViewModels;
|
||||||
@ -6,10 +7,10 @@ using System;
|
|||||||
|
|
||||||
namespace DepartmentBusinessLogic.ViewModels
|
namespace DepartmentBusinessLogic.ViewModels
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Список напарвлений обучений
|
/// Список напарвлений обучений
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class EducationDirectionListViewModel : ListViewModel<EducationDirectionViewModel> { }
|
public class EducationDirectionListViewModel : ListViewModel<EducationDirectionViewModel> { }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Элемент направления обучения
|
/// Элемент направления обучения
|
||||||
@ -19,30 +20,25 @@ namespace DepartmentBusinessLogic.ViewModels
|
|||||||
ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlAcademicPlanList, DepartmentWindowsDesktop")]
|
ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlAcademicPlanList, DepartmentWindowsDesktop")]
|
||||||
[ViewModelControlElementDependenceEntity(Title = "Группы", Order = 2, ParentPropertyName = "EducationDirectionId",
|
[ViewModelControlElementDependenceEntity(Title = "Группы", Order = 2, ParentPropertyName = "EducationDirectionId",
|
||||||
ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlStudentGroupList, DepartmentWindowsDesktop")]
|
ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlStudentGroupList, DepartmentWindowsDesktop")]
|
||||||
public class EducationDirectionViewModel : ElementViewModel
|
public class EducationDirectionViewModel : ElementViewModel, IEducationDirectionModel
|
||||||
{
|
{
|
||||||
[ViewModelControlListProperty("Шифр", ColumnWidth = 80)]
|
[ViewModelControlListProperty("Шифр", ColumnWidth = 80)]
|
||||||
[ViewModelControlElementProperty("Шифр", ControlType.ControlString, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Шифр", ControlType.ControlString, MustHaveValue = true)]
|
||||||
[MapConfiguration("Cipher")]
|
|
||||||
public string Cipher { get; set; }
|
public string Cipher { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Сокращение", ColumnWidth = 80)]
|
[ViewModelControlListProperty("Сокращение", ColumnWidth = 80)]
|
||||||
[ViewModelControlElementProperty("Сокращение", ControlType.ControlString, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Сокращение", ControlType.ControlString, MustHaveValue = true)]
|
||||||
[MapConfiguration("ShortName")]
|
|
||||||
public string ShortName { get; set; }
|
public string ShortName { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Название")]
|
[ViewModelControlListProperty("Название")]
|
||||||
[ViewModelControlElementProperty("Название", ControlType.ControlString, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Название", ControlType.ControlString, MustHaveValue = true)]
|
||||||
[MapConfiguration("Title")]
|
|
||||||
public string Title { get; set; }
|
public string Title { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Профиль")]
|
[ViewModelControlListProperty("Профиль")]
|
||||||
[ViewModelControlElementProperty("Профиль", ControlType.ControlString)]
|
[ViewModelControlElementProperty("Профиль", ControlType.ControlString)]
|
||||||
[MapConfiguration("Profile")]
|
|
||||||
public string Profile { get; set; }
|
public string Profile { get; set; }
|
||||||
|
|
||||||
[ViewModelControlElementProperty("Руководитель ОПОП", ControlType.ControlGuid, MustHaveValue = true, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlLecturerList, DepartmentWindowsDesktop")]
|
[ViewModelControlElementProperty("Руководитель ОПОП", ControlType.ControlGuid, MustHaveValue = true, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlLecturerList, DepartmentWindowsDesktop")]
|
||||||
[MapConfiguration("LecturerId")]
|
|
||||||
public Guid LecturerId { get; set; }
|
public Guid LecturerId { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("Руководитель ОПОП", ColumnWidth = 120)]
|
[ViewModelControlListProperty("Руководитель ОПОП", ColumnWidth = 120)]
|
||||||
@ -50,15 +46,13 @@ namespace DepartmentBusinessLogic.ViewModels
|
|||||||
public string LecturerName { get; set; }
|
public string LecturerName { get; set; }
|
||||||
|
|
||||||
[ViewModelControlElementProperty("Уровень обучения", ControlType.ControlEnum, MustHaveValue = true)]
|
[ViewModelControlElementProperty("Уровень обучения", ControlType.ControlEnum, MustHaveValue = true)]
|
||||||
[MapConfiguration("Qualification")]
|
|
||||||
public EducationDirectionQualification Qualification { get; set; }
|
public EducationDirectionQualification Qualification { get; set; }
|
||||||
|
|
||||||
[ViewModelControlListProperty("ровень обучения")]
|
[ViewModelControlListProperty("Уровень обучения")]
|
||||||
public string QualificationTitle => Qualification.ToString("G");
|
public string QualificationTitle => Qualification.ToString("G");
|
||||||
|
|
||||||
[ViewModelControlListProperty("Описание")]
|
[ViewModelControlListProperty("Описание")]
|
||||||
[ViewModelControlElementProperty("Описание", ControlType.ControlText, Height = 80)]
|
[ViewModelControlElementProperty("Описание", ControlType.ControlText, Height = 80)]
|
||||||
[MapConfiguration("Description")]
|
|
||||||
public string Description { get; set; }
|
public string Description { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,4 +1,4 @@
|
|||||||
using DepartmentBusinessLogic.Enums;
|
using CoreModels.Enums.Department;
|
||||||
using ModuleTools.Attributes;
|
using ModuleTools.Attributes;
|
||||||
using ModuleTools.Enums;
|
using ModuleTools.Enums;
|
||||||
using ModuleTools.ViewModels;
|
using ModuleTools.ViewModels;
|
||||||
@ -6,10 +6,10 @@ using System;
|
|||||||
|
|
||||||
namespace DepartmentBusinessLogic.ViewModels
|
namespace DepartmentBusinessLogic.ViewModels
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Список норм времени
|
/// Список норм времени
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class TimeNormListViewModel : ListViewModel<TimeNormViewModel> { }
|
public class TimeNormListViewModel : ListViewModel<TimeNormViewModel> { }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Элемент нормы времени
|
/// Элемент нормы времени
|
||||||
|
@ -33,7 +33,7 @@ namespace DepartmentDatabaseImplementation.Implementations
|
|||||||
}
|
}
|
||||||
if (model.Semester.HasValue)
|
if (model.Semester.HasValue)
|
||||||
{
|
{
|
||||||
query = query.Where(x => x.Semester == (int)model.Semester.Value);
|
query = query.Where(x => x.Semester == model.Semester.Value);
|
||||||
}
|
}
|
||||||
return query;
|
return query;
|
||||||
}
|
}
|
||||||
@ -51,7 +51,7 @@ namespace DepartmentDatabaseImplementation.Implementations
|
|||||||
context.SaveChanges();
|
context.SaveChanges();
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override AcademicPlanRecord GetUniqueEntity(AcademicPlanRecordSetBindingModel model, DbContext context) => context.Set<AcademicPlanRecord>().FirstOrDefault(x => x.AcademicPlanId == model.AcademicPlanId && x.DisciplineId == model.DisciplineId && x.Semester == (int)model.Semester && x.Id != model.Id);
|
protected override AcademicPlanRecord GetUniqueEntity(AcademicPlanRecordSetBindingModel model, DbContext context) => context.Set<AcademicPlanRecord>().FirstOrDefault(x => x.AcademicPlanId == model.AcademicPlanId && x.DisciplineId == model.DisciplineId && x.Semester == model.Semester && x.Id != model.Id);
|
||||||
|
|
||||||
protected override IQueryable<AcademicPlanRecord> IncludingWhenReading(IQueryable<AcademicPlanRecord> query) => query.Include(x => x.AcademicPlan).Include(x => x.Discipline);
|
protected override IQueryable<AcademicPlanRecord> IncludingWhenReading(IQueryable<AcademicPlanRecord> query) => query.Include(x => x.AcademicPlan).Include(x => x.Discipline);
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
using DatabaseCore;
|
using CoreModels.Enums.Department;
|
||||||
|
using DatabaseCore;
|
||||||
using DatabaseCore.Models.Department;
|
using DatabaseCore.Models.Department;
|
||||||
using DepartmentBusinessLogic.BindingModels;
|
using DepartmentBusinessLogic.BindingModels;
|
||||||
using DepartmentBusinessLogic.Enums;
|
|
||||||
using DepartmentBusinessLogic.Interfaces;
|
using DepartmentBusinessLogic.Interfaces;
|
||||||
using DepartmentBusinessLogic.ViewModels;
|
using DepartmentBusinessLogic.ViewModels;
|
||||||
using DepartmentDatabaseImplementation.Models;
|
using DepartmentDatabaseImplementation.Models;
|
||||||
@ -16,10 +16,10 @@ using System.Xml.Linq;
|
|||||||
|
|
||||||
namespace DepartmentDatabaseImplementation.Implementations
|
namespace DepartmentDatabaseImplementation.Implementations
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Реализация IAcademicPlanService
|
/// Реализация IAcademicPlanService
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class AcademicPlanService :
|
public class AcademicPlanService :
|
||||||
AbstractGenerticEntityService<AcademicPlanGetBindingModel, AcademicPlanSetBindingModel, AcademicPlan, AcademicPlanListViewModel, AcademicPlanViewModel>,
|
AbstractGenerticEntityService<AcademicPlanGetBindingModel, AcademicPlanSetBindingModel, AcademicPlan, AcademicPlanListViewModel, AcademicPlanViewModel>,
|
||||||
IAcademicPlanService
|
IAcademicPlanService
|
||||||
{
|
{
|
||||||
@ -320,7 +320,7 @@ namespace DepartmentDatabaseImplementation.Implementations
|
|||||||
parent = context.AcademicPlanRecords.FirstOrDefault(apr =>
|
parent = context.AcademicPlanRecords.FirstOrDefault(apr =>
|
||||||
apr.AcademicPlanId == model.AcademicPlanId &&
|
apr.AcademicPlanId == model.AcademicPlanId &&
|
||||||
apr.DisciplineId == parentDiscipilne.Entity.Id &&
|
apr.DisciplineId == parentDiscipilne.Entity.Id &&
|
||||||
apr.Semester == (int)hour.Semester);
|
apr.Semester == hour.Semester);
|
||||||
|
|
||||||
if (parent == null)
|
if (parent == null)
|
||||||
{
|
{
|
||||||
@ -330,7 +330,7 @@ namespace DepartmentDatabaseImplementation.Implementations
|
|||||||
AcademicPlanId = model.AcademicPlanId,
|
AcademicPlanId = model.AcademicPlanId,
|
||||||
DisciplineId = parentDiscipilne.Entity.Id,
|
DisciplineId = parentDiscipilne.Entity.Id,
|
||||||
InDepartment = inKafedra,
|
InDepartment = inKafedra,
|
||||||
Semester = (int)hour.Semester,
|
Semester = hour.Semester,
|
||||||
Zet = zet.IsNotEmpty() ? Convert.ToInt32(zet) : 0,
|
Zet = zet.IsNotEmpty() ? Convert.ToInt32(zet) : 0,
|
||||||
IsParent = true,
|
IsParent = true,
|
||||||
IsFacultative = isFacultative
|
IsFacultative = isFacultative
|
||||||
@ -357,7 +357,7 @@ namespace DepartmentDatabaseImplementation.Implementations
|
|||||||
var record = context.AcademicPlanRecords.FirstOrDefault(apr =>
|
var record = context.AcademicPlanRecords.FirstOrDefault(apr =>
|
||||||
apr.AcademicPlanId == model.AcademicPlanId &&
|
apr.AcademicPlanId == model.AcademicPlanId &&
|
||||||
apr.DisciplineId == discipline.Id &&
|
apr.DisciplineId == discipline.Id &&
|
||||||
apr.Semester == (int)hour.Semester);
|
apr.Semester == hour.Semester);
|
||||||
|
|
||||||
if (record == null)
|
if (record == null)
|
||||||
{
|
{
|
||||||
@ -366,7 +366,7 @@ namespace DepartmentDatabaseImplementation.Implementations
|
|||||||
AcademicPlanId = model.AcademicPlanId,
|
AcademicPlanId = model.AcademicPlanId,
|
||||||
DisciplineId = discipline.Id,
|
DisciplineId = discipline.Id,
|
||||||
Zet = zet.IsNotEmpty() ? Convert.ToInt32(zet) : 0,
|
Zet = zet.IsNotEmpty() ? Convert.ToInt32(zet) : 0,
|
||||||
Semester = (int)hour.Semester,
|
Semester = hour.Semester,
|
||||||
AcademicPlanRecordParentId = parent?.Id,
|
AcademicPlanRecordParentId = parent?.Id,
|
||||||
IsParent = false,
|
IsParent = false,
|
||||||
IsFacultative = isFacultative,
|
IsFacultative = isFacultative,
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
using DatabaseCore;
|
using CoreModels.Enums.Department;
|
||||||
|
using DatabaseCore;
|
||||||
using DatabaseCore.Models.Department;
|
using DatabaseCore.Models.Department;
|
||||||
using DepartmentBusinessLogic.BindingModels;
|
using DepartmentBusinessLogic.BindingModels;
|
||||||
using DepartmentBusinessLogic.Enums;
|
|
||||||
using DepartmentBusinessLogic.Interfaces;
|
using DepartmentBusinessLogic.Interfaces;
|
||||||
using DepartmentBusinessLogic.ViewModels;
|
using DepartmentBusinessLogic.ViewModels;
|
||||||
using Microsoft.EntityFrameworkCore;
|
using Microsoft.EntityFrameworkCore;
|
||||||
@ -10,10 +10,10 @@ using System.Linq;
|
|||||||
|
|
||||||
namespace DepartmentDatabaseImplementation.Implementations
|
namespace DepartmentDatabaseImplementation.Implementations
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Реализация интерфейса IClassroomService
|
/// Реализация интерфейса IClassroomService
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class ClassroomService :
|
public class ClassroomService :
|
||||||
AbstractGenerticEntityService<ClassroomGetBindingModel, ClassroomSetBindingModel, Classroom, ClassroomListViewModel, ClassroomViewModel>,
|
AbstractGenerticEntityService<ClassroomGetBindingModel, ClassroomSetBindingModel, Classroom, ClassroomListViewModel, ClassroomViewModel>,
|
||||||
IClassroomService
|
IClassroomService
|
||||||
{
|
{
|
||||||
@ -25,8 +25,8 @@ namespace DepartmentDatabaseImplementation.Implementations
|
|||||||
{
|
{
|
||||||
if (model.UseInSchedule.HasValue)
|
if (model.UseInSchedule.HasValue)
|
||||||
{
|
{
|
||||||
query = query.Where(x => x.ClassroomType == (int)ClassroomType.Дисплейный || x.ClassroomType == (int)ClassroomType.Лекционный ||
|
query = query.Where(x => x.ClassroomType == ClassroomType.Дисплейный || x.ClassroomType == ClassroomType.Лекционный ||
|
||||||
x.ClassroomType == (int)ClassroomType.Обычный);
|
x.ClassroomType == ClassroomType.Обычный);
|
||||||
}
|
}
|
||||||
if (model.EmployeeId.HasValue)
|
if (model.EmployeeId.HasValue)
|
||||||
{
|
{
|
||||||
|
@ -1,16 +1,15 @@
|
|||||||
using DatabaseCore.Models.Department;
|
using CoreModels.Enums.Department;
|
||||||
using DepartmentBusinessLogic.BindingModels;
|
using DatabaseCore.Models.Department;
|
||||||
using DepartmentBusinessLogic.Enums;
|
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Xml;
|
using System.Xml;
|
||||||
|
|
||||||
namespace DepartmentDatabaseImplementation.Models
|
namespace DepartmentDatabaseImplementation.Models
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Данные для разбора plx-файла с планом
|
/// Данные для разбора plx-файла с планом
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class ParsPlxModel
|
public class ParsPlxModel
|
||||||
{
|
{
|
||||||
public Guid AcademicPlanId { get; set; }
|
public Guid AcademicPlanId { get; set; }
|
||||||
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
using DepartmentBusinessLogic.BindingModels;
|
using CoreModels.Enums.Department;
|
||||||
|
using DepartmentBusinessLogic.BindingModels;
|
||||||
using DepartmentBusinessLogic.BusinessLogics;
|
using DepartmentBusinessLogic.BusinessLogics;
|
||||||
using DepartmentBusinessLogic.Enums;
|
|
||||||
using DepartmentBusinessLogic.ViewModels;
|
using DepartmentBusinessLogic.ViewModels;
|
||||||
using DesktopTools.Controls;
|
using DesktopTools.Controls;
|
||||||
using DesktopTools.Enums;
|
using DesktopTools.Enums;
|
||||||
@ -14,10 +14,10 @@ using System.Linq;
|
|||||||
|
|
||||||
namespace DepartmentWindowsDesktop.EntityControls
|
namespace DepartmentWindowsDesktop.EntityControls
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Реализация контрола для записей учебного плана
|
/// Реализация контрола для записей учебного плана
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public partial class ControlAcademicPlanRecordList :
|
public partial class ControlAcademicPlanRecordList :
|
||||||
GenericControlEntityList<AcademicPlanRecordGetBindingModel, AcademicPlanRecordSetBindingModel, AcademicPlanRecordListViewModel, AcademicPlanRecordViewModel, AcademicPlanRecordBusinessLogic>,
|
GenericControlEntityList<AcademicPlanRecordGetBindingModel, AcademicPlanRecordSetBindingModel, AcademicPlanRecordListViewModel, AcademicPlanRecordViewModel, AcademicPlanRecordBusinessLogic>,
|
||||||
IGenericControlEntityList
|
IGenericControlEntityList
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user