-
Notifications
You must be signed in to change notification settings - Fork 0
/
MainWindow.xaml
1131 lines (1129 loc) · 87.8 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
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
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<Window x:Class="hotelAdm.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:gif="http://wpfanimatedgif.codeplex.com"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:hotelAdm"
mc:Ignorable="d"
Title="Hotel" Height="700" Width="1200" WindowStartupLocation="CenterScreen" ResizeMode="CanMinimize">
<Grid>
<Grid x:Name="ContentGrid">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="4*"/>
</Grid.ColumnDefinitions>
<Grid x:Name="MenuGrid" Grid.Column="0" Background="Gray">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="5*"/>
</Grid.RowDefinitions>
<Grid x:Name="UserNameBox" Grid.Row="0" Background="#FF525252">
<Label x:Name="NameLabel" Style="{StaticResource ForUserLabels}" Content="NameLabel" Margin="10,24,10.4,0" Width="218" Height="41" FontSize="24" FontWeight="Bold"/>
<Label x:Name="PositionLabel" Style="{StaticResource ForUserLabels}" Content="PositionLabel" Margin="10,70,10.4,0" Width="218"/>
</Grid>
<Grid x:Name="MenuBox" Grid.Row="1">
<StackPanel x:Name="MenuButtons">
<Button x:Name="NewOfferBtn" Content="Новый заказ" Style="{StaticResource ForMenuButtons}" Click="NewOfferBtn_Click" Visibility="Collapsed"/>
<Button x:Name="ApartsBtn" Content="Номера" Style="{StaticResource ForMenuButtons}" Click="ApartsBtn_Click" Visibility="Collapsed"/>
<Button x:Name="OffersBtn" Content="Список заказов" Style="{StaticResource ForMenuButtons}" Click="OffersBtn_Click" Visibility="Collapsed"/>
<Button x:Name="StokBtn" Content="Склад" Style="{StaticResource ForMenuButtons}" Click="StokBtn_Click" Visibility="Collapsed"/>
<Button x:Name="GuestsBtn" Content="Клиенты" Style="{StaticResource ForMenuButtons}" Click="GuestsBtn_Click" Visibility="Collapsed"/>
<Button x:Name="SBSettingsBtn" Content="Настройки" Style="{StaticResource ForMenuButtons}" Click="SBSettingsBtn_Click" Margin="7,15,3.4,15" Visibility="Collapsed"/>
</StackPanel>
</Grid>
</Grid>
<Grid x:Name="DataGrid" Grid.Column="1">
<Image Source="img/logo.png" Margin="245,146,245,146"/>
<Grid x:Name="SettingsGrid" Visibility="Hidden" Background="White">
<TabControl x:Name="DBSettingsTab">
<TabItem x:Name="ConnectionSettings">
<TabItem.Header>
<TextBlock Text="Подключение к БД"/>
</TabItem.Header>
<TabItem.Content>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="2*"/>
<RowDefinition Height="3*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Label Grid.Column="1" Content="Настройка подключения БД" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="34"/>
<Grid Grid.Column="1" Grid.Row="1">
<Grid.RowDefinitions>
<RowDefinition Height="2*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition/>
<ColumnDefinition/>
</Grid.ColumnDefinitions>
<StackPanel Grid.Column="0" Grid.Row="0">
<Label Content="Сервер" Style="{StaticResource ForSettingsLabels}"/>
<Label Content="Порт" Style="{StaticResource ForSettingsLabels}"/>
<Label Content="Имя базы данных" Style="{StaticResource ForSettingsLabels}"/>
<Label Content="Пользователь" Style="{StaticResource ForSettingsLabels}"/>
<Label Content="Пароль" Style="{StaticResource ForSettingsLabels}"/>
</StackPanel>
<StackPanel Grid.Column="1" Grid.Row="0">
<TextBox x:Name="DBServerSettingsTextbox" Style="{StaticResource ForSettingsTextboxes}"/>
<TextBox x:Name="DBPortSettingsTextbox" Style="{StaticResource ForSettingsTextboxes}"/>
<TextBox x:Name="DBNameSettingsTextbox" Style="{StaticResource ForSettingsTextboxes}"/>
<TextBox x:Name="DBUserSettingsTextbox" Style="{StaticResource ForSettingsTextboxes}"/>
<TextBox x:Name="DBPassSettingsTextbox" Style="{StaticResource ForSettingsTextboxes}"/>
</StackPanel>
<Grid Grid.Row="1" Grid.ColumnSpan="2">
<Button x:Name="SaveSettingsBtn" Content="Сохранить" Style="{StaticResource ForMenuButtons}" Click="SaveSettingsBtn_Click"/>
</Grid>
</Grid>
<StackPanel Grid.Row="2" Grid.ColumnSpan="3" Orientation="Horizontal">
<Button x:Name="SaveDBBtn" Content="Резервная копия" Style="{StaticResource ForMenuButtons}" Click="SaveDBBtn_Click" Margin="5,57,5,15.2" Width="239"/>
<Button x:Name="AnyQueryBtn" Content="Пользовательские запросы" Style="{StaticResource ForMenuButtons}" Click="AnyQueryBtn_Click" Margin="5,57,5,15.2" Width="357"/>
<Button x:Name="ReportBtn" Content="Отчет" Style="{StaticResource ForMenuButtons}" Margin="5,57,5,15.2" Width="108" Click="ReportBtn_Click"/>
</StackPanel>
</Grid>
</TabItem.Content>
</TabItem>
<TabItem x:Name="UsersSettings">
<TabItem.Header>
<TextBlock Text="Пользователи"/>
</TabItem.Header>
<TabItem.Content>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="6*"/>
<RowDefinition Height="3*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Grid Grid.Column="1" Grid.Row="1">
<ScrollViewer>
<DataGrid x:Name="usersDataGrid" IsReadOnly="True" AutoGenerateColumns="True" HorizontalGridLinesBrush="DarkGray"
RowBackground="LightGray" AlternatingRowBackground="White" FontSize="14">
<DataGrid.Columns>
<DataGridTextColumn Header="ID" Binding="{Binding Path=id}"/>
<DataGridTextColumn Header="Логин" Binding="{Binding Path=login}"/>
<DataGridTextColumn Header="Пароль" Binding="{Binding Path=password}"/>
<DataGridTextColumn Header="ФИО" Binding="{Binding Path=FIO}"/>
<DataGridTextColumn Header="Тип" Binding="{Binding Path=type}"/>
<DataGridTextColumn Header="Должность" Binding="{Binding Path=position_name}"/>
</DataGrid.Columns>
</DataGrid>
</ScrollViewer>
</Grid>
<Grid x:Name="UsersControlBtnGrid" Grid.Column="1" Grid.Row="2" Background="White" Visibility="Visible">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="*"/>
<RowDefinition Height="2*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Button x:Name="AddUserBtn" Content="Создать" Grid.Row="1" Grid.Column="1" Style="{StaticResource ForAddBtn}" Click="AddUserBtn_Click"/>
<Button x:Name="UpdateUserBtn" Content="Изменить" Grid.Row="1" Grid.Column="3" Style="{StaticResource ForEditBtn}" Click="UpdateUserBtn_Click"/>
<Button x:Name="DeleteUserBtn" Content="Удалить" Grid.Row="1" Grid.Column="5" Style="{StaticResource ForDeleteBtn}" Click="DeleteUserBtn_Click"/>
</Grid>
<Grid x:Name="CreateUserGrid" Grid.Column="1" Grid.Row="2" Visibility="Hidden">
<Grid.RowDefinitions>
<RowDefinition Height="4*"/>
<RowDefinition Height="5*"/>
<RowDefinition Height="2*"/>
<RowDefinition Height="5*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
</Grid.ColumnDefinitions>
<Label Content="Добавление пользователя" Grid.Column="2" Grid.ColumnSpan="5" FontSize="20" HorizontalAlignment="Center"/>
<StackPanel x:Name="CreateUserLoginPanel" Grid.Row="1">
<Label Content="Логин"/>
<TextBox x:Name="CreateUserLoginTextBox"/>
</StackPanel>
<StackPanel x:Name="CreateUserPasswordPanel" Grid.Row="1" Grid.Column="2">
<Label Content="Пароль"/>
<TextBox x:Name="CreateUserPasswordTextBox"/>
</StackPanel>
<StackPanel x:Name="CreateUserFIOPanel" Grid.Row="1" Grid.Column="4">
<Label Content="ФИО"/>
<TextBox x:Name="CreateUserFIOTextBox"/>
</StackPanel>
<StackPanel x:Name="CreateUserTypePanel" Grid.Row="1" Grid.Column="6">
<Label Content="Тип"/>
<ComboBox x:Name="CreateUserTypeTextBox" IsEditable="True" IsReadOnly="True" Text="Выберите"/>
</StackPanel>
<StackPanel x:Name="CreateUserPositionPanel" Grid.Row="1" Grid.Column="8">
<Label Content="Должность"/>
<ComboBox x:Name="CreateUserPositionTextBox" IsEditable="True" IsReadOnly="True" Text="Выберите"/>
</StackPanel>
<Button x:Name="CreateUserCanselBtn" Content="Отменить" Grid.Column="6" Grid.Row="3" Style="{StaticResource ForDeleteBtn}" Click="CreateUserCanselBtn_Click"/>
<Button x:Name="CreateUserSaveBtn" Content="Сохранить" Grid.Column="8" Grid.Row="3" Style="{StaticResource ForAddBtn}" Click="CreateUserSaveBtn_Click"/>
</Grid>
<Grid x:Name="UpdateUserGrid" Grid.Column="1" Grid.Row="2" Visibility="Hidden">
<Grid.RowDefinitions>
<RowDefinition Height="4*"/>
<RowDefinition Height="5*"/>
<RowDefinition Height="2*"/>
<RowDefinition Height="5*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
</Grid.ColumnDefinitions>
<TextBox x:Name="UserIdForUpdate" Visibility="Collapsed"/>
<Label Content="Редактирование пользователя" Grid.Column="2" Grid.ColumnSpan="5" FontSize="20" HorizontalAlignment="Center"/>
<StackPanel x:Name="UpdateUserLoginPanel" Grid.Row="1">
<Label Content="Логин"/>
<TextBox x:Name="UpdateUserLoginTextBox"/>
</StackPanel>
<StackPanel x:Name="UpdateUserPasswordPanel" Grid.Row="1" Grid.Column="2">
<Label Content="Пароль"/>
<TextBox x:Name="UpdateUserPasswordTextBox"/>
</StackPanel>
<StackPanel x:Name="UpdateUserFIOPanel" Grid.Row="1" Grid.Column="4">
<Label Content="ФИО"/>
<TextBox x:Name="UpdateUserFIOTextBox"/>
</StackPanel>
<StackPanel x:Name="UpdateUserTypePanel" Grid.Row="1" Grid.Column="6">
<Label Content="Тип"/>
<ComboBox x:Name="UpdateUserTypeTextBox"/>
</StackPanel>
<StackPanel x:Name="UpdateUserPositionPanel" Grid.Row="1" Grid.Column="8">
<Label Content="Должность"/>
<ComboBox x:Name="UpdateUserPositionTextBox"/>
</StackPanel>
<Button x:Name="UpdateUserCanselBtn" Content="Отменить" Grid.Column="6" Grid.Row="3" Style="{StaticResource ForDeleteBtn}" Click="UpdateUserCanselBtn_Click"/>
<Button x:Name="UpdateUserSaveBtn" Content="Сохранить" Grid.Column="8" Grid.Row="3" Style="{StaticResource ForAddBtn}" Click="UpdateUserSaveBtn_Click"/>
</Grid>
</Grid>
</TabItem.Content>
</TabItem>
<TabItem x:Name="ApartSettings">
<TabItem.Header>
<TextBlock Text="Номера"/>
</TabItem.Header>
<TabItem.Content>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="6*"/>
<RowDefinition Height="3*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Grid Grid.Column="1" Grid.Row="1">
<ScrollViewer>
<DataGrid x:Name="ApartsDataGrid" AutoGenerateColumns="True" HorizontalGridLinesBrush="DarkGray"
RowBackground="LightGray" AlternatingRowBackground="White" FontSize="14">
<DataGrid.Columns>
<DataGridTextColumn Header="ID" Binding="{Binding Path=id}"/>
<DataGridTextColumn Header="Количество комнат" Binding="{Binding Path=countOfRooms}"/>
<DataGridTextColumn Header="Тип номера" Binding="{Binding Path=roomType}"/>
<DataGridTextColumn Header="Время уборки" Binding="{Binding Path=cleaningTime}"/>
<DataGridTextColumn Header="Цена" Binding="{Binding Path=price}"/>
</DataGrid.Columns>
</DataGrid>
</ScrollViewer>
</Grid>
<Grid x:Name="ApartControlBtnGrid" Grid.Column="1" Grid.Row="2">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="*"/>
<RowDefinition Height="2*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Button x:Name="AddApartBtn" Content="Создать" Grid.Row="1" Grid.Column="1" Style="{StaticResource ForAddBtn}" Click="AddApartBtn_Click"/>
<Button x:Name="UpdateApartBtn" Content="Изменить" Grid.Row="1" Grid.Column="3" Style="{StaticResource ForEditBtn}" Click="UpdateApartBtn_Click"/>
<Button x:Name="DeleteApartBtn" Content="Удалить" Grid.Row="1" Grid.Column="5" Style="{StaticResource ForDeleteBtn}" Click="DeleteApartBtn_Click"/>
</Grid>
<Grid x:Name="UpdateApartGrid" Grid.Column="1" Grid.Row="2" Visibility="Hidden">
<Grid.RowDefinitions>
<RowDefinition Height="4*"/>
<RowDefinition Height="5*"/>
<RowDefinition Height="2*"/>
<RowDefinition Height="5*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
</Grid.ColumnDefinitions>
<Label x:Name="UpdateApartLabel" Content="Редактирование Номера №" Grid.Column="2" Grid.ColumnSpan="5" FontSize="20" HorizontalAlignment="Center"/>
<Grid Grid.Row="1" Grid.ColumnSpan="9">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="4*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="4*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="4*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="4*"/>
</Grid.ColumnDefinitions>
<TextBox x:Name="UpdateApartId" Visibility="Collapsed"/>
<StackPanel x:Name="UpdateApartRoomsPanel">
<Label Content="Количество комнат"/>
<TextBox x:Name="UpdateApartRoomsTextBox" PreviewTextInput="NumberValidationTextBox"/>
</StackPanel>
<StackPanel x:Name="UpdateApartTypePanel" Grid.Column="2">
<Label Content="Тип номера"/>
<ComboBox x:Name="UpdateApartTypeTextBox"/>
</StackPanel>
<StackPanel x:Name="UpdateApartTimePanel" Grid.Column="4">
<Label Content="Время уборки"/>
<ComboBox x:Name="UpdateApartTimeTextBox"/>
</StackPanel>
<StackPanel x:Name="UpdateApartCostPanel" Grid.Column="6">
<Label Content="Цена"/>
<TextBox x:Name="UpdateApartCostTextBox" PreviewTextInput="NumberValidationTextBox"/>
</StackPanel>
</Grid>
<Button x:Name="UpdateApartCanselBtn" Content="Отменить" Grid.Column="6" Grid.Row="3" Style="{StaticResource ForDeleteBtn}" Click="UpdateApartCanselBtn_Click"/>
<Button x:Name="UpdateApartSaveBtn" Content="Сохранить" Grid.Column="8" Grid.Row="3" Style="{StaticResource ForAddBtn}" Click="UpdateApartSaveBtn_Click"/>
</Grid>
<Grid x:Name="CreateApartGrid" Grid.Column="1" Grid.Row="2" Visibility="Hidden">
<Grid.RowDefinitions>
<RowDefinition Height="4*"/>
<RowDefinition Height="5*"/>
<RowDefinition Height="2*"/>
<RowDefinition Height="5*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
</Grid.ColumnDefinitions>
<Label x:Name="CreateApartLabel" Content="Создание Номера" Grid.Column="2" Grid.ColumnSpan="5" FontSize="20" HorizontalAlignment="Center"/>
<Grid Grid.Row="1" Grid.ColumnSpan="9">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="4*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="4*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="4*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="4*"/>
</Grid.ColumnDefinitions>
<StackPanel x:Name="CreateApartRoomsPanel">
<Label Content="Количество комнат"/>
<TextBox x:Name="CreateApartRoomsTextBox" PreviewTextInput="NumberValidationTextBox"/>
</StackPanel>
<StackPanel x:Name="CreateApartTypePanel" Grid.Column="2">
<Label Content="Тип номера"/>
<ComboBox x:Name="CreateApartTypeTextBox" IsEditable="True" IsReadOnly="True" Text="Выберите"/>
</StackPanel>
<StackPanel x:Name="CreateApartTimePanel" Grid.Column="4">
<Label Content="Время уборки"/>
<ComboBox x:Name="CreateApartTimeTextBox" IsEditable="True" IsReadOnly="True" Text="Выберите"/>
</StackPanel>
<StackPanel x:Name="CreateApartCostPanel" Grid.Column="6">
<Label Content="Цена"/>
<TextBox x:Name="CreateApartCostTextBox" PreviewTextInput="NumberValidationTextBox"/>
</StackPanel>
</Grid>
<Button x:Name="CreateApartCanselBtn" Content="Отменить" Grid.Column="6" Grid.Row="3" Style="{StaticResource ForDeleteBtn}" Click="CreateApartCanselBtn_Click"/>
<Button x:Name="CreateApartSaveBtn" Content="Сохранить" Grid.Column="8" Grid.Row="3" Style="{StaticResource ForAddBtn}" Click="CreateApartSaveBtn_Click"/>
</Grid>
</Grid>
</TabItem.Content>
</TabItem>
<TabItem x:Name="Magazine" MouseUp="Magazine_MouseUp">
<TabItem.Header>
<TextBlock Text="Журнал"/>
</TabItem.Header>
<TabItem.Content>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="6*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Label Grid.Column="1" Content="Журнал" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="24"/>
<Grid Grid.Column="1" Grid.Row="1">
<ScrollViewer>
<DataGrid x:Name="LogDG" AutoGenerateColumns="True" HorizontalGridLinesBrush="DarkGray"
RowBackground="LightGray" AlternatingRowBackground="White" FontSize="14" >
<DataGrid.Columns>
<DataGridTextColumn Header="№" Binding="{Binding Path=Id}"/>
<DataGridTextColumn Header="Время" Binding="{Binding Path=Time}"/>
<DataGridTextColumn Header="Сообщение" Binding="{Binding Path=Text}"/>
<DataGridTextColumn Header="Таблица" Binding="{Binding Path=Table}"/>
<DataGridTextColumn Header="ID в таблице" Binding="{Binding Path=IdInTable}"/>
</DataGrid.Columns>
</DataGrid>
</ScrollViewer>
</Grid>
</Grid>
</TabItem.Content>
</TabItem>
</TabControl>
</Grid>
<Grid x:Name="ApartsGrid" Visibility="Hidden" Background="White">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="8*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="8*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Label Grid.Column="1" Content="Номера" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="36"/>
<ScrollViewer Grid.Row="1" Grid.Column="1">
<Grid x:Name="ApartsBtnGrid">
</Grid>
</ScrollViewer>
</Grid>
<Grid x:Name="NewOfferGrid" Visibility="Hidden" Background="White">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="6*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Label Content="Добавление нового заказа" Grid.ColumnSpan="3" VerticalAlignment="Center" HorizontalAlignment="Center" FontSize="36"/>
<Button x:Name="CancelAddingNewOrderBtn" Content="Отмена" Grid.Row="2" Grid.Column="2" Style="{StaticResource ForDeleteBtn}" Margin="10,10,10,10" Click="CancelAddingNewOrderBtn_Click"/>
<Grid x:Name="SearchClientForNewOrderGrid" Grid.Column="1" Grid.Row="1" Visibility="Visible">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="4*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<StackPanel Grid.Row="1" Grid.Column="1">
<Label Content="Введите номер паспорта клиента" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="20"/>
<TextBox x:Name="ClientForSearchTextBox" Style="{StaticResource LoginTextBoxes}" Template="{StaticResource LoginTextBoxesBorder}"/>
<Button x:Name="ClientForSearchOKBtn" Content="OK" Style="{StaticResource ForMenuButtons}" Margin="150,15,150,15" Click="ClientForSearchOKBtn_Click"/>
</StackPanel>
</Grid>
<Grid x:Name="NewClientForNewOrderGrid" Grid.Column="1" Grid.Row="1" Visibility="Hidden">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="4*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Label Content="Новый клиент" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="20" Grid.ColumnSpan="3"/>
<Grid Grid.Column="1" Grid.Row="1">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<StackPanel Grid.Column="0">
<TextBox Text="ФИО" IsEnabled="False" Style="{StaticResource ForApartInfoLeftTextboxes}"/>
<TextBox Text="№ пасспорта" IsEnabled="False" Style="{StaticResource ForApartInfoLeftTextboxes}"/>
<TextBox Text="№ телефона" IsEnabled="False" Style="{StaticResource ForApartInfoLeftTextboxes}"/>
</StackPanel>
<StackPanel Grid.Column="1">
<TextBox x:Name="FIONewClientNewOrder" Style="{StaticResource ForApartInfoRightTextboxes}"/>
<TextBox x:Name="PassNewClientNewOrder" Style="{StaticResource ForApartInfoRightTextboxes}"/>
<TextBox x:Name="TelNewClientNewOrder" Style="{StaticResource ForApartInfoRightTextboxes}"/>
</StackPanel>
<Button x:Name="SaveNewClientBtn" Content="Сохранить" Grid.Row="1" Grid.ColumnSpan="2" Style="{StaticResource ForAddBtn}" Margin="170,10,170,100" Click="SaveNewClientBtn_Click"/>
</Grid>
</Grid>
<Grid x:Name="ChooseApartsForNewOrderGrid" Grid.Column="1" Grid.Row="1" Visibility="Hidden">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="4*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Label Content="Выберите номера" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="20" Grid.ColumnSpan="3"/>
<ScrollViewer Grid.Column="1" Grid.Row="1">
<Grid x:Name="ForAparts">
</Grid>
</ScrollViewer>
<Button x:Name="SaveApartsListBtn" Content="ОК" Grid.Column="2" Grid.Row="2" Style="{StaticResource ForAddBtn}" Margin="10,10,10,10" Click="SaveApartsListBtn_Click"/>
</Grid>
<Grid x:Name="ChooseDatesForNewOrderGrid" Grid.Column="1" Grid.Row="1" Visibility="Hidden">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="4*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Label Content="Выберите дату начала и количество дней" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="20" Grid.ColumnSpan="3"/>
<Grid Grid.Column="1" Grid.Row="1">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<StackPanel Grid.Column="0">
<TextBox Text="Дата начала" IsEnabled="False" Style="{StaticResource ForApartInfoLeftTextboxes}"/>
<TextBox Text="Количество дней" IsEnabled="False" Style="{StaticResource ForApartInfoLeftTextboxes}"/>
</StackPanel>
<StackPanel Grid.Column="1">
<DatePicker x:Name="StartDayNewOrder" FontSize ="14" Margin="5,0,0,15"/>
<TextBox x:Name="DaysCountNewOrder" Style="{StaticResource ForApartInfoRightTextboxes}" PreviewTextInput="NumberValidationTextBox"/>
</StackPanel>
<Button x:Name="SaveDateInfoBtn" Content="Сохранить" Grid.Row="1" Grid.ColumnSpan="2" Style="{StaticResource ForAddBtn}" Margin="170,10,170,100" Click="SaveDateInfoBtn_Click"/>
</Grid>
</Grid>
<Grid x:Name="ConfirmNewOrderGrid" Grid.Column="1" Grid.Row="1" Visibility="Hidden">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="4*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Label Content="Проверьте данные" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="20" Grid.ColumnSpan="3"/>
<Grid Grid.Column="1" Grid.Row="1">
<Grid.RowDefinitions>
<RowDefinition Height="6*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<StackPanel Grid.Column="0">
<TextBox Text="ФИО" IsEnabled="False" Style="{StaticResource ForApartInfoLeftTextboxes}"/>
<TextBox Text="№ пасспорта" IsEnabled="False" Style="{StaticResource ForApartInfoLeftTextboxes}"/>
<TextBox Text="№ телефона" IsEnabled="False" Style="{StaticResource ForApartInfoLeftTextboxes}"/>
<TextBox Text="Список номеров" IsEnabled="False" Style="{StaticResource ForApartInfoLeftTextboxes}"/>
<TextBox Text="Количество дней" IsEnabled="False" Style="{StaticResource ForApartInfoLeftTextboxes}"/>
<TextBox Text="Дата начала" IsEnabled="False" Style="{StaticResource ForApartInfoLeftTextboxes}"/>
<TextBox Text="Итого" IsEnabled="False" Style="{StaticResource ForApartInfoLeftTextboxes}"/>
</StackPanel>
<StackPanel Grid.Column="1">
<TextBox x:Name="ConfirmFIONewOrder" Style="{StaticResource ForApartInfoRightTextboxes}"/>
<TextBox x:Name="ConfirmPassNewOrder" Style="{StaticResource ForApartInfoRightTextboxes}"/>
<TextBox x:Name="ConfirmTelNewOrder" Style="{StaticResource ForApartInfoRightTextboxes}"/>
<TextBox x:Name="ConfirmApartsNewOrder" Style="{StaticResource ForApartInfoRightTextboxes}"/>
<TextBox x:Name="ConfirmCountNewOrder" Style="{StaticResource ForApartInfoRightTextboxes}"/>
<TextBox x:Name="ConfirmDataNewOrder" Style="{StaticResource ForApartInfoRightTextboxes}"/>
<TextBox x:Name="ConfirmPriceNewOrder" Style="{StaticResource ForApartInfoRightTextboxes}"/>
</StackPanel>
<Button x:Name="SaveNewClientBtn1" Content="Сохранить" Grid.Row="1" Grid.ColumnSpan="2" Style="{StaticResource ForAddBtn}" Click="SaveNewClientBtn1_Click"/>
</Grid>
</Grid>
</Grid>
<Grid x:Name="OfferListGrid" Visibility="Hidden" Background="White">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="7*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="7*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Label Content="Список заказов" Grid.ColumnSpan="3" VerticalAlignment="Center" HorizontalAlignment="Center" FontSize="30"/>
<Grid Grid.Row="1" Grid.Column="1">
<Grid>
<ScrollViewer>
<DataGrid x:Name="OrderListDataGrid" ToolTip="Для просмотра дополнительной информации сделайте двойной щелчек по заказу" IsReadOnly="True" AutoGenerateColumns="True" HorizontalGridLinesBrush="DarkGray"
RowBackground="LightGray" AlternatingRowBackground="White" FontSize="14" MouseDoubleClick="OrderListDataGrid_MouseDoubleClick">
<DataGrid.Columns>
<DataGridTextColumn Header="ID" Binding="{Binding Path=Id}"/>
<DataGridTextColumn Header="К-во дней" Binding="{Binding Path=DaysCount}"/>
<DataGridTextColumn Header="ID Клиента" Binding="{Binding Path=GuestID}"/>
<DataGridTextColumn Header="Цена" Binding="{Binding Path=Price}"/>
<DataGridTextColumn Header="Дата начала" Binding="{Binding Path=StartDay}"/>
<DataGridTextColumn Header="Дата" Binding="{Binding Path=Date}"/>
</DataGrid.Columns>
</DataGrid>
</ScrollViewer>
</Grid>
</Grid>
</Grid>
<Grid x:Name="StokGrid" Visibility="Hidden" Background="White">
<TabControl x:Name="StokTabs">
<TabItem x:Name="ProductsTab">
<TabItem.Header>
<TextBlock Text="Склад"/>
</TabItem.Header>
<TabItem.Content>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="6*"/>
<RowDefinition Height="3*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Label Grid.Column="1" Content="Список продуктов" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="24"/>
<Grid Grid.Column="1" Grid.Row="1">
<ScrollViewer>
<DataGrid x:Name="ProductsDataGrid" IsReadOnly="True" AutoGenerateColumns="True" HorizontalGridLinesBrush="DarkGray"
RowBackground="LightGray" AlternatingRowBackground="White" FontSize="14">
<DataGrid.Columns>
<DataGridTextColumn Header="ID" Binding="{Binding Path=Id}"/>
<DataGridTextColumn Header="Наименование" Binding="{Binding Path=Name}"/>
<DataGridTextColumn Header="Количество" Binding="{Binding Path=Count}"/>
<DataGridTextColumn Header="Единицы измерения" Binding="{Binding Path=Unit}"/>
</DataGrid.Columns>
</DataGrid>
</ScrollViewer>
</Grid>
<Grid x:Name="ProductsControlBtnGrid" Grid.Column="1" Grid.Row="2" Background="White" Visibility="Visible">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="*"/>
<RowDefinition Height="2*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Button x:Name="AddProductBtn" Content="Создать" Grid.Row="1" Grid.Column="1" Style="{StaticResource ForAddBtn}" Click="AddProductBtn_Click"/>
<Button x:Name="UpdateProductBtn" Content="Изменить" Grid.Row="1" Grid.Column="3" Style="{StaticResource ForEditBtn}" Click="UpdateProductBtn_Click"/>
<Button x:Name="DeleteProductBtn" Content="Удалить" Grid.Row="1" Grid.Column="5" Style="{StaticResource ForDeleteBtn}" Click="DeleteProductBtn_Click"/>
</Grid>
<Grid x:Name="CreateProductGrid" Grid.Column="1" Grid.Row="2" Visibility="Hidden">
<Grid.RowDefinitions>
<RowDefinition Height="4*"/>
<RowDefinition Height="5*"/>
<RowDefinition Height="2*"/>
<RowDefinition Height="5*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
</Grid.ColumnDefinitions>
<Label Content="Добавление продукта" Grid.Column="2" Grid.ColumnSpan="5" FontSize="20" HorizontalAlignment="Center"/>
<StackPanel x:Name="CreateProductNamePanel" Grid.Row="1" Grid.Column="2">
<Label Content="Наименование"/>
<TextBox x:Name="CreateProductNameTextBox"/>
</StackPanel>
<StackPanel x:Name="CreateProductCountPanel" Grid.Row="1" Grid.Column="4">
<Label Content="Количество"/>
<TextBox x:Name="CreateProductCountTextBox" PreviewTextInput="NumberValidationTextBox"/>
</StackPanel>
<StackPanel x:Name="CreateProductUnitsPanel" Grid.Row="1" Grid.Column="6">
<Label Content="Единицы измерения"/>
<ComboBox x:Name="CreateProductUnitsComboBox" IsEditable="True" IsReadOnly="True" Text="Выберите"/>
</StackPanel>
<Button x:Name="CreateProductCanselBtn" Content="Отменить" Grid.Column="4" Grid.Row="3" Style="{StaticResource ForDeleteBtn}" Click="CreateProductCanselBtn_Click"/>
<Button x:Name="CreateProductSaveBtn" Content="Сохранить" Grid.Column="6" Grid.Row="3" Style="{StaticResource ForAddBtn}" Click="CreateProductSaveBtn_Click"/>
</Grid>
<Grid x:Name="UpdateProductGrid" Grid.Column="1" Grid.Row="2" Visibility="Hidden">
<Grid.RowDefinitions>
<RowDefinition Height="4*"/>
<RowDefinition Height="5*"/>
<RowDefinition Height="2*"/>
<RowDefinition Height="5*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
</Grid.ColumnDefinitions>
<TextBox x:Name="ProductIdForUpdate" Visibility="Collapsed"/>
<Label Content="Редактирование продукта" Grid.Column="2" Grid.ColumnSpan="5" FontSize="20" HorizontalAlignment="Center"/>
<StackPanel x:Name="UpdateProductNamePanel" Grid.Row="1" Grid.Column="2">
<Label Content="Наименование"/>
<TextBox x:Name="UpdateProductNameTextBox"/>
</StackPanel>
<StackPanel x:Name="UpdateProductCountPanel" Grid.Row="1" Grid.Column="4">
<Label Content="Количество"/>
<TextBox x:Name="UpdateProductCountTextBox" PreviewTextInput="NumberValidationTextBox"/>
</StackPanel>
<StackPanel x:Name="UpdateProductUnitsPanel" Grid.Row="1" Grid.Column="6">
<Label Content="Единицы измерения"/>
<ComboBox x:Name="UpdateProductUnitsComboBox"/>
</StackPanel>
<Button x:Name="UpdateProductCanselBtn" Content="Отменить" Grid.Column="6" Grid.Row="3" Style="{StaticResource ForDeleteBtn}" Click="UpdateProductCanselBtn_Click"/>
<Button x:Name="UpdateProductSaveBtn" Content="Сохранить" Grid.Column="8" Grid.Row="3" Style="{StaticResource ForAddBtn}" Click="UpdateProductSaveBtn_Click"/>
</Grid>
</Grid>
</TabItem.Content>
</TabItem>
<TabItem x:Name="ProvidersTab">
<TabItem.Header>
<TextBlock Text="Поставщики"/>
</TabItem.Header>
<TabItem.Content>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="6*"/>
<RowDefinition Height="3*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Label Grid.Column="1" Content="Список поставщиков" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="24"/>
<Grid Grid.Column="1" Grid.Row="1">
<ScrollViewer>
<DataGrid x:Name="ProviderDataGrid" IsReadOnly="True" AutoGenerateColumns="True" HorizontalGridLinesBrush="DarkGray"
RowBackground="LightGray" AlternatingRowBackground="White" FontSize="14">
<DataGrid.Columns>
<DataGridTextColumn Header="ID" Binding="{Binding Path=Id}"/>
<DataGridTextColumn Header="Наименование" Binding="{Binding Path=Name}"/>
<DataGridTextColumn Header="Телефон" Binding="{Binding Path=Phone}"/>
</DataGrid.Columns>
</DataGrid>
</ScrollViewer>
</Grid>
<Grid x:Name="ProviderControlBtnGrid" Grid.Column="1" Grid.Row="2" Background="White" Visibility="Visible">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="*"/>
<RowDefinition Height="2*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Button x:Name="AddProviderBtn" Content="Создать" Grid.Row="1" Grid.Column="1" Style="{StaticResource ForAddBtn}" Click="AddProviderBtn_Click"/>
<Button x:Name="UpdateProviderBtn" Content="Изменить" Grid.Row="1" Grid.Column="3" Style="{StaticResource ForEditBtn}" Click="UpdateProviderBtn_Click"/>
<Button x:Name="DeleteProviderBtn" Content="Удалить" Grid.Row="1" Grid.Column="5" Style="{StaticResource ForDeleteBtn}" Click="DeleteProviderBtn_Click"/>
</Grid>
<Grid x:Name="CreateProviderGrid" Grid.Column="1" Grid.Row="2" Visibility="Hidden">
<Grid.RowDefinitions>
<RowDefinition Height="4*"/>
<RowDefinition Height="5*"/>
<RowDefinition Height="2*"/>
<RowDefinition Height="5*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
</Grid.ColumnDefinitions>
<Label Content="Добавление пользователя" Grid.Column="2" Grid.ColumnSpan="5" FontSize="20" HorizontalAlignment="Center"/>
<StackPanel x:Name="CreateProviderNamePanel" Grid.Row="1" Grid.Column="2">
<Label Content="Наименование"/>
<TextBox x:Name="CreateProviderNameTextBox"/>
</StackPanel>
<StackPanel x:Name="CreateProviderCountPanel" Grid.Row="1" Grid.Column="4">
<Label Content="Телефон"/>
<TextBox x:Name="CreateProviderTelTextBox"/>
</StackPanel>
<Button x:Name="CreateProviderCanselBtn" Content="Отменить" Grid.Column="4" Grid.Row="3" Style="{StaticResource ForDeleteBtn}" Click="CreateProviderCanselBtn_Click"/>
<Button x:Name="CreateProviderSaveBtn" Content="Сохранить" Grid.Column="6" Grid.Row="3" Style="{StaticResource ForAddBtn}" Click="CreateProviderSaveBtn_Click"/>
</Grid>
<Grid x:Name="UpdateProviderGrid" Grid.Column="1" Grid.Row="2" Visibility="Hidden">
<Grid.RowDefinitions>
<RowDefinition Height="4*"/>
<RowDefinition Height="5*"/>
<RowDefinition Height="2*"/>
<RowDefinition Height="5*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
</Grid.ColumnDefinitions>
<TextBox x:Name="ProviderIdForUpdate" Visibility="Collapsed"/>
<Label Content="Редактирование поставщика" Grid.Column="2" Grid.ColumnSpan="5" FontSize="20" HorizontalAlignment="Center"/>
<StackPanel x:Name="UpdateProviderNamePanel" Grid.Row="1" Grid.Column="2">
<Label Content="Наименование"/>
<TextBox x:Name="UpdateProviderNameTextBox"/>
</StackPanel>
<StackPanel x:Name="UpdateProviderCountPanel" Grid.Row="1" Grid.Column="4">
<Label Content="Телефон"/>
<TextBox x:Name="UpdateProviderTelTextBox"/>
</StackPanel>
<Button x:Name="UpdateProviderCanselBtn" Content="Отменить" Grid.Column="6" Grid.Row="3" Style="{StaticResource ForDeleteBtn}" Click="UpdateProviderCanselBtn_Click"/>
<Button x:Name="UpdateProviderSaveBtn" Content="Сохранить" Grid.Column="8" Grid.Row="3" Style="{StaticResource ForAddBtn}" Click="UpdateProviderSaveBtn_Click"/>
</Grid>
</Grid>
</TabItem.Content>
</TabItem>
<TabItem x:Name="RequestsTab">
<TabItem.Header>
<TextBlock Text="Запросы к поставщикам"/>
</TabItem.Header>
<TabItem.Content>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="6*"/>
<RowDefinition Height="3*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Label Grid.Column="1" Content="Список запросов" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="24"/>
<Grid Grid.Column="1" Grid.Row="1">
<ScrollViewer>
<DataGrid x:Name="RequestsDataGrid" IsReadOnly="True" AutoGenerateColumns="True" HorizontalGridLinesBrush="DarkGray"
RowBackground="LightGray" AlternatingRowBackground="White" FontSize="14">
<DataGrid.Columns>
<DataGridTextColumn Header="ID" Binding="{Binding Path=Id}"/>
<DataGridTextColumn Header="Наименование товара" Binding="{Binding Path=ProdName}"/>
<DataGridTextColumn Header="Количество" Binding="{Binding Path=Count}"/>
<DataGridTextColumn Header="Наименование поставщика" Binding="{Binding Path=ProviderName}"/>
<DataGridTextColumn Header="Единицы состояние" Binding="{Binding Path=State}"/>
</DataGrid.Columns>
</DataGrid>
</ScrollViewer>
</Grid>
<Grid x:Name="RequestsControlBtnGrid" Grid.Column="1" Grid.Row="2" Background="White" Visibility="Visible">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="*"/>
<RowDefinition Height="2*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Button x:Name="AddRequestBtn" Content="Создать" Grid.Row="1" Grid.Column="1" Style="{StaticResource ForAddBtn}" Click="AddRequestBtn_Click"/>
<Button x:Name="UpdateRequestBtn" Content="Закрыть" Grid.Row="1" Grid.Column="3" Style="{StaticResource ForEditBtn}" Click="UpdateRequestBtn_Click"/>
<Button x:Name="DeleteRequestBtn" Content="Удалить" Grid.Row="1" Grid.Column="5" Style="{StaticResource ForDeleteBtn}" Click="DeleteRequestBtn_Click"/>
</Grid>
<Grid x:Name="CreateRequestGrid" Grid.Column="1" Grid.Row="2" Visibility="Hidden">
<Grid.RowDefinitions>
<RowDefinition Height="4*"/>
<RowDefinition Height="5*"/>
<RowDefinition Height="2*"/>
<RowDefinition Height="5*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
</Grid.ColumnDefinitions>
<Label Content="Добавление запроса" Grid.Column="2" Grid.ColumnSpan="5" FontSize="20" HorizontalAlignment="Center"/>
<StackPanel x:Name="CreateRequestProductPanel" Grid.Row="1" Grid.Column="2">
<Label Content="Продукт"/>
<ComboBox x:Name="CreateRequestProductComboBox" IsEditable="True" IsReadOnly="True" Text="Выберите"/>
</StackPanel>
<StackPanel x:Name="CreateRequestCountPanel" Grid.Row="1" Grid.Column="4">
<Label Content="Количество"/>
<TextBox x:Name="CreateRequestCountTextBox" PreviewTextInput="NumberValidationTextBox"/>
</StackPanel>
<StackPanel x:Name="CreateRequestProviderPanel" Grid.Row="1" Grid.Column="6">
<Label Content="Поставщик"/>
<ComboBox x:Name="CreateRequestProviderComboBox" IsEditable="True" IsReadOnly="True" Text="Выберите"/>
</StackPanel>
<Button x:Name="CreateRequestCanselBtn" Content="Отменить" Grid.Column="4" Grid.Row="3" Style="{StaticResource ForDeleteBtn}" Click="CreateRequestCanselBtn_Click"/>
<Button x:Name="CreateRequestSaveBtn" Content="Сохранить" Grid.Column="6" Grid.Row="3" Style="{StaticResource ForAddBtn}" Click="CreateRequestSaveBtn_Click"/>
</Grid>
</Grid>
</TabItem.Content>
</TabItem>
</TabControl>
</Grid>
<Grid x:Name="GuestsGrid" Visibility="Hidden" Background="White">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="6*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="6*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Label Content="Клиенты" Grid.Column="1" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="30"/>
<Grid Grid.Row="1" Grid.Column="1">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="7*"/>
</Grid.RowDefinitions>
<StackPanel>
<Label Content="Поиск"/>
<TextBox x:Name="ClientSearchTextBox" KeyUp="ClientSearchTextBox_KeyUp"/>
</StackPanel>
<Grid Grid.Row="1">
<ScrollViewer>
<DataGrid x:Name="ClientsDataGrid" IsReadOnly="True" AutoGenerateColumns="True" HorizontalGridLinesBrush="DarkGray"
RowBackground="LightGray" AlternatingRowBackground="White" FontSize="14">
<DataGrid.Columns>
<DataGridTextColumn Header="ID" Binding="{Binding Path=Id}"/>
<DataGridTextColumn Header="ФИО" Binding="{Binding Path=Name}"/>
<DataGridTextColumn Header="№ паспорта" Binding="{Binding Path=Passport_number}"/>
<DataGridTextColumn Header="Телефон" Binding="{Binding Path=Phone}"/>
</DataGrid.Columns>
</DataGrid>
</ScrollViewer>
</Grid>
</Grid>
</Grid>
</Grid>
</Grid>
<Grid x:Name="LoginGrid" Visibility="Hidden" Background="White">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>