|
|
@@ -0,0 +1,51 @@
|
|
|
+<UserControl xmlns="https://github.com/avaloniaui"
|
|
|
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
|
+ xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
|
|
+ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
|
+ xmlns:modules="using:PRS.Avalonia.Modules.MyHR"
|
|
|
+ xmlns:avalonia="using:PRS.Avalonia"
|
|
|
+ xmlns:components="using:InABox.Avalonia.Components"
|
|
|
+ xmlns:converters="using:InABox.Avalonia.Converters"
|
|
|
+ xmlns:listView="using:PRS.Avalonia.Components.ListView"
|
|
|
+ mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
|
|
|
+ x:Class="PRS.Avalonia.Modules.MyHR.MyHRQualificationsView"
|
|
|
+ x:DataType="modules:MyHRQualificationsViewModel">
|
|
|
+ <listView:PrsListView Repository="{Binding Qualifications}">
|
|
|
+ <listView:PrsListView.ItemTemplate>
|
|
|
+ <DataTemplate DataType="avalonia:EmployeeQualificationShell">
|
|
|
+ <Button Classes="Standard"
|
|
|
+ Background="{Binding ., Converter={x:Static modules:QualificationColorConverter.Instance}}"
|
|
|
+ Foreground="Black"
|
|
|
+ Padding="5"
|
|
|
+ HorizontalContentAlignment="Stretch"
|
|
|
+ VerticalContentAlignment="Stretch"
|
|
|
+ Command="{Binding $parent[listView:PrsListView].((modules:MyHRQualificationsViewModel)DataContext).QualificationClickedCommand}"
|
|
|
+ CommandParameter="{Binding .}">
|
|
|
+ <Grid RowDefinitions="*,Auto"
|
|
|
+ ColumnDefinitions="Auto,*,Auto">
|
|
|
+ <Image Classes="Large" HorizontalAlignment="Center"
|
|
|
+ VerticalAlignment="Center"
|
|
|
+ Source="{Binding Image, Converter={x:Static converters:ByteArrayToImageSourceConverter.Instance}}"
|
|
|
+ Grid.Row="0" Grid.Column="0" Grid.RowSpan="2"/>
|
|
|
+ <Label Grid.Row="0"
|
|
|
+ Grid.Column="1" Grid.ColumnSpan="2"
|
|
|
+ VerticalAlignment="Stretch"
|
|
|
+ VerticalContentAlignment="Center"
|
|
|
+ FontSize="{StaticResource PrsFontSizeSmall}"
|
|
|
+ FontWeight="{StaticResource PrsFontWeightBold}"
|
|
|
+ Content="{Binding Description}" />
|
|
|
+ <TextBlock Grid.Row="1" Grid.Column="1"
|
|
|
+ FontSize="{StaticResource PrsFontSizeExtraSmall}" FontStyle="{StaticResource PrsFontStylItalic}"
|
|
|
+ TextWrapping="WrapWithOverflow"
|
|
|
+ VerticalAlignment="Stretch"
|
|
|
+ Text="{Binding ., Converter={x:Static modules:QualificationNumberConverter.Instance}}"/>
|
|
|
+ <TextBlock Grid.Row="1" Grid.Column="2"
|
|
|
+ FontSize="{StaticResource PrsFontSizeExtraSmall}" FontStyle="{StaticResource PrsFontStylItalic}"
|
|
|
+ VerticalAlignment="Stretch"
|
|
|
+ Text="{Binding ., Converter={x:Static modules:QualificationExpiryConverter.Instance}}"/>
|
|
|
+ </Grid>
|
|
|
+ </Button>
|
|
|
+ </DataTemplate>
|
|
|
+ </listView:PrsListView.ItemTemplate>
|
|
|
+ </listView:PrsListView>
|
|
|
+</UserControl>
|