diff --git a/BlacksmithWorkshop/BlacksmithWorkshop/FormMails.Designer.cs b/BlacksmithWorkshop/BlacksmithWorkshop/FormMails.Designer.cs index f7b64aa..2b1ba02 100644 --- a/BlacksmithWorkshop/BlacksmithWorkshop/FormMails.Designer.cs +++ b/BlacksmithWorkshop/BlacksmithWorkshop/FormMails.Designer.cs @@ -50,6 +50,7 @@ Controls.Add(dataGridView); Name = "FormMails"; Text = "Сообщения"; + Load += FormMails_Load; ((System.ComponentModel.ISupportInitialize)dataGridView).EndInit(); ResumeLayout(false); } diff --git a/BlacksmithWorkshop/BlacksmithWorkshop/FormMails.cs b/BlacksmithWorkshop/BlacksmithWorkshop/FormMails.cs index 7045e30..adc6a93 100644 --- a/BlacksmithWorkshop/BlacksmithWorkshop/FormMails.cs +++ b/BlacksmithWorkshop/BlacksmithWorkshop/FormMails.cs @@ -48,5 +48,10 @@ namespace BlacksmithWorkshop MessageBoxIcon.Error); } } + + private void FormMails_Load(object sender, EventArgs e) + { + LoadData(); + } } } diff --git a/BlacksmithWorkshop/BlacksmithWorkshop/Program.cs b/BlacksmithWorkshop/BlacksmithWorkshop/Program.cs index bfc515d..84f5497 100644 --- a/BlacksmithWorkshop/BlacksmithWorkshop/Program.cs +++ b/BlacksmithWorkshop/BlacksmithWorkshop/Program.cs @@ -42,7 +42,7 @@ namespace BlacksmithWorkshop }); // - var timer = new System.Threading.Timer(new TimerCallback(MailCheck!), null, 0, 100000); + var timer = new System.Threading.Timer(new TimerCallback(MailCheck!), null, 0, 100); } catch (Exception ex) { diff --git a/BlacksmithWorkshop/BlacksmithWorkshopClientApp/Controllers/HomeController.cs b/BlacksmithWorkshop/BlacksmithWorkshopClientApp/Controllers/HomeController.cs index e942df2..876ca94 100644 --- a/BlacksmithWorkshop/BlacksmithWorkshopClientApp/Controllers/HomeController.cs +++ b/BlacksmithWorkshop/BlacksmithWorkshopClientApp/Controllers/HomeController.cs @@ -159,7 +159,7 @@ namespace BlacksmithWorkshopClientApp.Controllers return Redirect("~/Home/Enter"); } return - View(APIClient.GetRequest>($"api/client/getmessages?clientId ={ APIClient.Client.Id}")); + View(APIClient.GetRequest>($"api/client/getmessages?clientId ={APIClient.Client.Id}")); } } diff --git a/BlacksmithWorkshop/BlacksmithWorkshopRestApi/Controllers/MainController.cs b/BlacksmithWorkshop/BlacksmithWorkshopRestApi/Controllers/MainController.cs index 431c91f..0116c7f 100644 --- a/BlacksmithWorkshop/BlacksmithWorkshopRestApi/Controllers/MainController.cs +++ b/BlacksmithWorkshop/BlacksmithWorkshopRestApi/Controllers/MainController.cs @@ -70,7 +70,8 @@ namespace BlacksmithWorkshopRestApi.Controllers throw; } } - [HttpPost] + + [HttpPost] public void CreateOrder(OrderBindingModel model) { try diff --git a/BlacksmithWorkshop/BlacksmithWorkshopRestApi/appsettings.json b/BlacksmithWorkshop/BlacksmithWorkshopRestApi/appsettings.json index 5990d80..da85af4 100644 --- a/BlacksmithWorkshop/BlacksmithWorkshopRestApi/appsettings.json +++ b/BlacksmithWorkshop/BlacksmithWorkshopRestApi/appsettings.json @@ -6,12 +6,13 @@ } }, "AllowedHosts": "*", + "SmtpClientHost": "smtp.gmail.com", "SmtpClientPort": "587", "PopHost": "pop.gmail.com", "PopPort": "995", - "MailLogin": "labwork15kafis@gmail.com", - "MailPassword": "passlab15" + "MailLogin": "lab7rpp@gmail.com", + "MailPassword": "bvac xppu dkze ppcr" }