Skip to content

Commit

Permalink
Update CUBaseInfoDetailsTasksView.xaml
Browse files Browse the repository at this point in the history
  • Loading branch information
peterbarancek authored Jun 26, 2024
1 parent e409986 commit 12d3c47
Showing 1 changed file with 0 additions and 241 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -238,245 +238,4 @@
</Grid>


</UserControl>
<UserControl
x:Class="x_template_xPlc.CUBaseInfoDetailsTasksView"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:local="clr-namespace:x_template_xPlc"
xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:p="clr-namespace:x_template_xHmi.Wpf.Properties"
xmlns:plc="clr-namespace:x_template_xPlc"
xmlns:vortex="http://vortex.mts/xaml" xmlns:vortexs="http://vortex.security.mts/xaml"
mc:Ignorable="d"
d:DesignHeight="450"
d:DesignWidth="800">
<d:UserControl.DataContext>
<local:CUBaseInfoTasksView />
</d:UserControl.DataContext>

<UserControl.Resources>
<BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter" />
<Style x:Key="iconContainer" TargetType="Border">
<Setter Property="Width" Value="40" />
<Setter Property="Height" Value="40" />
<Setter Property="Visibility" Value="Visible" />
<Setter Property="Margin" Value="5" />
<Setter Property="BorderBrush" Value="{StaticResource OnSecondary}" />
<Setter Property="BorderThickness" Value="3" />
<Setter Property="CornerRadius" Value="3" />
</Style>
<Style x:Key="icon" TargetType="materialDesign:PackIcon">
<Setter Property="Width" Value="30" />
<Setter Property="Height" Value="30" />
<Setter Property="Foreground" Value="{DynamicResource OnSecondary}" />
<Setter Property="HorizontalAlignment" Value="Center" />
<Setter Property="VerticalAlignment" Value="Center" />
</Style>

</UserControl.Resources>


<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<!-- Controlled unit name card -->
<materialDesign:Card materialDesign:ShadowAssist.ShadowDepth="Depth1" Padding="2.5">

<Grid Margin="5,0,0,0">
<Grid.ColumnDefinitions>
<ColumnDefinition></ColumnDefinition>
<ColumnDefinition Width="auto"></ColumnDefinition>
</Grid.ColumnDefinitions>
<TextBlock
Grid.Column="1"
HorizontalAlignment="Right"
VerticalAlignment="Center"
Margin="5,0,40,0"
Style="{DynamicResource MaterialDesignHeadline6TextBlock}"
Text="{Binding Component, Converter={vortex:NameOrSymbolConverter}}" />

<!--Cycle time analitics-->
<ScrollViewer
VerticalScrollBarVisibility="Hidden" HorizontalScrollBarVisibility="Auto">

<WrapPanel HorizontalAlignment="Left"
Background="{Binding Component._statusInfo.State.Cyclic,Converter={local:ControledUnitStateToBackgroundBrushConverter}}"
>
<UniformGrid

Margin="5"
HorizontalAlignment="Left"
Columns="4"
Rows="2">
<TextBlock
HorizontalAlignment="Center"
Foreground="{Binding Component._statusInfo.State.Cyclic,Converter={local:ControledUnitStateToForegroundBrushConverter}}"
Text="{x:Static p:strings.ActualCycleTime}" />
<TextBlock
HorizontalAlignment="Center"
Foreground="{Binding Component._statusInfo.State.Cyclic,Converter={local:ControledUnitStateToForegroundBrushConverter}}"
Text="{x:Static p:strings.AverageCycleTime}" />
<TextBlock
HorizontalAlignment="Center"
Foreground="{Binding Component._statusInfo.State.Cyclic,Converter={local:ControledUnitStateToForegroundBrushConverter}}"
Text="{x:Static p:strings.ActualCleanCycleTime}" />
<TextBlock
HorizontalAlignment="Center"
Foreground="{Binding Component._statusInfo.State.Cyclic,Converter={local:ControledUnitStateToForegroundBrushConverter}}"
Text="{x:Static p:strings.AverageCleanCycleTime}" />

<TextBlock
HorizontalAlignment="Center"
Foreground="{Binding Component._statusInfo.State.Cyclic,Converter={local:ControledUnitStateToForegroundBrushConverter}}"
Text="{Binding Component._statusInfo.CurrentCycleTime.Cyclic, StringFormat={}{0:hh\\:mm\\:ss\\:f}}" />
<TextBlock
HorizontalAlignment="Center"
Foreground="{Binding Component._statusInfo.State.Cyclic,Converter={local:ControledUnitStateToForegroundBrushConverter}}"
Text="{Binding Component._statusInfo.AverageCycleTime.Cyclic, StringFormat={}{0:hh\\:mm\\:ss\\:f}}" />


