File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- using System . Collections . Generic ;
1+ using System ;
2+ using System . Collections . Generic ;
23using System . Runtime . Serialization ;
34
45namespace Morph . Server . Sdk . Dto
@@ -19,7 +20,12 @@ internal class TaskFullDto
1920
2021 [ DataMember ( Name = "name" ) ]
2122 public string Name { get ; set ; } = string . Empty ;
22-
23-
23+ [ DataMember ( Name = "group" ) ]
24+ public string Group { get ; set ; } = string . Empty ;
25+
26+ [ DataMember ( Name = "schedules" ) ]
27+ public ScheduleBaseDto [ ] Schedules { get ; set ; } = Array . Empty < ScheduleBaseDto > ( ) ;
28+
29+
2430 }
2531}
Original file line number Diff line number Diff line change @@ -27,7 +27,9 @@ internal class TaskShortDto
2727 public string Name { get ; set ; } = string . Empty ;
2828
2929 [ DataMember ( Name = "nextRunText" ) ]
30- public string NextRunText { get ; set ; } = "" ;
31-
30+ public string NextRunText { get ; set ; } = string . Empty ;
31+ [ DataMember ( Name = "group" ) ]
32+ public string Group { get ; set ; } = string . Empty ;
33+
3234 }
3335}
Original file line number Diff line number Diff line change @@ -23,6 +23,7 @@ public static SpaceTasksListItem MapItem(TaskShortDto dto)
2323 TaskName = dto . Name ,
2424 Note = dto . Note ,
2525 ProjectPath = dto . ProjectFile ,
26+ Group = dto . Group ?? string . Empty ,
2627 Schedules = dto . Schedules ?
2728 . Select ( sdto => new TaskSchedule { ScheduleType = sdto . ScheduleType , ScheduleDescription = sdto . ScheduleAsText } )
2829 . ToArray ( ) ?? new [ ] { NoSchedule }
@@ -38,6 +39,10 @@ public static SpaceTask MapFull(TaskFullDto fullDto)
3839 TaskName = fullDto . Name ,
3940 Note = fullDto . Note ,
4041 ProjectPath = fullDto . ProjectFile ,
42+ Group = fullDto . Group ?? string . Empty ,
43+ Schedules = fullDto . Schedules ?
44+ . Select ( sdto => new TaskSchedule { ScheduleType = sdto . ScheduleType , ScheduleDescription = sdto . ScheduleAsText } )
45+ . ToArray ( ) ?? new [ ] { NoSchedule }
4146 } ;
4247 if ( fullDto . Parameters != null )
4348 {
Original file line number Diff line number Diff line change @@ -10,12 +10,12 @@ public class SpaceTasksListItem
1010 public string ProjectPath { get ; internal set ; } = string . Empty ;
1111 public string Note { get ; internal set ; } = string . Empty ;
1212
13- public TaskSchedule [ ] Schedules { get ; internal set ; } = Array . Empty < TaskSchedule > ( ) ;
14- //public List<TaskParameter> TaskParameters { get; internal set; } = new List<TaskParameter>();
15- //public string StatusText { get; internal set; } = string.Empty;
13+ public TaskSchedule [ ] Schedules { get ; internal set ; } = Array . Empty < TaskSchedule > ( ) ;
1614 public bool Enabled { get ; internal set ; } = false ;
17- //public bool IsRunning { get; internal set; } = false;
18- //public TaskState TaskState { get; internal set; } = TaskState.Disabled;
15+
16+ public string Group { get ; internal set ; } = string . Empty ;
17+
18+
1919 }
2020
2121 public sealed class SpaceTask : SpaceTasksListItem
You can’t perform that action at this time.
0 commit comments