DepartmentProject/DepartmentPortal/Department/DepartmentContract/ViewModels/DisciplineViewModels.cs

44 lines
2.4 KiB
C#
Raw Normal View History

using CoreModels.ModelsDepartment;
2021-04-03 19:03:56 +04:00
using System;
2022-03-20 10:10:44 +04:00
using ToolsModule.ManagmentEntity;
2021-04-03 19:03:56 +04:00
namespace DepartmentContract.ViewModels
2021-04-03 19:03:56 +04:00
{
/// <summary>
/// Список дисциплин
/// </summary>
public class DisciplineListViewModel : ListViewModel<DisciplineViewModel> { }
2021-04-03 19:03:56 +04:00
/// <summary>
/// Элемент дисциплина
/// </summary>
2021-04-06 22:07:11 +04:00
[ViewModelControlElementClass(HaveDependenceEntities = true, Width = 800, Height = 500)]
[ViewModelControlElementDependenceEntity(Title = "Записи учебного плана", Order = 1, ParentPropertyName = "DisciplineId",
ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlAcademicPlanRecordList, DepartmentWindowsDesktop")]
public class DisciplineViewModel : ElementViewModel, IDisciplineModel
2021-04-03 19:03:56 +04:00
{
[ViewModelControlElementProperty("Блок дисциплин", ControlType.ControlGuid, MustHaveValue = true, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlDisciplineBlockList, DepartmentWindowsDesktop")]
public Guid DisciplineBlockId { get; set; }
2022-03-27 14:51:27 +04:00
[ViewModelControlElementProperty("Базовая кафедра", ControlType.ControlGuid, MustHaveValue = true, ReadOnly = false, ControlTypeObject = "DepartmentWindowsDesktop.EntityControls.ControlBasicDepartmentList, DepartmentWindowsDesktop")]
public Guid? BasicDepartmentId { get; set; }
[ViewModelControlListProperty("Базовая кафедра")]
public bool IsBasicDepartmentId => BasicDepartmentId.HasValue ? true : false;
2021-04-03 19:03:56 +04:00
[ViewModelControlListProperty("Название дисциплины")]
[ViewModelControlElementProperty("Название дисциплины", ControlType.ControlString, MustHaveValue = true)]
public string DisciplineName { get; set; }
[ViewModelControlListProperty("Краткое название дисциплины")]
[ViewModelControlElementProperty("Краткое нисциплины", ControlType.ControlString, MustHaveValue = true)]
public string DisciplineShortName { get; set; }
[ViewModelControlListProperty("Описание")]
[ViewModelControlElementProperty("Описание", ControlType.ControlText, Height = 200, MustHaveValue = true)]
public string Description { get; set; }
2021-04-03 19:03:56 +04:00
[ViewModelControlElementProperty("Название в планах", ControlType.ControlString)]
public string DisciplineBlueAsteriskName { get; set; }
2022-03-27 14:51:27 +04:00
}
2021-04-03 19:03:56 +04:00
}