ADO
This commit is contained in:
34
Adaptation/FileHandlers/json/WorkItems/CustomRequester.cs
Normal file
34
Adaptation/FileHandlers/json/WorkItems/CustomRequester.cs
Normal file
@ -0,0 +1,34 @@
|
||||
using System.Text.Json.Serialization;
|
||||
|
||||
namespace Adaptation.FileHandlers.json.WorkItems;
|
||||
|
||||
public class CustomRequester
|
||||
{
|
||||
[JsonConstructor]
|
||||
public CustomRequester(
|
||||
string descriptor,
|
||||
string displayName,
|
||||
string id,
|
||||
string imageUrl,
|
||||
Links links,
|
||||
string uniqueName,
|
||||
string url
|
||||
)
|
||||
{
|
||||
Descriptor = descriptor;
|
||||
DisplayName = displayName;
|
||||
Id = id;
|
||||
ImageUrl = imageUrl;
|
||||
Links = links;
|
||||
UniqueName = uniqueName;
|
||||
Url = url;
|
||||
}
|
||||
|
||||
[JsonPropertyName("descriptor")] public string Descriptor { get; }
|
||||
[JsonPropertyName("displayName")] public string DisplayName { get; }
|
||||
[JsonPropertyName("id")] public string Id { get; }
|
||||
[JsonPropertyName("imageUrl")] public string ImageUrl { get; }
|
||||
[JsonPropertyName("_links")] public Links Links { get; }
|
||||
[JsonPropertyName("uniqueName")] public string UniqueName { get; }
|
||||
[JsonPropertyName("url")] public string Url { get; }
|
||||
}
|
@ -5,109 +5,96 @@ namespace Adaptation.FileHandlers.json.WorkItems;
|
||||
|
||||
public class Fields
|
||||
{
|
||||
|
||||
#nullable enable
|
||||
|
||||
[JsonConstructor]
|
||||
public Fields(
|
||||
string systemAreaPath,
|
||||
string systemTeamProject,
|
||||
string systemIterationPath,
|
||||
string systemWorkItemType,
|
||||
string systemState,
|
||||
string systemReason,
|
||||
SystemAssignedTo systemAssignedTo,
|
||||
DateTime systemCreatedDate,
|
||||
SystemCreatedBy systemCreatedBy,
|
||||
DateTime systemChangedDate,
|
||||
SystemChangedBy systemChangedBy,
|
||||
int systemCommentCount,
|
||||
string systemTitle,
|
||||
DateTime microsoftVSTSCommonStateChangeDate,
|
||||
int microsoftVSTSCommonPriority,
|
||||
string systemDescription,
|
||||
string systemTags,
|
||||
string systemHistory,
|
||||
float? effort,
|
||||
DateTime targetDate
|
||||
)
|
||||
public Fields(int customRRminusOE,
|
||||
CustomRequester? customRequester,
|
||||
float customWSJF,
|
||||
float? microsoftVSTSSchedulingEffort,
|
||||
int microsoftVSTSCommonBusinessValue,
|
||||
DateTime microsoftVSTSCommonClosedDate,
|
||||
int microsoftVSTSCommonPriority,
|
||||
DateTime microsoftVSTSCommonResolvedDate,
|
||||
DateTime microsoftVSTSCommonStateChangeDate,
|
||||
float microsoftVSTSCommonTimeCriticality,
|
||||
DateTime microsoftVSTSSchedulingStartDate,
|
||||
string systemAreaPath,
|
||||
SystemAssignedTo systemAssignedTo,
|
||||
SystemChangedBy systemChangedBy,
|
||||
DateTime systemChangedDate,
|
||||
int systemCommentCount,
|
||||
SystemCreatedBy systemCreatedBy,
|
||||
DateTime systemCreatedDate,
|
||||
string systemDescription,
|
||||
string systemHistory,
|
||||
string systemIterationPath,
|
||||
string systemReason,
|
||||
string systemState,
|
||||
string systemTags,
|
||||
string systemTeamProject,
|
||||
string systemTitle,
|
||||
string systemWorkItemType,
|
||||
DateTime microsoftVSTSSchedulingTargetDate)
|
||||
{
|
||||
SystemAreaPath = systemAreaPath;
|
||||
SystemTeamProject = systemTeamProject;
|
||||
SystemIterationPath = systemIterationPath;
|
||||
SystemWorkItemType = systemWorkItemType;
|
||||
SystemState = systemState;
|
||||
SystemReason = systemReason;
|
||||
SystemAssignedTo = systemAssignedTo;
|
||||
SystemCreatedDate = systemCreatedDate;
|
||||
SystemCreatedBy = systemCreatedBy;
|
||||
SystemChangedDate = systemChangedDate;
|
||||
SystemChangedBy = systemChangedBy;
|
||||
SystemCommentCount = systemCommentCount;
|
||||
SystemTitle = systemTitle;
|
||||
MicrosoftVSTSCommonStateChangeDate = microsoftVSTSCommonStateChangeDate;
|
||||
CustomRRminusOE = customRRminusOE;
|
||||
CustomRequester = customRequester;
|
||||
CustomWSJF = customWSJF;
|
||||
MicrosoftVSTSSchedulingEffort = microsoftVSTSSchedulingEffort;
|
||||
MicrosoftVSTSCommonBusinessValue = microsoftVSTSCommonBusinessValue;
|
||||
MicrosoftVSTSCommonClosedDate = microsoftVSTSCommonClosedDate;
|
||||
MicrosoftVSTSCommonPriority = microsoftVSTSCommonPriority;
|
||||
MicrosoftVSTSCommonResolvedDate = microsoftVSTSCommonResolvedDate;
|
||||
MicrosoftVSTSCommonStateChangeDate = microsoftVSTSCommonStateChangeDate;
|
||||
MicrosoftVSTSCommonTimeCriticality = microsoftVSTSCommonTimeCriticality;
|
||||
MicrosoftVSTSSchedulingStartDate = microsoftVSTSSchedulingStartDate;
|
||||
SystemAreaPath = systemAreaPath;
|
||||
SystemAssignedTo = systemAssignedTo;
|
||||
SystemChangedBy = systemChangedBy;
|
||||
SystemChangedDate = systemChangedDate;
|
||||
SystemCommentCount = systemCommentCount;
|
||||
SystemCreatedBy = systemCreatedBy;
|
||||
SystemCreatedDate = systemCreatedDate;
|
||||
SystemDescription = systemDescription;
|
||||
SystemTags = systemTags;
|
||||
SystemHistory = systemHistory;
|
||||
Effort = effort;
|
||||
TargetDate = targetDate;
|
||||
SystemIterationPath = systemIterationPath;
|
||||
SystemReason = systemReason;
|
||||
SystemState = systemState;
|
||||
SystemTags = systemTags;
|
||||
SystemTeamProject = systemTeamProject;
|
||||
SystemTitle = systemTitle;
|
||||
SystemWorkItemType = systemWorkItemType;
|
||||
MicrosoftVSTSSchedulingTargetDate = microsoftVSTSSchedulingTargetDate;
|
||||
}
|
||||
|
||||
[JsonPropertyName("System.AreaPath")]
|
||||
public string SystemAreaPath { get; } // { init; get; }
|
||||
[JsonPropertyName("Custom.RRminusOE")] public int CustomRRminusOE { get; } // { init; get; }
|
||||
[JsonPropertyName("Custom.Requester")] public CustomRequester? CustomRequester { get; } // { init; get; }
|
||||
[JsonPropertyName("Custom.WSJF")] public float CustomWSJF { get; } // { init; get; }
|
||||
[JsonPropertyName("Microsoft.VSTS.Common.BusinessValue")] public int MicrosoftVSTSCommonBusinessValue { get; } // { init; get; }
|
||||
[JsonPropertyName("Microsoft.VSTS.Common.ClosedDate")] public DateTime MicrosoftVSTSCommonClosedDate { get; } // { init; get; }
|
||||
[JsonPropertyName("Microsoft.VSTS.Common.Priority")] public int MicrosoftVSTSCommonPriority { get; } // { init; get; }
|
||||
[JsonPropertyName("Microsoft.VSTS.Common.ResolvedDate")] public DateTime MicrosoftVSTSCommonResolvedDate { get; } // { init; get; }
|
||||
[JsonPropertyName("Microsoft.VSTS.Common.StateChangeDate")] public DateTime MicrosoftVSTSCommonStateChangeDate { get; } // { init; get; }
|
||||
[JsonPropertyName("Microsoft.VSTS.Common.TimeCriticality")] public float MicrosoftVSTSCommonTimeCriticality { get; } // { init; get; }
|
||||
[JsonPropertyName("Microsoft.VSTS.Scheduling.Effort")] public float? MicrosoftVSTSSchedulingEffort { get; } // { init; get; }
|
||||
[JsonPropertyName("Microsoft.VSTS.Scheduling.StartDate")] public DateTime MicrosoftVSTSSchedulingStartDate { get; } // { init; get; }
|
||||
[JsonPropertyName("System.AreaPath")] public string SystemAreaPath { get; } // { init; get; }
|
||||
[JsonPropertyName("System.AssignedTo")] public SystemAssignedTo? SystemAssignedTo { get; } // { init; get; }
|
||||
[JsonPropertyName("System.ChangedBy")] public SystemChangedBy SystemChangedBy { get; } // { init; get; }
|
||||
[JsonPropertyName("System.ChangedDate")] public DateTime SystemChangedDate { get; } // { init; get; }
|
||||
[JsonPropertyName("System.CommentCount")] public int SystemCommentCount { get; } // { init; get; }
|
||||
[JsonPropertyName("System.CreatedBy")] public SystemCreatedBy SystemCreatedBy { get; } // { init; get; }
|
||||
[JsonPropertyName("System.CreatedDate")] public DateTime SystemCreatedDate { get; } // { init; get; }
|
||||
[JsonPropertyName("System.Description")] public string SystemDescription { get; } // { init; get; }
|
||||
[JsonPropertyName("System.History")] public string SystemHistory { get; } // { init; get; }
|
||||
[JsonPropertyName("System.IterationPath")] public string SystemIterationPath { get; } // { init; get; }
|
||||
[JsonPropertyName("System.Reason")] public string SystemReason { get; } // { init; get; }
|
||||
[JsonPropertyName("System.State")] public string SystemState { get; } // { init; get; }
|
||||
[JsonPropertyName("System.Tags")] public string SystemTags { get; } // { init; get; }
|
||||
[JsonPropertyName("System.TeamProject")] public string SystemTeamProject { get; } // { init; get; }
|
||||
[JsonPropertyName("System.Title")] public string SystemTitle { get; } // { init; get; }
|
||||
[JsonPropertyName("System.WorkItemType")] public string SystemWorkItemType { get; } // { init; get; }
|
||||
[JsonPropertyName("Microsoft.VSTS.Scheduling.TargetDate")] public DateTime MicrosoftVSTSSchedulingTargetDate { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("System.TeamProject")]
|
||||
public string SystemTeamProject { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("System.IterationPath")]
|
||||
public string SystemIterationPath { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("System.WorkItemType")]
|
||||
public string SystemWorkItemType { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("System.State")]
|
||||
public string SystemState { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("System.Reason")]
|
||||
public string SystemReason { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("System.AssignedTo")]
|
||||
public SystemAssignedTo SystemAssignedTo { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("System.CreatedDate")]
|
||||
public DateTime SystemCreatedDate { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("System.CreatedBy")]
|
||||
public SystemCreatedBy SystemCreatedBy { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("System.ChangedDate")]
|
||||
public DateTime SystemChangedDate { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("System.ChangedBy")]
|
||||
public SystemChangedBy SystemChangedBy { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("System.CommentCount")]
|
||||
public int SystemCommentCount { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("System.Title")]
|
||||
public string SystemTitle { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("Microsoft.VSTS.Common.StateChangeDate")]
|
||||
public DateTime MicrosoftVSTSCommonStateChangeDate { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("Microsoft.VSTS.Common.Priority")]
|
||||
public int MicrosoftVSTSCommonPriority { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("System.Description")]
|
||||
public string SystemDescription { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("System.Tags")]
|
||||
public string SystemTags { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("System.History")]
|
||||
public string SystemHistory { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("Microsoft.VSTS.Scheduling.Effort")]
|
||||
public float? Effort { get; } // { init; get; }
|
||||
|
||||
[JsonPropertyName("Microsoft.VSTS.Scheduling.TargetDate")]
|
||||
public DateTime TargetDate { get; } // { init; get; }
|
||||
}
|
88
Adaptation/FileHandlers/json/WorkItems/WorkItem.cs
Normal file
88
Adaptation/FileHandlers/json/WorkItems/WorkItem.cs
Normal file
@ -0,0 +1,88 @@
|
||||
using System;
|
||||
using System.Text.Json.Serialization;
|
||||
|
||||
namespace Adaptation.FileHandlers.json.WorkItems;
|
||||
|
||||
public class WorkItem
|
||||
{
|
||||
|
||||
#nullable enable
|
||||
|
||||
[JsonConstructor]
|
||||
public WorkItem(string areaPath,
|
||||
string? assignedTo,
|
||||
int? businessValue,
|
||||
DateTime changedDate,
|
||||
DateTime? closedDate,
|
||||
int commentCount,
|
||||
DateTime createdDate,
|
||||
string description,
|
||||
float? effort,
|
||||
int id,
|
||||
string iterationPath,
|
||||
int? priority,
|
||||
string? requester,
|
||||
DateTime? resolvedDate,
|
||||
int revision,
|
||||
int? riskReductionMinusOpportunityEnablement,
|
||||
DateTime? startDate,
|
||||
string state,
|
||||
string tags,
|
||||
DateTime? targetDate,
|
||||
float? timeCriticality,
|
||||
string title,
|
||||
string workItemType,
|
||||
float? weightedShortestJobFirst)
|
||||
{
|
||||
AreaPath = areaPath;
|
||||
AssignedTo = assignedTo;
|
||||
BusinessValue = businessValue;
|
||||
ChangedDate = changedDate;
|
||||
ClosedDate = closedDate;
|
||||
CommentCount = commentCount;
|
||||
CreatedDate = createdDate;
|
||||
Description = description;
|
||||
Effort = effort;
|
||||
Id = id;
|
||||
IterationPath = iterationPath;
|
||||
Priority = priority;
|
||||
Requester = requester;
|
||||
ResolvedDate = resolvedDate;
|
||||
Revision = revision;
|
||||
RiskReductionMinusOpportunityEnablement = riskReductionMinusOpportunityEnablement;
|
||||
StartDate = startDate;
|
||||
State = state;
|
||||
Tags = tags;
|
||||
TargetDate = targetDate;
|
||||
TimeCriticality = timeCriticality;
|
||||
Title = title;
|
||||
WorkItemType = workItemType;
|
||||
WeightedShortestJobFirst = weightedShortestJobFirst;
|
||||
}
|
||||
|
||||
public string AreaPath { get; set; } // { init; get; }
|
||||
public string? AssignedTo { get; set; } // { init; get; }
|
||||
public int? BusinessValue { get; set; } // { init; get; }
|
||||
public DateTime ChangedDate { get; set; } // { init; get; }
|
||||
public DateTime? ClosedDate { get; set; } // { init; get; }
|
||||
public int CommentCount { get; set; } // { init; get; }
|
||||
public DateTime CreatedDate { get; set; } // { init; get; }
|
||||
public string Description { get; set; } // { init; get; }
|
||||
public float? Effort { get; set; } // { init; get; }
|
||||
public int Id { get; set; } // { init; get; }
|
||||
public string IterationPath { get; set; } // { init; get; }
|
||||
public int? Priority { get; set; } // { init; get; }
|
||||
public string? Requester { get; set; } // { init; get; }
|
||||
public DateTime? ResolvedDate { get; set; } // { init; get; }
|
||||
public int Revision { get; set; } // { init; get; }
|
||||
public int? RiskReductionMinusOpportunityEnablement { get; set; } // { init; get; }
|
||||
public DateTime? StartDate { get; set; } // { init; get; }
|
||||
public string State { get; set; } // { init; get; }
|
||||
public string Tags { get; set; } // { init; get; }
|
||||
public DateTime? TargetDate { get; set; } // { init; get; }
|
||||
public float? TimeCriticality { get; set; } // { init; get; }
|
||||
public string Title { get; set; } // { init; get; }
|
||||
public string WorkItemType { get; set; } // { init; get; }
|
||||
public float? WeightedShortestJobFirst { get; set; } // { init; get; }
|
||||
|
||||
}
|
Reference in New Issue
Block a user