StockSummaryPanel.cs 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. using System;
  2. using System.Collections.Generic;
  3. using Comal.Classes;
  4. using InABox.Configuration;
  5. using InABox.Core;
  6. using InABox.Wpf;
  7. namespace PRSDesktop;
  8. public class StockSummaryPanel : StockSummaryControl, IPanel<JobMaterial>, IPropertiesPanel<StockSummaryPanelSettings, CanConfigureProductsPanels>
  9. {
  10. public StockSummaryPanel()
  11. {
  12. SectionName = nameof(StockSummaryPanel);
  13. LoadSettings += (sender) => new UserConfiguration<StockSummaryProperties>(SectionName).Load();
  14. SaveSettings += (sender, properties) => new UserConfiguration<StockSummaryProperties>(SectionName).Save(properties);
  15. }
  16. public bool IsReady { get; set; }
  17. public void CreateToolbarButtons(IPanelHost host)
  18. {
  19. ProductSetupActions.Standard(host);
  20. }
  21. public Dictionary<string, object[]> Selected()
  22. {
  23. return new Dictionary<string, object[]>();
  24. }
  25. public void Heartbeat(TimeSpan time)
  26. {
  27. }
  28. public string SectionName { get; }
  29. StockSummaryPanelSettings IPropertiesPanel<StockSummaryPanelSettings>.Properties { get; set; }
  30. public DataModel DataModel(Selection selection)
  31. {
  32. //throw new NotImplementedException();
  33. return new AutoDataModel<JobMaterial>(null);
  34. }
  35. public event DataModelUpdateEvent? OnUpdateDataModel;
  36. }