-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAddEditServiceWindow.xaml
More file actions
87 lines (74 loc) · 4.47 KB
/
Copy pathAddEditServiceWindow.xaml
File metadata and controls
87 lines (74 loc) · 4.47 KB
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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
<Window x:Class="MyPanelCarWashing.AddEditServiceWindow"
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:MyPanelCarWashing"
mc:Ignorable="d"
Title="Добавление/Редактирование услуги"
WindowStartupLocation="CenterScreen"
ResizeMode="NoResize"
Width="550" Height="750"
Background="#F5F6FA"
BorderBrush="Black"
BorderThickness="1"
WindowStyle="None">
<Grid Margin="15">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<TextBlock Text="{Binding WindowTitle}" FontSize="20" FontWeight="Bold"
Foreground="#2C3E50" HorizontalAlignment="Center" Margin="0,0,0,15" Grid.Row="0"/>
<Label Content="Название услуги:" Grid.Row="1" Margin="0,5" FontWeight="SemiBold"/>
<TextBox x:Name="NameTextBox" Text="{Binding CurrentService.Name, UpdateSourceTrigger=PropertyChanged}"
Grid.Row="2" Margin="0,5" Height="50" Padding="5"/>
<Label Content="Цены по категориям кузова:" Grid.Row="3" Margin="0,5" FontWeight="SemiBold"/>
<Grid Grid.Row="4" Margin="0,5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<StackPanel Grid.Column="0" Margin="5">
<Label Content="Категория 1 (Легковая)" FontSize="10"/>
<TextBox x:Name="PriceCategory1TextBox" Height="50" Padding="5" Text="0"/>
</StackPanel>
<StackPanel Grid.Column="1" Margin="5">
<Label Content="Категория 2 (Универсал)" FontSize="10"/>
<TextBox x:Name="PriceCategory2TextBox" Height="50" Padding="5" Text="0"/>
</StackPanel>
<StackPanel Grid.Column="2" Margin="5">
<Label Content="Категория 3 (Кроссовер)" FontSize="10"/>
<TextBox x:Name="PriceCategory3TextBox" Height="50" Padding="5" Text="0"/>
</StackPanel>
<StackPanel Grid.Column="3" Margin="5">
<Label Content="Категория 4 (Внедорожник)" FontSize="10"/>
<TextBox x:Name="PriceCategory4TextBox" Height="50" Padding="5" Text="0"/>
</StackPanel>
</Grid>
<Label Content="Длительность (минуты):" Grid.Row="5" Margin="0,5" FontWeight="SemiBold"/>
<TextBox x:Name="DurationTextBox" Text="{Binding CurrentService.DurationMinutes, UpdateSourceTrigger=PropertyChanged}"
Grid.Row="6" Margin="0,5" Height="50" Padding="5"/>
<Label Content="Описание:" Grid.Row="7" Margin="0,5" FontWeight="SemiBold"/>
<TextBox x:Name="DescriptionTextBox" Text="{Binding CurrentService.Description, UpdateSourceTrigger=PropertyChanged}"
Grid.Row="8" Margin="0,5" Height="80" Padding="5" TextWrapping="Wrap" AcceptsReturn="True"/>
<!-- <CheckBox Content="Услуга активна" IsChecked="{Binding CurrentService.IsActive}" Grid.Row="9" Margin="0,10" HorizontalAlignment="Left"/> -->
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center" Grid.Row="10" Margin="0,15">
<Button Content="✅ Сохранить" Click="SaveButton_Click" Width="120" Height="35"
Margin="5" Background="#27AE60" Foreground="White" Cursor="Hand"/>
<Button Content="✖ Отмена" Click="CloseButton_Click" Width="100" Height="35"
Margin="5" Background="#E74C3C" Foreground="White" Cursor="Hand"/>
</StackPanel>
</Grid>
</Window>