diff --git a/FunctionWindow.axaml b/FunctionWindow.axaml
old mode 100755
new mode 100644
index 2dccebc..2b0f2f9
--- a/FunctionWindow.axaml
+++ b/FunctionWindow.axaml
@@ -9,7 +9,7 @@
-
+
@@ -25,4 +25,4 @@
-
+
\ No newline at end of file
diff --git a/FunctionWindow.axaml.cs b/FunctionWindow.axaml.cs
old mode 100755
new mode 100644
diff --git a/MainWindow.axaml.cs b/MainWindow.axaml.cs
index f3d1264..2c01e5b 100755
--- a/MainWindow.axaml.cs
+++ b/MainWindow.axaml.cs
@@ -3,6 +3,7 @@ using System.Linq;
using Avalonia.Controls;
using Avalonia.Interactivity;
using demo_hard.Models;
+//using demo_hard.Models;
using Tmds.DBus.Protocol;
namespace demo_hard;
diff --git a/Models/Client.cs b/Models/Client.cs
new file mode 100644
index 0000000..95c8ac5
--- /dev/null
+++ b/Models/Client.cs
@@ -0,0 +1,23 @@
+using System;
+using System.Collections.Generic;
+
+namespace demo_hard.Models;
+
+public partial class Client
+{
+ public int Id { get; set; }
+
+ public string Fio { get; set; } = null!;
+
+ public int ClientCode { get; set; }
+
+ public string Passport { get; set; } = null!;
+
+ public DateOnly Birthday { get; set; }
+
+ public string Address { get; set; } = null!;
+
+ public string Email { get; set; } = null!;
+
+ public string Password { get; set; } = null!;
+}
diff --git a/Models/Employee.cs b/Models/Employee.cs
new file mode 100644
index 0000000..a4dec6e
--- /dev/null
+++ b/Models/Employee.cs
@@ -0,0 +1,19 @@
+using System;
+using System.Collections.Generic;
+
+namespace demo_hard.Models;
+
+public partial class Employee
+{
+ public int EmployeId { get; set; }
+
+ public int RoleId { get; set; }
+
+ public string Fio { get; set; } = null!;
+
+ public string EmployeLogin { get; set; } = null!;
+
+ public string EmployePassword { get; set; } = null!;
+
+ public string? EmployePhoto { get; set; }
+}
diff --git a/Models/LastEnter.cs b/Models/LastEnter.cs
new file mode 100644
index 0000000..20980f0
--- /dev/null
+++ b/Models/LastEnter.cs
@@ -0,0 +1,13 @@
+using System;
+using System.Collections.Generic;
+
+namespace demo_hard.Models;
+
+public partial class LastEnter
+{
+ public int EmployeId { get; set; }
+
+ public DateTime EnterDatetime { get; set; }
+
+ public string EnterType { get; set; } = null!;
+}
diff --git a/Models/Order.cs b/Models/Order.cs
new file mode 100644
index 0000000..e918654
--- /dev/null
+++ b/Models/Order.cs
@@ -0,0 +1,25 @@
+using System;
+using System.Collections.Generic;
+
+namespace demo_hard.Models;
+
+public partial class Order
+{
+ public int Id { get; set; }
+
+ public string OrderCode { get; set; } = null!;
+
+ public DateOnly OrderDate { get; set; }
+
+ public TimeOnly OrderTime { get; set; }
+
+ public int ClientCode { get; set; }
+
+ public int ServiceId { get; set; }
+
+ public string Status { get; set; } = null!;
+
+ public DateOnly? DateClose { get; set; }
+
+ public int RentalTime { get; set; }
+}
diff --git a/Models/Role.cs b/Models/Role.cs
new file mode 100644
index 0000000..0915894
--- /dev/null
+++ b/Models/Role.cs
@@ -0,0 +1,11 @@
+using System;
+using System.Collections.Generic;
+
+namespace demo_hard.Models;
+
+public partial class Role
+{
+ public int RoleId { get; set; }
+
+ public string RoleName { get; set; } = null!;
+}
diff --git a/Models/Service.cs b/Models/Service.cs
new file mode 100644
index 0000000..89ab885
--- /dev/null
+++ b/Models/Service.cs
@@ -0,0 +1,15 @@
+using System;
+using System.Collections.Generic;
+
+namespace demo_hard.Models;
+
+public partial class Service
+{
+ public int Id { get; set; }
+
+ public string ServiceName { get; set; } = null!;
+
+ public string ServiceCode { get; set; } = null!;
+
+ public string ServiceCost { get; set; } = null!;
+}
diff --git a/Models/User2Context.cs b/Models/User2Context.cs
new file mode 100644
index 0000000..e961e16
--- /dev/null
+++ b/Models/User2Context.cs
@@ -0,0 +1,162 @@
+using System;
+using System.Collections.Generic;
+using Microsoft.EntityFrameworkCore;
+
+namespace demo_hard.Models;
+
+public partial class User2Context : DbContext
+{
+ public User2Context()
+ {
+ }
+
+ public User2Context(DbContextOptions options)
+ : base(options)
+ {
+ }
+
+ public virtual DbSet Clients { get; set; }
+
+ public virtual DbSet Employees { get; set; }
+
+ public virtual DbSet LastEnters { get; set; }
+
+ public virtual DbSet Orders { get; set; }
+
+ public virtual DbSet Roles { get; set; }
+
+ public virtual DbSet Services { get; set; }
+
+ protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
+#warning To protect potentially sensitive information in your connection string, you should move it out of source code. You can avoid scaffolding the connection string by using the Name= syntax to read it from configuration - see https://go.microsoft.com/fwlink/?linkid=2131148. For more guidance on storing connection strings, see https://go.microsoft.com/fwlink/?LinkId=723263.
+ => optionsBuilder.UseNpgsql("Host=45.67.56.214;Port=5454;USERNAME=user2;DATABASE=user2;Password=hGcLvi0i");
+
+ protected override void OnModelCreating(ModelBuilder modelBuilder)
+ {
+ modelBuilder.Entity(entity =>
+ {
+ entity.HasKey(e => e.Id).HasName("clients_pk");
+
+ entity.ToTable("clients");
+
+ entity.Property(e => e.Id).HasColumnName("id");
+ entity.Property(e => e.Address)
+ .HasColumnType("character varying")
+ .HasColumnName("address");
+ entity.Property(e => e.Birthday).HasColumnName("birthday");
+ entity.Property(e => e.ClientCode).HasColumnName("client_code");
+ entity.Property(e => e.Email)
+ .HasColumnType("character varying")
+ .HasColumnName("email");
+ entity.Property(e => e.Fio)
+ .HasColumnType("character varying")
+ .HasColumnName("fio");
+ entity.Property(e => e.Passport)
+ .HasColumnType("character varying")
+ .HasColumnName("passport");
+ entity.Property(e => e.Password)
+ .HasColumnType("character varying")
+ .HasColumnName("password");
+ });
+
+ modelBuilder.Entity(entity =>
+ {
+ entity.HasKey(e => e.EmployeId).HasName("employees_pk");
+
+ entity.ToTable("employees");
+
+ entity.Property(e => e.EmployeId)
+ .ValueGeneratedNever()
+ .HasColumnName("employe_id");
+ entity.Property(e => e.EmployeLogin)
+ .HasColumnType("character varying")
+ .HasColumnName("employe_login");
+ entity.Property(e => e.EmployePassword)
+ .HasColumnType("character varying")
+ .HasColumnName("employe_password");
+ entity.Property(e => e.EmployePhoto)
+ .HasColumnType("character varying")
+ .HasColumnName("employe_photo");
+ entity.Property(e => e.Fio)
+ .HasColumnType("character varying")
+ .HasColumnName("fio");
+ entity.Property(e => e.RoleId).HasColumnName("role_id");
+ });
+
+ modelBuilder.Entity(entity =>
+ {
+ entity.HasKey(e => e.EmployeId).HasName("last_enter_pk");
+
+ entity.ToTable("last_enter");
+
+ entity.Property(e => e.EmployeId)
+ .ValueGeneratedNever()
+ .HasColumnName("employe_id");
+ entity.Property(e => e.EnterDatetime)
+ .HasColumnType("timestamp without time zone")
+ .HasColumnName("enter_datetime");
+ entity.Property(e => e.EnterType)
+ .HasColumnType("character varying")
+ .HasColumnName("enter_type");
+ });
+
+ modelBuilder.Entity(entity =>
+ {
+ entity.HasKey(e => e.Id).HasName("orders_pk");
+
+ entity.ToTable("orders");
+
+ entity.Property(e => e.Id).HasColumnName("id");
+ entity.Property(e => e.ClientCode).HasColumnName("client_code");
+ entity.Property(e => e.DateClose).HasColumnName("date_close");
+ entity.Property(e => e.OrderCode)
+ .HasColumnType("character varying")
+ .HasColumnName("order_code");
+ entity.Property(e => e.OrderDate).HasColumnName("order_date");
+ entity.Property(e => e.OrderTime).HasColumnName("order_time");
+ entity.Property(e => e.RentalTime).HasColumnName("rental_time");
+ entity.Property(e => e.ServiceId).HasColumnName("service_id");
+ entity.Property(e => e.Status)
+ .HasColumnType("character varying")
+ .HasColumnName("status");
+ });
+
+ modelBuilder.Entity(entity =>
+ {
+ entity.HasKey(e => e.RoleId).HasName("roles_pk");
+
+ entity.ToTable("roles");
+
+ entity.Property(e => e.RoleId).HasColumnName("role_id");
+ entity.Property(e => e.RoleName)
+ .HasColumnType("character varying")
+ .HasColumnName("role_name");
+ });
+
+ modelBuilder.Entity(entity =>
+ {
+ entity.HasKey(e => e.Id).HasName("service_pk");
+
+ entity.ToTable("service");
+
+ entity.HasIndex(e => e.ServiceCode, "service_unique").IsUnique();
+
+ entity.Property(e => e.Id)
+ .ValueGeneratedNever()
+ .HasColumnName("id");
+ entity.Property(e => e.ServiceCode)
+ .HasColumnType("character varying")
+ .HasColumnName("service_code");
+ entity.Property(e => e.ServiceCost)
+ .HasColumnType("character varying")
+ .HasColumnName("service_cost");
+ entity.Property(e => e.ServiceName)
+ .HasColumnType("character varying")
+ .HasColumnName("service_name");
+ });
+
+ OnModelCreatingPartial(modelBuilder);
+ }
+
+ partial void OnModelCreatingPartial(ModelBuilder modelBuilder);
+}
diff --git a/bin/Debug/net8.0/demo_hard.dll b/bin/Debug/net8.0/demo_hard.dll
index 977eefc..40e9485 100644
Binary files a/bin/Debug/net8.0/demo_hard.dll and b/bin/Debug/net8.0/demo_hard.dll differ
diff --git a/bin/Debug/net8.0/demo_hard.pdb b/bin/Debug/net8.0/demo_hard.pdb
index 95f5ec6..5b640e6 100644
Binary files a/bin/Debug/net8.0/demo_hard.pdb and b/bin/Debug/net8.0/demo_hard.pdb differ
diff --git a/obj/Debug/net8.0/Avalonia/demo_hard.dll b/obj/Debug/net8.0/Avalonia/demo_hard.dll
index 977eefc..40e9485 100644
Binary files a/obj/Debug/net8.0/Avalonia/demo_hard.dll and b/obj/Debug/net8.0/Avalonia/demo_hard.dll differ
diff --git a/obj/Debug/net8.0/Avalonia/demo_hard.pdb b/obj/Debug/net8.0/Avalonia/demo_hard.pdb
index 95f5ec6..5b640e6 100644
Binary files a/obj/Debug/net8.0/Avalonia/demo_hard.pdb and b/obj/Debug/net8.0/Avalonia/demo_hard.pdb differ
diff --git a/obj/Debug/net8.0/Avalonia/resources b/obj/Debug/net8.0/Avalonia/resources
index b9f9977..8b113d2 100644
Binary files a/obj/Debug/net8.0/Avalonia/resources and b/obj/Debug/net8.0/Avalonia/resources differ
diff --git a/obj/Debug/net8.0/demo_hard.AssemblyInfo.cs b/obj/Debug/net8.0/demo_hard.AssemblyInfo.cs
index 0892abb..e38c7c2 100644
--- a/obj/Debug/net8.0/demo_hard.AssemblyInfo.cs
+++ b/obj/Debug/net8.0/demo_hard.AssemblyInfo.cs
@@ -13,7 +13,7 @@ using System.Reflection;
[assembly: System.Reflection.AssemblyCompanyAttribute("demo_hard")]
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
-[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+e8319cee614431d1a9b9d1c9878b71cec61259a0")]
+[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+c91804fd9638a5631768e0f8d9252b7076859bc2")]
[assembly: System.Reflection.AssemblyProductAttribute("demo_hard")]
[assembly: System.Reflection.AssemblyTitleAttribute("demo_hard")]
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
diff --git a/obj/Debug/net8.0/demo_hard.AssemblyInfoInputs.cache b/obj/Debug/net8.0/demo_hard.AssemblyInfoInputs.cache
index bf27586..699269e 100644
--- a/obj/Debug/net8.0/demo_hard.AssemblyInfoInputs.cache
+++ b/obj/Debug/net8.0/demo_hard.AssemblyInfoInputs.cache
@@ -1 +1 @@
-946f5a24939ef6e23b67d0109d55ffc53297d201f2384d6e1f3038aa1754ec52
+c7751d4c859009911ef8abab35f4913fc67078eaa69e0f8e455111b451d12c80
diff --git a/obj/Debug/net8.0/demo_hard.csproj.CoreCompileInputs.cache b/obj/Debug/net8.0/demo_hard.csproj.CoreCompileInputs.cache
index 833278b..0248619 100644
--- a/obj/Debug/net8.0/demo_hard.csproj.CoreCompileInputs.cache
+++ b/obj/Debug/net8.0/demo_hard.csproj.CoreCompileInputs.cache
@@ -1 +1 @@
-ce241f4d95563f593c3fa12dec7919781dc53e55b898ac2536acd7743b2edee4
+a04853a7f7fe215ad2bf6414aca2370fba026abbead53c35ab1138596aea4ab4
diff --git a/obj/Debug/net8.0/demo_hard.csproj.FileListAbsolute.txt b/obj/Debug/net8.0/demo_hard.csproj.FileListAbsolute.txt
index 963f19c..5ce91f8 100755
--- a/obj/Debug/net8.0/demo_hard.csproj.FileListAbsolute.txt
+++ b/obj/Debug/net8.0/demo_hard.csproj.FileListAbsolute.txt
@@ -159,6 +159,3 @@
/home/class_student/RiderProjects/demo_hard/demo_hard/obj/Debug/net8.0/demo_hard.csproj.Up2Date
/home/class_student/RiderProjects/demo_hard/demo_hard/obj/Debug/net8.0/demo_hard.genruntimeconfig.cache
/home/class_student/RiderProjects/demo_hard/demo_hard/obj/Debug/net8.0/ref/demo_hard.dll
-/home/class_student/RiderProjects/demo_hard/demo_hard/obj/Debug/net8.0/demo_hard.dll
-/home/class_student/RiderProjects/demo_hard/demo_hard/obj/Debug/net8.0/refint/demo_hard.dll
-/home/class_student/RiderProjects/demo_hard/demo_hard/obj/Debug/net8.0/demo_hard.pdb
diff --git a/obj/Debug/net8.0/demo_hard.dll b/obj/Debug/net8.0/demo_hard.dll
index 983f66d..4a3586c 100644
Binary files a/obj/Debug/net8.0/demo_hard.dll and b/obj/Debug/net8.0/demo_hard.dll differ
diff --git a/obj/Debug/net8.0/demo_hard.pdb b/obj/Debug/net8.0/demo_hard.pdb
index b384812..2c0ec24 100644
Binary files a/obj/Debug/net8.0/demo_hard.pdb and b/obj/Debug/net8.0/demo_hard.pdb differ
diff --git a/obj/Debug/net8.0/ref/demo_hard.dll b/obj/Debug/net8.0/ref/demo_hard.dll
index 56fb3a5..bee1b91 100644
Binary files a/obj/Debug/net8.0/ref/demo_hard.dll and b/obj/Debug/net8.0/ref/demo_hard.dll differ
diff --git a/obj/Debug/net8.0/refint/Avalonia/demo_hard.dll b/obj/Debug/net8.0/refint/Avalonia/demo_hard.dll
index 56fb3a5..bee1b91 100644
Binary files a/obj/Debug/net8.0/refint/Avalonia/demo_hard.dll and b/obj/Debug/net8.0/refint/Avalonia/demo_hard.dll differ
diff --git a/obj/Debug/net8.0/refint/demo_hard.dll b/obj/Debug/net8.0/refint/demo_hard.dll
index 8b1cb62..a23f939 100644
Binary files a/obj/Debug/net8.0/refint/demo_hard.dll and b/obj/Debug/net8.0/refint/demo_hard.dll differ