-
Notifications
You must be signed in to change notification settings - Fork 0
/
MainWindow.xaml
55 lines (45 loc) · 2.94 KB
/
MainWindow.xaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
<Window x:Class="AutaList.MainWindow"
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:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:AutaList"
mc:Ignorable="d"
Title="AutaList" Height="450" Width="600">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="10"></RowDefinition>
<RowDefinition Height="*"></RowDefinition>
<RowDefinition Height="10"></RowDefinition>
<RowDefinition Height="Auto"></RowDefinition>
<RowDefinition Height="10"></RowDefinition>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="10"></ColumnDefinition>
<ColumnDefinition Width="*"></ColumnDefinition>
<ColumnDefinition Width="10"></ColumnDefinition>
</Grid.ColumnDefinitions>
<DataGrid Name="AutaDataGrid" Grid.Row="1" Grid.Column="1" ColumnWidth="*" ItemsSource="{Binding Auta}" CanUserSortColumns="True" CanUserResizeRows="True" CanUserResizeColumns="True" CanUserAddRows="True" SelectionUnit="FullRow" SelectionMode="Single" AutoGenerateColumns="False" IsReadOnly="True" >
<DataGrid.Columns>
<DataGridTextColumn Header="Název modelu" Binding="{Binding Model}" />
<DataGridTextColumn Header="Datum prodeje" Binding="{Binding Prodano, StringFormat=dd.MM.yyyy}" />
<DataGridTextColumn Header="Cena" Binding="{Binding Cena, ConverterCulture=cs-CZ, StringFormat=N}" />
<DataGridTextColumn Header="DPH" Binding="{Binding DPH}" />
</DataGrid.Columns>
</DataGrid>
<Grid Grid.Row="3" Grid.Column="1">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="10"></ColumnDefinition>
<ColumnDefinition Width="Auto"></ColumnDefinition>
<ColumnDefinition Width="10"></ColumnDefinition>
<ColumnDefinition Width="*"></ColumnDefinition>
<ColumnDefinition Width="10"></ColumnDefinition>
<ColumnDefinition Width="Auto"></ColumnDefinition>
<ColumnDefinition Width="10"></ColumnDefinition>
</Grid.ColumnDefinitions>
<Button Content="Načti tabulku" Command="{Binding LoadTableCommand}" Grid.Column="1" Name="Nacist" HorizontalAlignment="Left" Width="120" Height="25"></Button>
<Button Content="Prodej ve všední dny" Command="{Binding ShowWeekdaysSaleCommand}" Grid.Column="3" HorizontalAlignment="Right" Width="120" Height="25" ></Button>
<Button Content="Prodej o víkendu" Command="{Binding ShowWeekendSaleCommand}" Grid.Column="5" HorizontalAlignment="Right" Width="120" Height="25" ></Button>
</Grid>
</Grid>
</Window>