StockForecastControl.xaml 6.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129
  1. <UserControl x:Class="PRSDesktop.StockForecastControl"
  2. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  3. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  4. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  5. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  6. xmlns:local="clr-namespace:PRSDesktop"
  7. xmlns:stk="clr-namespace:PRSDesktop.Panels.StockForecast"
  8. xmlns:dynamicGrid="clr-namespace:InABox.DynamicGrid;assembly=InABox.Wpf"
  9. mc:Ignorable="d"
  10. d:DesignHeight="900" d:DesignWidth="1000">
  11. <dynamicGrid:DynamicSplitPanel x:Name="SplitPanel"
  12. MasterCaption="Product Groups" DetailCaption="Stock Forecast"
  13. View="Combined" AllowableViews="Combined, Detail"
  14. Anchor="Master" AnchorWidth="350"
  15. OnChanged="SplitPanel_OnOnChanged">
  16. <dynamicGrid:DynamicSplitPanel.Header>
  17. <Border BorderBrush="Gray" BorderThickness="0.75" Background="WhiteSmoke">
  18. <Label Content="Product Groups" HorizontalContentAlignment="Center"/>
  19. </Border>
  20. </dynamicGrid:DynamicSplitPanel.Header>
  21. <dynamicGrid:DynamicSplitPanel.Master>
  22. <local:StockForecastProductGroupTree x:Name="ProductGroups"
  23. SelectionChanged="ProductGroups_GroupSelectionChanged"
  24. AfterRefresh="ProductGroups_AfterRefresh"/>
  25. </dynamicGrid:DynamicSplitPanel.Master>
  26. <dynamicGrid:DynamicSplitPanel.Detail>
  27. <dynamicGrid:DynamicSplitPanel x:Name="DetailSplitPanel"
  28. DetailCaption="Suppliers"
  29. View="Combined" AllowableViews="Master,Combined"
  30. Anchor="Detail" AnchorWidth="300" DetailHeight="500"
  31. OnChanged="DetailSplitPanel_OnChanged">
  32. <dynamicGrid:DynamicSplitPanel.Header>
  33. <Border BorderBrush="Gray" BorderThickness="0.75" Background="WhiteSmoke">
  34. <DockPanel>
  35. <CheckBox
  36. x:Name="Optimise"
  37. DockPanel.Dock="Right"
  38. VerticalContentAlignment="Center"
  39. Content="Optimise"
  40. Margin="5,0"
  41. Checked="Optimise_Checked"
  42. Unchecked="Optimise_Checked"/>
  43. <CheckBox
  44. x:Name="RequiredOnly"
  45. DockPanel.Dock="Right"
  46. VerticalContentAlignment="Center"
  47. Content="Required Only"
  48. Margin="5,0"
  49. Checked="RequiredOnly_Checked"
  50. Unchecked="RequiredOnly_Checked"/>
  51. <Label Content="Stock Forecast" HorizontalContentAlignment="Center"/>
  52. </DockPanel>
  53. </Border>
  54. </dynamicGrid:DynamicSplitPanel.Header>
  55. <dynamicGrid:DynamicSplitPanel.Master>
  56. <local:StockForecastGrid x:Name="StockForecastGrid" BeforeRefresh="StockForecastGrid_OnBeforeRefresh" AfterRefresh="StockForecastGrid_OnAfterRefresh" />
  57. </dynamicGrid:DynamicSplitPanel.Master>
  58. <dynamicGrid:DynamicSplitPanel.Detail>
  59. <Grid>
  60. <Grid.RowDefinitions>
  61. <RowDefinition Height="Auto"/>
  62. <RowDefinition Height="*"/>
  63. </Grid.RowDefinitions>
  64. <Border BorderBrush="Gray" BorderThickness="0.75"
  65. Grid.Row="0" Margin="0,0,0,4" Background="WhiteSmoke">
  66. <DockPanel>
  67. <CheckBox
  68. x:Name="AllStock"
  69. DockPanel.Dock="Right"
  70. VerticalContentAlignment="Center"
  71. Content="Show All"
  72. Margin="5,0"
  73. Checked="AllStock_Checked"
  74. Unchecked="AllStock_Checked"
  75. />
  76. <Label
  77. Content="Suppliers"
  78. HorizontalContentAlignment="Center"
  79. DockPanel.Dock="Left"/>
  80. </DockPanel>
  81. </Border>
  82. <stk:StockForecastSupplierGrid x:Name="SupplierGrid"
  83. Grid.Row="1"
  84. SelectionChanged="SupplierGrid_SelectionChanged"/>
  85. </Grid>
  86. </dynamicGrid:DynamicSplitPanel.Detail>
  87. <dynamicGrid:DynamicSplitPanel.SecondaryDetail>
  88. <Grid>
  89. <Grid.RowDefinitions>
  90. <RowDefinition Height="Auto"/>
  91. <RowDefinition Height="*"/>
  92. </Grid.RowDefinitions>
  93. <Border
  94. BorderBrush="Gray"
  95. BorderThickness="0.75"
  96. Grid.Row="0"
  97. Margin="0,0,0,4"
  98. Background="WhiteSmoke">
  99. <Label Content="Jobs" HorizontalContentAlignment="Center"
  100. DockPanel.Dock="Left"/>
  101. </Border>
  102. <stk:StockForecastJobGrid
  103. x:Name="JobGrid"
  104. Grid.Row="1"
  105. SelectionChanged="JobGrid_SelectionChanged"/>
  106. </Grid>
  107. </dynamicGrid:DynamicSplitPanel.SecondaryDetail>
  108. </dynamicGrid:DynamicSplitPanel>
  109. </dynamicGrid:DynamicSplitPanel.Detail>
  110. </dynamicGrid:DynamicSplitPanel>
  111. </UserControl>