You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

708 lines
36 KiB

  1. <UserControl
  2. x:Class="HBLConsole.Debug.Debug_MORKIC"
  3. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  4. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  5. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  6. xmlns:local="clr-namespace:HBLConsole.Debug"
  7. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  8. xmlns:s="https://github.com/canton7/Stylet"
  9. d:DesignHeight="450"
  10. d:DesignWidth="800"
  11. mc:Ignorable="d">
  12. <UserControl.DataContext>
  13. <local:ViewModel_MORKIC x:Name="vmode" />
  14. </UserControl.DataContext>
  15. <UserControl.Resources>
  16. <ResourceDictionary>
  17. <ResourceDictionary.MergedDictionaries>
  18. <ResourceDictionary Source="Style.xaml" />
  19. <ResourceDictionary>
  20. <!--#region ComboBox 样式-->
  21. <!-- ComBoBox项选中背景色 -->
  22. <SolidColorBrush x:Key="ComboBoxSelectdBackground" Color="#AA3ba7f2" />
  23. <!-- ComBoBox项鼠标经过背景色 -->
  24. <SolidColorBrush x:Key="ComboBoxMouseOverBackground" Color="#553ba7f2" />
  25. <!-- ComBoBox项选中前景色 -->
  26. <SolidColorBrush x:Key="ComboBoxSelectedForeground" Color="#DDD" />
  27. <!-- ComBoBox项鼠标经过前景色 -->
  28. <SolidColorBrush x:Key="ComboBoxMouseOverForegrond" Color="#DDD" />
  29. <ControlTemplate x:Key="ComboBoxToggleButton" TargetType="{x:Type ToggleButton}">
  30. <Grid Height="25" HorizontalAlignment="Stretch">
  31. <Grid.ColumnDefinitions>
  32. <ColumnDefinition Width="*" />
  33. <ColumnDefinition Width="30" />
  34. </Grid.ColumnDefinitions>
  35. <Border
  36. Grid.ColumnSpan="2"
  37. Background="White"
  38. Opacity="0" />
  39. <TextBlock
  40. Grid.Column="1"
  41. Margin="0,0,5,0"
  42. HorizontalAlignment="Right"
  43. VerticalAlignment="Center"
  44. FontFamily="../Fonts/#iconfont"
  45. FontSize="14"
  46. Foreground="#FF23CACA"
  47. Text="&#xe64d;" />
  48. <!--<Path
  49. x:Name="Arrow"
  50. Grid.Column="1"
  51. HorizontalAlignment="Center"
  52. VerticalAlignment="Center"
  53. Data="M 0 0 6 6 12 0 Z"
  54. Fill="#aa20FDFA"
  55. Stretch="None">
  56. <Path.Effect>
  57. <DropShadowEffect
  58. BlurRadius="10"
  59. Direction="90"
  60. Opacity="1"
  61. RenderingBias="Quality"
  62. ShadowDepth="0"
  63. Color="#aa20FDFA" />
  64. </Path.Effect>
  65. </Path>-->
  66. </Grid>
  67. <!--<ControlTemplate.Triggers>
  68. <Trigger Property="IsChecked" Value="true">
  69. <Setter TargetName="Arrow" Property="RenderTransform">
  70. <Setter.Value>
  71. <RotateTransform Angle="180" CenterX="6" CenterY="3" />
  72. </Setter.Value>
  73. </Setter>
  74. <Setter TargetName="Arrow" Property="Margin" Value="0,0,0,2" />
  75. </Trigger>
  76. </ControlTemplate.Triggers>-->
  77. </ControlTemplate>
  78. <!--#region 按钮样式-->
  79. <Style x:Key="ButtonStyle" TargetType="Button">
  80. <Setter Property="Foreground" Value="#00c2f4" />
  81. <Setter Property="FontSize" Value="18" />
  82. <Setter Property="Width" Value="100" />
  83. <Setter Property="Template">
  84. <Setter.Value>
  85. <ControlTemplate TargetType="Button">
  86. <Border
  87. Name="TitleBarBr"
  88. Background="Transparent"
  89. BorderBrush="#00c2f4"
  90. BorderThickness="2"
  91. CornerRadius="10">
  92. <ContentPresenter
  93. Margin="{TemplateBinding Margin}"
  94. HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
  95. VerticalAlignment="{TemplateBinding VerticalContentAlignment}" />
  96. </Border>
  97. <ControlTemplate.Triggers>
  98. <Trigger Property="IsMouseOver" Value="true">
  99. <Setter TargetName="TitleBarBr" Property="Background" Value="#3300c2f4" />
  100. </Trigger>
  101. </ControlTemplate.Triggers>
  102. </ControlTemplate>
  103. </Setter.Value>
  104. </Setter>
  105. </Style>
  106. <Style x:Key="ComboBoxStyle" TargetType="{x:Type ComboBox}">
  107. <Setter Property="BorderThickness" Value="0" />
  108. <Setter Property="ItemContainerStyle">
  109. <Setter.Value>
  110. <Style TargetType="ComboBoxItem">
  111. <Setter Property="Height" Value="25" />
  112. <Setter Property="Template">
  113. <Setter.Value>
  114. <ControlTemplate TargetType="{x:Type ComboBoxItem}">
  115. <Grid Width="{TemplateBinding Width}" Height="{TemplateBinding Height}">
  116. <Border x:Name="_borderbg" Background="Transparent" />
  117. <TextBlock
  118. x:Name="_txt"
  119. Margin="3,0,3,0"
  120. HorizontalAlignment="Center"
  121. VerticalAlignment="Center"
  122. Foreground="#DDD"
  123. Text="{Binding Content, RelativeSource={RelativeSource TemplatedParent}}" />
  124. <Border
  125. x:Name="_border"
  126. Background="#103153"
  127. Opacity="0" />
  128. </Grid>
  129. <ControlTemplate.Triggers>
  130. <Trigger Property="IsSelected" Value="true">
  131. <Setter TargetName="_txt" Property="Foreground" Value="{StaticResource ComboBoxSelectedForeground}" />
  132. <Setter TargetName="_borderbg" Property="Background" Value="{StaticResource ComboBoxSelectdBackground}" />
  133. </Trigger>
  134. <MultiTrigger>
  135. <MultiTrigger.Conditions>
  136. <Condition Property="IsSelected" Value="false" />
  137. <Condition Property="IsMouseOver" Value="true" />
  138. </MultiTrigger.Conditions>
  139. <Setter TargetName="_borderbg" Property="Background" Value="{StaticResource ComboBoxMouseOverBackground}" />
  140. <Setter TargetName="_txt" Property="Foreground" Value="{StaticResource ComboBoxMouseOverForegrond}" />
  141. </MultiTrigger>
  142. </ControlTemplate.Triggers>
  143. </ControlTemplate>
  144. </Setter.Value>
  145. </Setter>
  146. </Style>
  147. </Setter.Value>
  148. </Setter>
  149. <Setter Property="Template">
  150. <Setter.Value>
  151. <ControlTemplate TargetType="{x:Type ComboBox}">
  152. <Grid>
  153. <Grid.ColumnDefinitions>
  154. <ColumnDefinition Width="0.7*" />
  155. <ColumnDefinition Width="0.3*" MaxWidth="30" />
  156. </Grid.ColumnDefinitions>
  157. <Border
  158. x:Name="_prybr"
  159. Grid.Column="0"
  160. Grid.ColumnSpan="2"
  161. BorderBrush="{TemplateBinding BorderBrush}"
  162. BorderThickness="{TemplateBinding BorderThickness}"
  163. CornerRadius="0" />
  164. <ContentPresenter
  165. x:Name="ContentSite"
  166. Margin="3,3,0,3"
  167. HorizontalAlignment="Center"
  168. VerticalAlignment="Center"
  169. Content="{TemplateBinding SelectionBoxItem}"
  170. ContentTemplate="{TemplateBinding SelectionBoxItemTemplate}"
  171. ContentTemplateSelector="{TemplateBinding ItemTemplateSelector}"
  172. IsHitTestVisible="False" />
  173. <!-- ToggleButton 已数据绑定到 ComboBox 本身以切换 IsDropDownOpen -->
  174. <ToggleButton
  175. x:Name="ToggleButton"
  176. Grid.Column="0"
  177. Grid.ColumnSpan="2"
  178. ClickMode="Press"
  179. Focusable="false"
  180. IsChecked="{Binding Path=IsDropDownOpen, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}"
  181. Template="{StaticResource ComboBoxToggleButton}" />
  182. <!-- 必须将 TextBox 命名为 PART_EditableTextBox,否则 ComboBox 将无法识别它 -->
  183. <TextBox
  184. x:Name="PART_EditableTextBox"
  185. Margin="2,0,0,0"
  186. VerticalAlignment="Center"
  187. Background="Transparent"
  188. BorderThickness="0"
  189. Focusable="True"
  190. IsReadOnly="{TemplateBinding IsReadOnly}"
  191. Visibility="Hidden" />
  192. <!-- Popup 可显示 ComboBox 中的项列表。IsOpen 已数据绑定到通过 ComboBoxToggleButton 来切换的 IsDropDownOpen -->
  193. <Popup
  194. x:Name="Popup"
  195. AllowsTransparency="True"
  196. Focusable="False"
  197. IsOpen="{TemplateBinding IsDropDownOpen}"
  198. Placement="Bottom"
  199. PopupAnimation="Slide">
  200. <Grid
  201. x:Name="DropDown"
  202. MinWidth="{TemplateBinding ActualWidth}"
  203. MaxHeight="150"
  204. SnapsToDevicePixels="True">
  205. <Border
  206. x:Name="DropDownBorder"
  207. BorderBrush="#3ba7f2"
  208. BorderThickness="0" />
  209. <ScrollViewer
  210. Margin="1"
  211. CanContentScroll="True"
  212. HorizontalScrollBarVisibility="Auto"
  213. SnapsToDevicePixels="True"
  214. VerticalScrollBarVisibility="Auto">
  215. <!-- StackPanel 用于显示子级,方法是将 IsItemsHost 设置为 True -->
  216. <!-- 一下可以设置列表背景色 -->
  217. <StackPanel
  218. Background="#103153"
  219. IsItemsHost="True"
  220. KeyboardNavigation.DirectionalNavigation="Contained" />
  221. </ScrollViewer>
  222. </Grid>
  223. </Popup>
  224. </Grid>
  225. <ControlTemplate.Triggers>
  226. <Trigger Property="IsEditable" Value="true">
  227. <Setter TargetName="PART_EditableTextBox" Property="Visibility" Value="Visible" />
  228. </Trigger>
  229. <Trigger Property="IsMouseOver" Value="True">
  230. <Setter TargetName="_prybr" Property="BorderBrush" Value="#aa3ba7f2" />
  231. <!--<Setter Property="Background" Value="#553ba7f2" TargetName="_prybr"/>-->
  232. </Trigger>
  233. </ControlTemplate.Triggers>
  234. </ControlTemplate>
  235. </Setter.Value>
  236. </Setter>
  237. </Style>
  238. <!--#endregion-->
  239. </ResourceDictionary>
  240. </ResourceDictionary.MergedDictionaries>
  241. </ResourceDictionary>
  242. </UserControl.Resources>
  243. <Grid>
  244. <Grid.Resources>
  245. <Style TargetType="TextBlock">
  246. <Setter Property="HorizontalAlignment" Value="Left" />
  247. <Setter Property="VerticalAlignment" Value="Center" />
  248. </Style>
  249. </Grid.Resources>
  250. <Grid.RowDefinitions>
  251. <RowDefinition />
  252. <RowDefinition />
  253. </Grid.RowDefinitions>
  254. <!--#region 乐百机器人控制-->
  255. <GroupBox
  256. BorderBrush="#3aa7f3"
  257. BorderThickness="2"
  258. FontFamily="楷体"
  259. FontSize="20"
  260. Foreground="Aqua"
  261. Header=" 乐百机器人控制 "
  262. Style="{DynamicResource GroupBoxStyle1}">
  263. <Grid>
  264. <Grid.RowDefinitions>
  265. <RowDefinition Height="50" />
  266. <RowDefinition />
  267. </Grid.RowDefinitions>
  268. <StackPanel Margin="0,10,0,0" Orientation="Horizontal">
  269. <Button
  270. Width="130"
  271. Margin="10,0,10,0"
  272. Command="{s:Action SimIceCream}"
  273. Content="冰淇淋模拟"
  274. Style="{StaticResource ButtonStyle}" />
  275. <Button
  276. Width="130"
  277. Margin="10,0,10,0"
  278. s:View.ActionTarget="{Binding}"
  279. Command="{s:Action SimCoffee}"
  280. Content="咖啡模拟"
  281. Style="{StaticResource ButtonStyle}" />
  282. </StackPanel>
  283. <StackPanel Grid.Row="1" Margin="0,10,0,0" Orientation="Vertical">
  284. <Grid HorizontalAlignment="Left">
  285. <Grid.ColumnDefinitions>
  286. <ColumnDefinition Width="*"></ColumnDefinition>
  287. <ColumnDefinition Width="100"></ColumnDefinition>
  288. <ColumnDefinition Width="*"></ColumnDefinition>
  289. <ColumnDefinition Width="100"></ColumnDefinition>
  290. <ColumnDefinition Width="*"></ColumnDefinition>
  291. <ColumnDefinition Width="100"></ColumnDefinition>
  292. </Grid.ColumnDefinitions>
  293. <TextBlock>机器人连接状态</TextBlock>
  294. <TextBlock Margin="10,0,0,0" Grid.Column="1" Text="{Binding RobotConnected}"></TextBlock>
  295. <TextBlock Grid.Column="2">冰淇淋机连接状态</TextBlock>
  296. <TextBlock Margin="10,0,0,0" Grid.Column="3" Text="{Binding IceCreamConnected}"></TextBlock>
  297. <TextBlock Grid.Column="4">咖啡机连接状态</TextBlock>
  298. <TextBlock Margin="10,0,0,0" Grid.Column="5" Text="{Binding CoffeeConnected}"></TextBlock>
  299. </Grid>
  300. </StackPanel>
  301. </Grid>
  302. </GroupBox>
  303. <!--#endregion-->
  304. <Grid Grid.Row="1">
  305. <Grid.ColumnDefinitions>
  306. <ColumnDefinition />
  307. <ColumnDefinition />
  308. </Grid.ColumnDefinitions>
  309. <!--#region 冰淇淋机-->
  310. <GroupBox
  311. BorderBrush="#3aa7f3"
  312. BorderThickness="2"
  313. FontFamily="楷体"
  314. FontSize="20"
  315. Foreground="Aqua"
  316. Header=" 冰淇淋控制 "
  317. Style="{DynamicResource GroupBoxStyle1}">
  318. <StackPanel Orientation="Vertical">
  319. <StackPanel.Resources>
  320. <Style TargetType="StackPanel">
  321. <Setter Property="Margin" Value="5"></Setter>
  322. </Style>
  323. </StackPanel.Resources>
  324. <StackPanel Orientation="Horizontal">
  325. <Button Content="1号口开" s:View.ActionTarget="{Binding}" Command="{s:Action OpenSE1}" Style="{StaticResource ButtonStyle}"></Button>
  326. <Button Content="1号口关" s:View.ActionTarget="{Binding}" Command="{s:Action CloseSE1}" Style="{StaticResource ButtonStyle}"></Button>
  327. </StackPanel>
  328. <StackPanel Orientation="Horizontal">
  329. <Button Content="2号口开" s:View.ActionTarget="{Binding}" Command="{s:Action OpenSE2}" Style="{StaticResource ButtonStyle}"></Button>
  330. <Button Content="2号口关" s:View.ActionTarget="{Binding}" Command="{s:Action CloseSE2}" Style="{StaticResource ButtonStyle}"></Button>
  331. </StackPanel>
  332. <StackPanel Orientation="Horizontal">
  333. <Button Content="3号口开" s:View.ActionTarget="{Binding}" Command="{s:Action OpenSE3}" Style="{StaticResource ButtonStyle}"></Button>
  334. <Button Content="3号口关" s:View.ActionTarget="{Binding}" Command="{s:Action CloseSE3}" Style="{StaticResource ButtonStyle}"></Button>
  335. </StackPanel>
  336. <StackPanel Orientation="Horizontal">
  337. <Button Content="转筒转动" s:View.ActionTarget="{Binding}" Command="{s:Action TurnRoll}" Style="{StaticResource ButtonStyle}"></Button>
  338. <Button Content="停止转筒转动" s:View.ActionTarget="{Binding}" Command="{s:Action StopTurnRoll}" Style="{StaticResource ButtonStyle}"></Button>
  339. </StackPanel>
  340. <StackPanel Orientation="Horizontal">
  341. <Button Content="完整制作流程" s:View.ActionTarget="{Binding}" Command="{s:Action MakeIceCreamBySE1}" Style="{StaticResource ButtonStyle}"></Button>
  342. </StackPanel>
  343. <!--<Grid.RowDefinitions>
  344. <RowDefinition />
  345. <RowDefinition />
  346. </Grid.RowDefinitions>
  347. <Grid>
  348. <Grid.RowDefinitions>
  349. <RowDefinition />
  350. <RowDefinition />
  351. <RowDefinition />
  352. <RowDefinition />
  353. </Grid.RowDefinitions>
  354. <Grid.ColumnDefinitions>
  355. <ColumnDefinition Width="120" />
  356. <ColumnDefinition Width="100" />
  357. <ColumnDefinition Width="120" />
  358. <ColumnDefinition Width="100" />
  359. </Grid.ColumnDefinitions>
  360. <TextBlock Grid.Row="0" Grid.Column="0">预冷温度</TextBlock>
  361. <TextBlock
  362. Grid.Row="0"
  363. Grid.Column="1"
  364. Text="{Binding YLWD}" />
  365. <TextBlock Grid.Row="0" Grid.Column="2">回气温度</TextBlock>
  366. <TextBlock
  367. Grid.Row="0"
  368. Grid.Column="3"
  369. Text="{Binding HQWD}" />
  370. <TextBlock Grid.Row="1" Grid.Column="0">环境温度</TextBlock>
  371. <TextBlock
  372. Grid.Row="1"
  373. Grid.Column="1"
  374. Text="{Binding HJWD}" />
  375. <TextBlock Grid.Row="1" Grid.Column="2">当前模式</TextBlock>
  376. <TextBlock
  377. Grid.Row="1"
  378. Grid.Column="3"
  379. Text="{Binding CurrentMode}" />
  380. <TextBlock Grid.Row="2" Grid.Column="0">电流</TextBlock>
  381. <TextBlock
  382. Grid.Row="2"
  383. Grid.Column="1"
  384. Text="{Binding DL}" />
  385. <TextBlock Grid.Row="2" Grid.Column="2">电压</TextBlock>
  386. <TextBlock
  387. Grid.Row="2"
  388. Grid.Column="3"
  389. Text="{Binding DY}" />
  390. <TextBlock Grid.Row="3" Grid.Column="0">成型比</TextBlock>
  391. <TextBlock
  392. Grid.Row="3"
  393. Grid.Column="1"
  394. Text="{Binding CXB}" />
  395. <TextBlock Grid.Row="3" Grid.Column="2">故障</TextBlock>
  396. <TextBlock
  397. Grid.Row="3"
  398. Grid.Column="3"
  399. Text="{Binding IceCreamFault}" />
  400. </Grid>
  401. <StackPanel Grid.Row="1" Orientation="Vertical">
  402. <StackPanel Margin="0,10,0,0" Orientation="Horizontal">
  403. <TextBlock>饮品</TextBlock>
  404. <Button
  405. s:View.ActionTarget="{Binding}"
  406. Command="{s:Action MakeIceCream}"
  407. Content="制作" />
  408. </StackPanel>
  409. <StackPanel Margin="0,10,0,0" Orientation="Horizontal">
  410. <TextBlock>模式</TextBlock>
  411. <ComboBox
  412. Width="100"
  413. ItemsSource="{Binding IceCreamModes}"
  414. SelectedItem="{Binding SelecteIceCreamdMode}" />
  415. <Button
  416. s:View.ActionTarget="{Binding}"
  417. Command="{s:Action SetIceCreamModel}"
  418. Content="设置" />
  419. </StackPanel>
  420. </StackPanel>-->
  421. </StackPanel>
  422. </GroupBox>
  423. <!--#endregion-->
  424. <!--#region 咖啡机-->
  425. <GroupBox
  426. Grid.Column="1"
  427. BorderBrush="#3aa7f3"
  428. BorderThickness="2"
  429. FontFamily="楷体"
  430. FontSize="20"
  431. Foreground="Aqua"
  432. Header=" 咖啡机控制 "
  433. Style="{DynamicResource GroupBoxStyle1}">
  434. <Grid>
  435. <Grid.RowDefinitions>
  436. <RowDefinition />
  437. <RowDefinition />
  438. </Grid.RowDefinitions>
  439. <Grid>
  440. <Grid.Resources>
  441. <Style TargetType="TextBlock">
  442. <Setter Property="HorizontalAlignment" Value="Left" />
  443. <Setter Property="VerticalAlignment" Value="Center" />
  444. </Style>
  445. </Grid.Resources>
  446. <Grid.RowDefinitions>
  447. <RowDefinition />
  448. <RowDefinition />
  449. </Grid.RowDefinitions>
  450. <Grid.ColumnDefinitions>
  451. <ColumnDefinition Width="120" />
  452. <ColumnDefinition Width="100" />
  453. <ColumnDefinition Width="120" />
  454. <ColumnDefinition Width="150" />
  455. </Grid.ColumnDefinitions>
  456. <TextBlock Grid.Row="0" Grid.Column="0">咖啡机状态</TextBlock>
  457. <TextBlock
  458. Grid.Row="0"
  459. Grid.Column="1"
  460. Text="{Binding CoffeeStatus}" />
  461. <TextBlock Grid.Row="0" Grid.Column="2">应用状态</TextBlock>
  462. <TextBlock
  463. Grid.Row="0"
  464. Grid.Column="3"
  465. Text="{Binding AppStatus}" />
  466. <TextBlock Grid.Row="1" Grid.Column="0">告警信息</TextBlock>
  467. <TextBlock
  468. Grid.Row="1"
  469. Grid.Column="1"
  470. Text="{Binding Warning}" />
  471. <TextBlock Grid.Row="1" Grid.Column="2">故障信息</TextBlock>
  472. <TextBlock
  473. Grid.Row="1"
  474. Grid.Column="3"
  475. Text="{Binding CaffeeFault}" />
  476. </Grid>
  477. <StackPanel Grid.Row="1" Orientation="Vertical">
  478. <StackPanel Margin="0,10,0,0" Orientation="Horizontal">
  479. <TextBlock>饮品</TextBlock>
  480. <ComboBox
  481. Width="100"
  482. ItemsSource="{Binding Coffees}"
  483. SelectedItem="{Binding SelectedCoffee}" Style="{DynamicResource ComboBoxStyle}" />
  484. <Button
  485. s:View.ActionTarget="{Binding}"
  486. Command="{s:Action MakeCoffee}"
  487. Style="{StaticResource ButtonStyle}"
  488. Content="制作" />
  489. <Button
  490. s:View.ActionTarget="{Binding}"
  491. Command="{s:Action StopMakeCoffee}"
  492. Style="{StaticResource ButtonStyle}"
  493. Content="停止制作" />
  494. </StackPanel>
  495. <StackPanel Margin="0,10,0,0" Orientation="Horizontal">
  496. <TextBlock>模式</TextBlock>
  497. <ComboBox
  498. Width="100"
  499. ItemsSource="{Binding CoffeeCmds}"
  500. SelectedItem="{Binding SelectedCoffeeCmd}" Style="{DynamicResource ComboBoxStyle}" />
  501. <Button
  502. s:View.ActionTarget="{Binding}"
  503. Command="{s:Action SetCoffeeModel}"
  504. Style="{StaticResource ButtonStyle}"
  505. Content="设置" />
  506. </StackPanel>
  507. </StackPanel>
  508. </Grid>
  509. </GroupBox>
  510. <!--#endregion-->
  511. </Grid>
  512. <!--<GroupBox
  513. Grid.Row="1"
  514. Grid.Column="0"
  515. Header="冰淇淋机">
  516. <Grid>
  517. <Grid.RowDefinitions>
  518. <RowDefinition />
  519. <RowDefinition />
  520. </Grid.RowDefinitions>
  521. <Grid>
  522. <Grid.RowDefinitions>
  523. <RowDefinition />
  524. <RowDefinition />
  525. <RowDefinition />
  526. <RowDefinition />
  527. </Grid.RowDefinitions>
  528. <Grid.ColumnDefinitions>
  529. <ColumnDefinition Width="120" />
  530. <ColumnDefinition Width="100" />
  531. <ColumnDefinition Width="120" />
  532. <ColumnDefinition Width="100" />
  533. </Grid.ColumnDefinitions>
  534. <TextBlock Grid.Row="0" Grid.Column="0">预冷温度</TextBlock>
  535. <TextBlock
  536. Grid.Row="0"
  537. Grid.Column="1"
  538. Text="{Binding YLWD}" />
  539. <TextBlock Grid.Row="0" Grid.Column="2">回气温度</TextBlock>
  540. <TextBlock
  541. Grid.Row="0"
  542. Grid.Column="3"
  543. Text="{Binding HQWD}" />
  544. <TextBlock Grid.Row="1" Grid.Column="0">环境温度</TextBlock>
  545. <TextBlock
  546. Grid.Row="1"
  547. Grid.Column="1"
  548. Text="{Binding HJWD}" />
  549. <TextBlock Grid.Row="1" Grid.Column="2">当前模式</TextBlock>
  550. <TextBlock
  551. Grid.Row="1"
  552. Grid.Column="3"
  553. Text="{Binding CurrentMode}" />
  554. <TextBlock Grid.Row="2" Grid.Column="0">电流</TextBlock>
  555. <TextBlock
  556. Grid.Row="2"
  557. Grid.Column="1"
  558. Text="{Binding DL}" />
  559. <TextBlock Grid.Row="2" Grid.Column="2">电压</TextBlock>
  560. <TextBlock
  561. Grid.Row="2"
  562. Grid.Column="3"
  563. Text="{Binding DY}" />
  564. <TextBlock Grid.Row="3" Grid.Column="0">成型比</TextBlock>
  565. <TextBlock
  566. Grid.Row="3"
  567. Grid.Column="1"
  568. Text="{Binding CXB}" />
  569. <TextBlock Grid.Row="3" Grid.Column="2">故障</TextBlock>
  570. <TextBlock
  571. Grid.Row="3"
  572. Grid.Column="3"
  573. Text="{Binding IceCreamFault}" />
  574. </Grid>
  575. <StackPanel Grid.Row="1" Orientation="Vertical">
  576. <StackPanel Margin="0,10,0,0" Orientation="Horizontal">
  577. <TextBlock>饮品</TextBlock>
  578. <Button
  579. s:View.ActionTarget="{Binding}"
  580. Command="{s:Action MakeIceCream}"
  581. Content="制作" />
  582. </StackPanel>
  583. <StackPanel Margin="0,10,0,0" Orientation="Horizontal">
  584. <TextBlock>模式</TextBlock>
  585. <ComboBox
  586. Width="100"
  587. ItemsSource="{Binding IceCreamModes}"
  588. SelectedItem="{Binding SelecteIceCreamdMode}" />
  589. <Button
  590. s:View.ActionTarget="{Binding}"
  591. Command="{s:Action SetIceCreamModel}"
  592. Content="设置" />
  593. </StackPanel>
  594. </StackPanel>
  595. </Grid>
  596. </GroupBox>-->
  597. <!--<GroupBox
  598. Grid.Row="1"
  599. Grid.Column="1"
  600. Header="咖啡机">
  601. <Grid>
  602. <Grid.RowDefinitions>
  603. <RowDefinition />
  604. <RowDefinition />
  605. </Grid.RowDefinitions>
  606. <Grid>
  607. <Grid.Resources>
  608. <Style TargetType="TextBlock">
  609. <Setter Property="HorizontalAlignment" Value="Left" />
  610. <Setter Property="VerticalAlignment" Value="Center" />
  611. </Style>
  612. </Grid.Resources>
  613. <Grid.RowDefinitions>
  614. <RowDefinition />
  615. <RowDefinition />
  616. </Grid.RowDefinitions>
  617. <Grid.ColumnDefinitions>
  618. <ColumnDefinition Width="120" />
  619. <ColumnDefinition Width="100" />
  620. <ColumnDefinition Width="120" />
  621. <ColumnDefinition Width="150" />
  622. </Grid.ColumnDefinitions>
  623. <TextBlock Grid.Row="0" Grid.Column="0">咖啡机状态</TextBlock>
  624. <TextBlock
  625. Grid.Row="0"
  626. Grid.Column="1"
  627. Text="{Binding CoffeeStatus}" />
  628. <TextBlock Grid.Row="0" Grid.Column="2">应用状态</TextBlock>
  629. <TextBlock
  630. Grid.Row="0"
  631. Grid.Column="3"
  632. Text="{Binding AppStatus}" />
  633. <TextBlock Grid.Row="1" Grid.Column="0">告警信息</TextBlock>
  634. <TextBlock
  635. Grid.Row="1"
  636. Grid.Column="1"
  637. Text="{Binding Warning}" />
  638. <TextBlock Grid.Row="1" Grid.Column="2">故障信息</TextBlock>
  639. <TextBlock
  640. Grid.Row="1"
  641. Grid.Column="3"
  642. Text="{Binding CaffeeFault}" />
  643. </Grid>
  644. <StackPanel Grid.Row="1" Orientation="Vertical">
  645. <StackPanel Margin="0,10,0,0" Orientation="Horizontal">
  646. <TextBlock>饮品</TextBlock>
  647. <ComboBox
  648. Width="100"
  649. ItemsSource="{Binding Coffees}"
  650. SelectedItem="{Binding SelectedCoffee}" />
  651. <Button
  652. s:View.ActionTarget="{Binding}"
  653. Command="{s:Action MakeCoffee}"
  654. Content="制作" />
  655. <Button
  656. s:View.ActionTarget="{Binding}"
  657. Command="{s:Action StopMakeCoffee}"
  658. Content="停止制作" />
  659. </StackPanel>
  660. <StackPanel Margin="0,10,0,0" Orientation="Horizontal">
  661. <TextBlock>模式</TextBlock>
  662. <ComboBox
  663. Width="100"
  664. ItemsSource="{Binding CoffeeCmds}"
  665. SelectedItem="{Binding SelectedCoffeeCmd}" />
  666. <Button
  667. s:View.ActionTarget="{Binding}"
  668. Command="{s:Action SetCoffeeModel}"
  669. Content="设置" />
  670. </StackPanel>
  671. </StackPanel>
  672. </Grid>
  673. </GroupBox>-->
  674. </Grid>
  675. </UserControl>