EquipmentSetupActions.cs 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. using Comal.Classes;
  2. using InABox.DynamicGrid;
  3. using InABox.Wpf;
  4. using System.Collections.Generic;
  5. using System.Linq;
  6. using System.Text;
  7. using System.Threading.Tasks;
  8. namespace PRSDesktop;
  9. public static class EquipmentSetupActions
  10. {
  11. public static void TrackerTypes(IPanelHost host)
  12. {
  13. host.CreateSetupActionIfCanView<GPSTrackerType>("Tracker Types", PRSDesktop.Resources.milestone, TrackerTypes_Click);
  14. }
  15. private static void TrackerTypes_Click(PanelAction action)
  16. {
  17. var list = new MasterList(typeof(GPSTrackerType));
  18. list.ShowDialog();
  19. }
  20. public static void WebStickers(IPanelHost host)
  21. {
  22. host.CreateSetupActionIfCanView<WebSticker>("Stickers", PRSDesktop.Resources.barcode, Stickers_Click);
  23. }
  24. private static void Stickers_Click(PanelAction action)
  25. {
  26. var list = new MasterList(typeof(WebSticker));
  27. list.ShowDialog();
  28. }
  29. public static void DigitalKeys(IPanelHost host)
  30. {
  31. host.CreateSetupActionIfCanView<DigitalKey>("Digital Keys", PRSDesktop.Resources.key, DigitalKeys_Click);
  32. }
  33. private static void DigitalKeys_Click(PanelAction action)
  34. {
  35. var list = new MasterList(typeof(DigitalKey));
  36. list.ShowDialog();
  37. }
  38. public static void EquipmentGroups(IPanelHost host)
  39. {
  40. host.CreateSetupActionIfCanView<EquipmentGroup>("Equipment Groups", PRSDesktop.Resources.specifications, EquipmentGroupList_Click);
  41. }
  42. private static void EquipmentGroupList_Click(PanelAction action)
  43. {
  44. var list = new MasterList(typeof(EquipmentGroup));
  45. list.ShowDialog();
  46. }
  47. }