|
@@ -8,7 +8,7 @@ using System.Text;
|
|
|
|
|
|
|
|
namespace PRSClasses
|
|
namespace PRSClasses
|
|
|
{
|
|
{
|
|
|
- public class DFLayoutAddTaskFieldProperties : DFLayoutFieldProperties<int?>
|
|
|
|
|
|
|
+ public class DFLayoutAddTaskFieldProperties : DFLayoutFieldProperties<int?, int?>
|
|
|
{
|
|
{
|
|
|
public KanbanTypeLink TaskType { get; set; }
|
|
public KanbanTypeLink TaskType { get; set; }
|
|
|
|
|
|
|
@@ -30,18 +30,24 @@ namespace PRSClasses
|
|
|
SetProperty("TaskType", TaskType.ID);
|
|
SetProperty("TaskType", TaskType.ID);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- public override string FormatValue(object value)
|
|
|
|
|
|
|
+ public override int? DeserializeValue(DFLoadStorageEntry entry)
|
|
|
{
|
|
{
|
|
|
- return string.Format("{0}", value);
|
|
|
|
|
|
|
+ return entry.GetValue<int?>();
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ public override void SerializeValue(DFSaveStorageEntry entry, int? value)
|
|
|
|
|
+ {
|
|
|
|
|
+ entry.SetValue(value);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- public override object? ParseValue(object value)
|
|
|
|
|
|
|
+ public override int? GetValue(int? value)
|
|
|
{
|
|
{
|
|
|
- if (value is int)
|
|
|
|
|
- return value;
|
|
|
|
|
- if (int.TryParse(value as string, out var result))
|
|
|
|
|
- return result;
|
|
|
|
|
- return null;
|
|
|
|
|
|
|
+ return value;
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ public override string FormatValue(object? value)
|
|
|
|
|
+ {
|
|
|
|
|
+ return string.Format("{0}", value);
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|