DFLayoutAddTaskFieldProperties.cs 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. using Comal.Classes;
  2. using InABox.Clients;
  3. using InABox.Core;
  4. using System;
  5. using System.Collections.Generic;
  6. using System.Linq;
  7. using System.Text;
  8. namespace PRSClasses
  9. {
  10. public class DFLayoutAddTaskFieldProperties : DFLayoutFieldProperties<string?, string?>
  11. {
  12. public KanbanTypeLink TaskType { get; set; }
  13. protected override void LoadProperties()
  14. {
  15. base.LoadProperties();
  16. TaskType.ID = GetProperty("TaskType", Guid.Empty);
  17. }
  18. protected override void SaveProperties()
  19. {
  20. base.SaveProperties();
  21. SetProperty("TaskType", TaskType.ID);
  22. }
  23. public override string? DeserializeValue(DFLoadStorageEntry entry)
  24. {
  25. return entry.GetValue<string>();
  26. }
  27. public override void SerializeValue(DFSaveStorageEntry entry, string? value)
  28. {
  29. entry.SetValue(value);
  30. }
  31. public override string? GetValue(string? value)
  32. {
  33. return value;
  34. }
  35. public override string FormatValue(string? value)
  36. {
  37. return string.Format("{0}", value);
  38. }
  39. }
  40. }