终端一体化运控平台
Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.
 
 
 

319 rader
11 KiB

  1. <UserControl
  2. x:Class="BPASmartClient.DosingSystem.View.HardwareStatusView"
  3. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  4. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  5. xmlns:control="clr-namespace:BPASmartClient.CustomResource.UserControls;assembly=BPASmartClient.CustomResource"
  6. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  7. xmlns:local="clr-namespace:BPASmartClient.DosingSystem.View"
  8. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  9. xmlns:pry="clr-namespace:BPASmartClient.CustomResource.UserControls;assembly=BPASmartClient.CustomResource"
  10. xmlns:vm="clr-namespace:BPASmartClient.DosingSystem.ViewModel"
  11. d:DesignHeight="1080"
  12. d:DesignWidth="1920"
  13. mc:Ignorable="d">
  14. <UserControl.DataContext>
  15. <vm:HardwareStatusViewModel />
  16. </UserControl.DataContext>
  17. <Grid>
  18. <!--#region 测试-->
  19. <ListView
  20. Height="150"
  21. VerticalAlignment="Center"
  22. Background="Transparent"
  23. BorderThickness="0"
  24. ItemsSource="{Binding TopDeviceCurrentStatuses}"
  25. ScrollViewer.HorizontalScrollBarVisibility="Disabled">
  26. <ListView.ItemsPanel>
  27. <ItemsPanelTemplate>
  28. <UniformGrid
  29. HorizontalAlignment="Center"
  30. VerticalAlignment="Center"
  31. Columns="10" />
  32. </ItemsPanelTemplate>
  33. </ListView.ItemsPanel>
  34. <ListView.ItemTemplate>
  35. <DataTemplate>
  36. <Border Background="Transparent">
  37. <Grid Height="100">
  38. <pry:MotorBottle
  39. Height="100"
  40. CurrentValue="{Binding Weight}"
  41. IsRun="{Binding RunStatus}"
  42. RenderTransformOrigin="0.5,0.5">
  43. <pry:MotorBottle.RenderTransform>
  44. <TransformGroup>
  45. <RotateTransform Angle="90" />
  46. </TransformGroup>
  47. </pry:MotorBottle.RenderTransform>
  48. </pry:MotorBottle>
  49. </Grid>
  50. </Border>
  51. </DataTemplate>
  52. </ListView.ItemTemplate>
  53. </ListView>
  54. <!--#endregion-->
  55. <UniformGrid Columns="10" Visibility="Collapsed">
  56. <pry:MotorBottle
  57. Width="150"
  58. Height="100"
  59. CurrentValue="66"
  60. IsRun="True"
  61. RenderTransformOrigin="0.5,0.5">
  62. <pry:MotorBottle.RenderTransform>
  63. <TransformGroup>
  64. <RotateTransform Angle="90" />
  65. </TransformGroup>
  66. </pry:MotorBottle.RenderTransform>
  67. </pry:MotorBottle>
  68. <pry:MotorBottle
  69. Width="150"
  70. Height="100"
  71. CurrentValue="40"
  72. IsRun="True"
  73. RenderTransformOrigin="0.5,0.5">
  74. <pry:MotorBottle.RenderTransform>
  75. <TransformGroup>
  76. <RotateTransform Angle="90" />
  77. </TransformGroup>
  78. </pry:MotorBottle.RenderTransform>
  79. </pry:MotorBottle>
  80. <pry:MotorBottle
  81. Width="150"
  82. Height="100"
  83. CurrentValue="88"
  84. IsRun="True"
  85. RenderTransformOrigin="0.5,0.5">
  86. <pry:MotorBottle.RenderTransform>
  87. <TransformGroup>
  88. <RotateTransform Angle="90" />
  89. </TransformGroup>
  90. </pry:MotorBottle.RenderTransform>
  91. </pry:MotorBottle>
  92. <pry:MotorBottle
  93. Width="150"
  94. Height="100"
  95. CurrentValue="25"
  96. IsRun="True"
  97. RenderTransformOrigin="0.5,0.5">
  98. <pry:MotorBottle.RenderTransform>
  99. <TransformGroup>
  100. <RotateTransform Angle="90" />
  101. </TransformGroup>
  102. </pry:MotorBottle.RenderTransform>
  103. </pry:MotorBottle>
  104. <pry:MotorBottle
  105. Width="150"
  106. Height="100"
  107. CurrentValue="97"
  108. IsRun="True"
  109. RenderTransformOrigin="0.5,0.5">
  110. <pry:MotorBottle.RenderTransform>
  111. <TransformGroup>
  112. <RotateTransform Angle="90" />
  113. </TransformGroup>
  114. </pry:MotorBottle.RenderTransform>
  115. </pry:MotorBottle>
  116. <pry:MotorBottle
  117. Width="150"
  118. Height="100"
  119. CurrentValue="10"
  120. IsRun="True"
  121. RenderTransformOrigin="0.5,0.5">
  122. <pry:MotorBottle.RenderTransform>
  123. <TransformGroup>
  124. <RotateTransform Angle="90" />
  125. </TransformGroup>
  126. </pry:MotorBottle.RenderTransform>
  127. </pry:MotorBottle>
  128. <pry:MotorBottle
  129. Width="150"
  130. Height="100"
  131. CurrentValue="60"
  132. IsRun="True"
  133. RenderTransformOrigin="0.5,0.5">
  134. <pry:MotorBottle.RenderTransform>
  135. <TransformGroup>
  136. <RotateTransform Angle="90" />
  137. </TransformGroup>
  138. </pry:MotorBottle.RenderTransform>
  139. </pry:MotorBottle>
  140. <pry:MotorBottle
  141. Width="150"
  142. Height="100"
  143. CurrentValue="96"
  144. IsRun="True"
  145. RenderTransformOrigin="0.5,0.5">
  146. <pry:MotorBottle.RenderTransform>
  147. <TransformGroup>
  148. <RotateTransform Angle="90" />
  149. </TransformGroup>
  150. </pry:MotorBottle.RenderTransform>
  151. </pry:MotorBottle>
  152. </UniformGrid>
  153. <Grid x:Name="gr" Grid.Row="1">
  154. <pry:ConveyorBelt
  155. Grid.Row="1"
  156. Width="{Binding ElementName=gr, Path=ActualWidth}"
  157. Height="{Binding ElementName=gr, Path=ActualHeight}"
  158. Margin="10,0,400,0"
  159. ConveyorBeltWidth="70"
  160. Direction="1"
  161. StrokeBrush="#00BEFA"
  162. StrokeDashArray="1.5 1.5"
  163. StrokeFillBrush="#00BEFA"
  164. StrokeThickness="2" />
  165. <!--<pry:Pipeline CapRadius="30" Height="30"/>-->
  166. </Grid>
  167. <UniformGrid Grid.Row="2" Columns="10">
  168. <pry:MotorBottle
  169. Width="150"
  170. Height="100"
  171. CurrentValue="89"
  172. IsRun="True"
  173. RenderTransformOrigin="0.5,0.5">
  174. <pry:MotorBottle.RenderTransform>
  175. <TransformGroup>
  176. <RotateTransform Angle="270" />
  177. <ScaleTransform ScaleX="-1" />
  178. </TransformGroup>
  179. </pry:MotorBottle.RenderTransform>
  180. </pry:MotorBottle>
  181. <pry:MotorBottle
  182. Width="150"
  183. Height="100"
  184. CurrentValue="13"
  185. IsRun="True"
  186. RenderTransformOrigin="0.5,0.5">
  187. <pry:MotorBottle.RenderTransform>
  188. <TransformGroup>
  189. <RotateTransform Angle="270" />
  190. <ScaleTransform ScaleX="-1" />
  191. </TransformGroup>
  192. </pry:MotorBottle.RenderTransform>
  193. </pry:MotorBottle>
  194. <pry:MotorBottle
  195. Width="150"
  196. Height="100"
  197. CurrentValue="31"
  198. IsRun="True"
  199. RenderTransformOrigin="0.5,0.5">
  200. <pry:MotorBottle.RenderTransform>
  201. <TransformGroup>
  202. <RotateTransform Angle="270" />
  203. <ScaleTransform ScaleX="-1" />
  204. </TransformGroup>
  205. </pry:MotorBottle.RenderTransform>
  206. </pry:MotorBottle>
  207. <pry:MotorBottle
  208. Width="150"
  209. Height="100"
  210. CurrentValue="96"
  211. IsRun="True"
  212. RenderTransformOrigin="0.5,0.5">
  213. <pry:MotorBottle.RenderTransform>
  214. <TransformGroup>
  215. <RotateTransform Angle="270" />
  216. <ScaleTransform ScaleX="-1" />
  217. </TransformGroup>
  218. </pry:MotorBottle.RenderTransform>
  219. </pry:MotorBottle>
  220. <pry:MotorBottle
  221. Width="150"
  222. Height="100"
  223. CurrentValue="80"
  224. IsRun="True"
  225. RenderTransformOrigin="0.5,0.5">
  226. <pry:MotorBottle.RenderTransform>
  227. <TransformGroup>
  228. <RotateTransform Angle="270" />
  229. <ScaleTransform ScaleX="-1" />
  230. </TransformGroup>
  231. </pry:MotorBottle.RenderTransform>
  232. </pry:MotorBottle>
  233. <pry:MotorBottle
  234. Width="150"
  235. Height="100"
  236. CurrentValue="26"
  237. IsRun="True"
  238. RenderTransformOrigin="0.5,0.5">
  239. <pry:MotorBottle.RenderTransform>
  240. <TransformGroup>
  241. <RotateTransform Angle="270" />
  242. <ScaleTransform ScaleX="-1" />
  243. </TransformGroup>
  244. </pry:MotorBottle.RenderTransform>
  245. </pry:MotorBottle>
  246. <pry:MotorBottle
  247. Width="150"
  248. Height="100"
  249. CurrentValue="20"
  250. IsRun="True"
  251. RenderTransformOrigin="0.5,0.5">
  252. <pry:MotorBottle.RenderTransform>
  253. <TransformGroup>
  254. <RotateTransform Angle="270" />
  255. <ScaleTransform ScaleX="-1" />
  256. </TransformGroup>
  257. </pry:MotorBottle.RenderTransform>
  258. </pry:MotorBottle>
  259. <pry:MotorBottle
  260. Width="150"
  261. Height="100"
  262. CurrentValue="100"
  263. IsRun="True"
  264. RenderTransformOrigin="0.5,0.5">
  265. <pry:MotorBottle.RenderTransform>
  266. <TransformGroup>
  267. <RotateTransform Angle="270" />
  268. <ScaleTransform ScaleX="-1" />
  269. </TransformGroup>
  270. </pry:MotorBottle.RenderTransform>
  271. </pry:MotorBottle>
  272. </UniformGrid>
  273. <Grid.RowDefinitions>
  274. <RowDefinition Height="0.5*" />
  275. <RowDefinition />
  276. <RowDefinition Height="0.5*" />
  277. </Grid.RowDefinitions>
  278. </Grid>
  279. </UserControl>