<TextBlock
HorizontalAlignment="Center"
Foreground="{Binding Component._statusInfo.State.Cyclic,Converter={local:ControledUnitStateToForegroundBrushConverter}}"
Text="{Binding Component._statusInfo.CurrentCleanCycleTime.Cyclic, StringFormat={}{0:hh\\:mm\\:ss\\:f}}" />
<TextBlock
HorizontalAlignment="Center"
Foreground="{Binding Component._statusInfo.State.Cyclic,Converter={local:ControledUnitStateToForegroundBrushConverter}}"
Text="{Binding Component._statusInfo.AverageCleanCycleTime.Cyclic, StringFormat={}{0:hh\\:mm\\:ss\\:f}}" />
</UniformGrid>
</WrapPanel>
</ScrollViewer>

</Grid>

</materialDesign:Card>


<!-- Task commands -->
<materialDesign:Card Grid.Row="1"

materialDesign:ShadowAssist.ShadowDepth="Depth1"
Padding="1">

<!-- Short task description and background card coloring -->
<Grid Margin="0,0,0,0" Background="{Binding Component._statusInfo.Mode.Cyclic, Converter={local:SelectorStateToBrushConverter}}">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<TextBlock
Margin="25,0,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Center"
Foreground="{Binding Component._statusInfo.Mode.Cyclic, Converter={local:SelectorStateToForegroundBrushConverter}}"
Style="{DynamicResource MaterialDesignHeadline5TextBlock}"
Text="{Binding Component._statusInfo.CurrentTaskDescription.Cyclic}" />
<StackPanel
Grid.Column="2"
Margin="2"
HorizontalAlignment="Left"
VerticalAlignment="Center"
Orientation="Vertical"
Visibility="{Binding Component._statusInfo.CurrentIsInStepMode.Cyclic, Converter={StaticResource BooleanToVisibilityConverter}}">

<materialDesign:PackIcon
Foreground="{Binding Component._statusInfo.Mode.Cyclic, Converter={plc:SelectorStateToForegroundBrushConverter}}"
Kind="ShoePrint"
Style="{StaticResource icon}" />
</StackPanel>
<!-- Task command buttons -->
<ItemsControl
Grid.Row="0"
Grid.Column="1"
Margin="10"
ItemsSource="{Binding TaskControls}">
<ItemsControl.ItemsPanel>
<ItemsPanelTemplate>
<WrapPanel HorizontalAlignment="Right" />
</ItemsPanelTemplate>
</ItemsControl.ItemsPanel>
<ItemsControl.ItemTemplate>
<DataTemplate>
<ContentControl Width="200" Margin="10">
<vortex:RenderableContentControl DataContext="{Binding }" PresentationType="TaskCommand" />
</ContentControl>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
</Grid>
</materialDesign:Card>

<!-- Tasks details card -->

<materialDesign:Card
Grid.Row="2"
materialDesign:ShadowAssist.ShadowDepth="Depth1"
Padding="2.5">


<TabControl >
<TabItem Header="{x:Static p:strings.Control}">
<Grid>
<!-- Tasks details card -->
<materialDesign:Card
materialDesign:ShadowAssist.ShadowDepth="Depth1"
Padding="2.5">
<ScrollViewer>

<ItemsControl ItemsSource="{Binding TaskControls}">
<ItemsControl.ItemsPanel>
<ItemsPanelTemplate>
<StackPanel />
</ItemsPanelTemplate>
</ItemsControl.ItemsPanel>
<ItemsControl.ItemTemplate>
<DataTemplate>
<ContentControl>
<vortex:RenderableContentControl DataContext="{Binding }" PresentationType="Sequence" />
</ContentControl>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>

</ScrollViewer>
</materialDesign:Card>
<!-- Components card -->
<materialDesign:Card
materialDesign:ShadowAssist.ShadowDepth="Depth1"
Padding="2.5"
Visibility="{Binding ManualTask._taskState.Cyclic, Converter={local:TaskStateToVisibilityConverter}}">

<vortex:RenderableContentControl Grid.Row="1" DataContext="{Binding Components}" PresentationType="Base-Service-Manual-Base">
</vortex:RenderableContentControl>

</materialDesign:Card>
</Grid>
</TabItem>
<TabItem Header="{x:Static p:strings.StationProcessData}" DataContext="{Binding Component}">
<vortex:RenderableContentControl DataContext="{Binding _cuProcessDataDisplay}" PresentationType="ShadowDisplaySlim-ShadowDisplay"></vortex:RenderableContentControl>
</TabItem>
<TabItem Header="{x:Static p:strings.StationTechnologyData}" DataContext="{Binding Component}">
<vortex:RenderableContentControl DataContext="{Binding _cuTechnologicalDataDisplay}" PresentationType="ShadowDisplaySlim-ShadowDisplay"></vortex:RenderableContentControl>
</TabItem>
<TabItem Header="{x:Static p:strings.FullProcessData}">
<vortex:RenderableContentControl DataContext="{Binding OnlineData}" PresentationType="ShadowDisplaySlim-ShadowDisplay"></vortex:RenderableContentControl>

</TabItem>

</TabControl>



</materialDesign:Card>

</Grid>


</UserControl>

0 comments on commit 12d3c47

Please sign in to comment.