diff --git a/SoftwareInstallation/SoftwareInstallationClientApp/Views/Home/Mails.cshtml b/SoftwareInstallation/SoftwareInstallationClientApp/Views/Home/Mails.cshtml
index 0446c5d..2c4fc72 100644
--- a/SoftwareInstallation/SoftwareInstallationClientApp/Views/Home/Mails.cshtml
+++ b/SoftwareInstallation/SoftwareInstallationClientApp/Views/Home/Mails.cshtml
@@ -15,7 +15,7 @@
@{
if (Model == null)
{
-
Авторизируйтесь
+ Авторизируйтесь
return;
}
diff --git a/SoftwareInstallation/SoftwareInstallationClientApp/Views/Shared/_Layout.cshtml b/SoftwareInstallation/SoftwareInstallationClientApp/Views/Shared/_Layout.cshtml
index 12fbb2d..a2ec9df 100644
--- a/SoftwareInstallation/SoftwareInstallationClientApp/Views/Shared/_Layout.cshtml
+++ b/SoftwareInstallation/SoftwareInstallationClientApp/Views/Shared/_Layout.cshtml
@@ -28,6 +28,9 @@
Личные данные
+
+ Письма
+
Вход
diff --git a/SoftwareInstallation/SoftwareInstallationDatabaseImplement/Migrations/20230403203641_init.Designer.cs b/SoftwareInstallation/SoftwareInstallationDatabaseImplement/Migrations/20230423115628_init.Designer.cs
similarity index 85%
rename from SoftwareInstallation/SoftwareInstallationDatabaseImplement/Migrations/20230403203641_init.Designer.cs
rename to SoftwareInstallation/SoftwareInstallationDatabaseImplement/Migrations/20230423115628_init.Designer.cs
index 17e0647..ae608ff 100644
--- a/SoftwareInstallation/SoftwareInstallationDatabaseImplement/Migrations/20230403203641_init.Designer.cs
+++ b/SoftwareInstallation/SoftwareInstallationDatabaseImplement/Migrations/20230423115628_init.Designer.cs
@@ -12,7 +12,7 @@ using SoftwareInstallationDatabaseImplement;
namespace SoftwareInstallationDatabaseImplement.Migrations
{
[DbContext(typeof(SoftwareInstallationDatabase))]
- [Migration("20230403203641_init")]
+ [Migration("20230423115628_init")]
partial class init
{
///
@@ -97,6 +97,36 @@ namespace SoftwareInstallationDatabaseImplement.Migrations
b.ToTable("Implementers");
});
+ modelBuilder.Entity("SoftwareInstallationDatabaseImplement.Models.MessageInfo", b =>
+ {
+ b.Property("MessageId")
+ .HasColumnType("nvarchar(450)");
+
+ b.Property("Body")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("ClientId")
+ .HasColumnType("int");
+
+ b.Property("DateDelivery")
+ .HasColumnType("datetime2");
+
+ b.Property("SenderName")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("Subject")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.HasKey("MessageId");
+
+ b.HasIndex("ClientId");
+
+ b.ToTable("Messages");
+ });
+
modelBuilder.Entity("SoftwareInstallationDatabaseImplement.Models.Order", b =>
{
b.Property("Id")
@@ -186,6 +216,15 @@ namespace SoftwareInstallationDatabaseImplement.Migrations
b.ToTable("PackageComponents");
});
+ modelBuilder.Entity("SoftwareInstallationDatabaseImplement.Models.MessageInfo", b =>
+ {
+ b.HasOne("SoftwareInstallationDatabaseImplement.Models.Client", "Client")
+ .WithMany("Messages")
+ .HasForeignKey("ClientId");
+
+ b.Navigation("Client");
+ });
+
modelBuilder.Entity("SoftwareInstallationDatabaseImplement.Models.Order", b =>
{
b.HasOne("SoftwareInstallationDatabaseImplement.Models.Client", "Client")
@@ -232,6 +271,8 @@ namespace SoftwareInstallationDatabaseImplement.Migrations
modelBuilder.Entity("SoftwareInstallationDatabaseImplement.Models.Client", b =>
{
+ b.Navigation("Messages");
+
b.Navigation("Orders");
});
diff --git a/SoftwareInstallation/SoftwareInstallationDatabaseImplement/Migrations/20230403203641_init.cs b/SoftwareInstallation/SoftwareInstallationDatabaseImplement/Migrations/20230423115628_init.cs
similarity index 85%
rename from SoftwareInstallation/SoftwareInstallationDatabaseImplement/Migrations/20230403203641_init.cs
rename to SoftwareInstallation/SoftwareInstallationDatabaseImplement/Migrations/20230423115628_init.cs
index 2fce27d..7e72138 100644
--- a/SoftwareInstallation/SoftwareInstallationDatabaseImplement/Migrations/20230403203641_init.cs
+++ b/SoftwareInstallation/SoftwareInstallationDatabaseImplement/Migrations/20230423115628_init.cs
@@ -70,6 +70,27 @@ namespace SoftwareInstallationDatabaseImplement.Migrations
table.PrimaryKey("PK_Packages", x => x.Id);
});
+ migrationBuilder.CreateTable(
+ name: "Messages",
+ columns: table => new
+ {
+ MessageId = table.Column(type: "nvarchar(450)", nullable: false),
+ ClientId = table.Column(type: "int", nullable: true),
+ SenderName = table.Column(type: "nvarchar(max)", nullable: false),
+ DateDelivery = table.Column(type: "datetime2", nullable: false),
+ Subject = table.Column(type: "nvarchar(max)", nullable: false),
+ Body = table.Column(type: "nvarchar(max)", nullable: false)
+ },
+ constraints: table =>
+ {
+ table.PrimaryKey("PK_Messages", x => x.MessageId);
+ table.ForeignKey(
+ name: "FK_Messages_Clients_ClientId",
+ column: x => x.ClientId,
+ principalTable: "Clients",
+ principalColumn: "Id");
+ });
+
migrationBuilder.CreateTable(
name: "Orders",
columns: table => new
@@ -134,6 +155,11 @@ namespace SoftwareInstallationDatabaseImplement.Migrations
onDelete: ReferentialAction.Cascade);
});
+ migrationBuilder.CreateIndex(
+ name: "IX_Messages_ClientId",
+ table: "Messages",
+ column: "ClientId");
+
migrationBuilder.CreateIndex(
name: "IX_Orders_ClientId",
table: "Orders",
@@ -163,6 +189,9 @@ namespace SoftwareInstallationDatabaseImplement.Migrations
///
protected override void Down(MigrationBuilder migrationBuilder)
{
+ migrationBuilder.DropTable(
+ name: "Messages");
+
migrationBuilder.DropTable(
name: "Orders");
diff --git a/SoftwareInstallation/SoftwareInstallationDatabaseImplement/Migrations/SoftwareInstallationDatabaseModelSnapshot.cs b/SoftwareInstallation/SoftwareInstallationDatabaseImplement/Migrations/SoftwareInstallationDatabaseModelSnapshot.cs
index d719758..664788a 100644
--- a/SoftwareInstallation/SoftwareInstallationDatabaseImplement/Migrations/SoftwareInstallationDatabaseModelSnapshot.cs
+++ b/SoftwareInstallation/SoftwareInstallationDatabaseImplement/Migrations/SoftwareInstallationDatabaseModelSnapshot.cs
@@ -94,6 +94,36 @@ namespace SoftwareInstallationDatabaseImplement.Migrations
b.ToTable("Implementers");
});
+ modelBuilder.Entity("SoftwareInstallationDatabaseImplement.Models.MessageInfo", b =>
+ {
+ b.Property("MessageId")
+ .HasColumnType("nvarchar(450)");
+
+ b.Property("Body")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("ClientId")
+ .HasColumnType("int");
+
+ b.Property("DateDelivery")
+ .HasColumnType("datetime2");
+
+ b.Property("SenderName")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("Subject")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.HasKey("MessageId");
+
+ b.HasIndex("ClientId");
+
+ b.ToTable("Messages");
+ });
+
modelBuilder.Entity("SoftwareInstallationDatabaseImplement.Models.Order", b =>
{
b.Property("Id")
@@ -183,6 +213,15 @@ namespace SoftwareInstallationDatabaseImplement.Migrations
b.ToTable("PackageComponents");
});
+ modelBuilder.Entity("SoftwareInstallationDatabaseImplement.Models.MessageInfo", b =>
+ {
+ b.HasOne("SoftwareInstallationDatabaseImplement.Models.Client", "Client")
+ .WithMany("Messages")
+ .HasForeignKey("ClientId");
+
+ b.Navigation("Client");
+ });
+
modelBuilder.Entity("SoftwareInstallationDatabaseImplement.Models.Order", b =>
{
b.HasOne("SoftwareInstallationDatabaseImplement.Models.Client", "Client")
@@ -229,6 +268,8 @@ namespace SoftwareInstallationDatabaseImplement.Migrations
modelBuilder.Entity("SoftwareInstallationDatabaseImplement.Models.Client", b =>
{
+ b.Navigation("Messages");
+
b.Navigation("Orders");
});
diff --git a/SoftwareInstallation/SoftwareInstallationDatabaseImplement/OrderStorage.cs b/SoftwareInstallation/SoftwareInstallationDatabaseImplement/OrderStorage.cs
index ef0c0e6..5a52f00 100644
--- a/SoftwareInstallation/SoftwareInstallationDatabaseImplement/OrderStorage.cs
+++ b/SoftwareInstallation/SoftwareInstallationDatabaseImplement/OrderStorage.cs
@@ -72,7 +72,8 @@ namespace SoftwareInstallationDatabaseImplement.Implements
return queryWhere
.Include(x => x.Client)
.Include(x => x.Implementer)
- .Select(x => x.GetViewModel)
+ .Include(x => x.Package)
+ .Select(x => x.GetViewModel)
.ToList();
}
diff --git a/SoftwareInstallation/SoftwareInstallationRestApi/appsettings.json b/SoftwareInstallation/SoftwareInstallationRestApi/appsettings.json
index 697acfb..96f4ca2 100644
--- a/SoftwareInstallation/SoftwareInstallationRestApi/appsettings.json
+++ b/SoftwareInstallation/SoftwareInstallationRestApi/appsettings.json
@@ -11,6 +11,6 @@
"SmtpClientPort": "587",
"PopHost": "pop.mail.ru",
"PopPort": "995",
- "MailLogin": "ordersender228@mail.ru",
- "MailPassword": "v8czsQ8zztJc5wEHxKPN"
+ "MailLogin": "ilox_2018@mail.ru",
+ "MailPassword": "5Q1HSfrrha0Mg1UAGUZ8"
}
diff --git a/SoftwareInstallation/SoftwareInstallationView/App.config b/SoftwareInstallation/SoftwareInstallationView/App.config
index 400d322..34fa27c 100644
--- a/SoftwareInstallation/SoftwareInstallationView/App.config
+++ b/SoftwareInstallation/SoftwareInstallationView/App.config
@@ -5,7 +5,7 @@
-
-
+
+
\ No newline at end of file