ломаем

This commit is contained in:
bulatova_karina 2024-05-22 12:02:40 +04:00
parent 206cc0c6fc
commit 6322bbf9a0
7 changed files with 2 additions and 1 deletions

View File

@ -19,6 +19,7 @@ namespace ComputersShopBusinessLogic.MailWorker
protected string _popHost = string.Empty;
protected int _popPort;
private readonly IMessageInfoLogic _messageInfoLogic;
private readonly IClientLogic _clientLogic;
private readonly ILogger _logger;
public AbstractMailWorker(ILogger<AbstractMailWorker> logger, IMessageInfoLogic messageInfoLogic)
{
@ -75,6 +76,7 @@ namespace ComputersShopBusinessLogic.MailWorker
_logger.LogDebug("Check Mail: {Count} new mails", list.Count);
foreach (var mail in list)
{
mail.ClientId = _clientLogic.ReadElement(new() { Email = mail.SenderName })?.Id;
_messageInfoLogic.Create(mail);
}
}

View File

@ -26,7 +26,6 @@ namespace ComputersShopView
{
throw new InvalidOperationException($"Не найден атрибут типа ColumnAttribute для свойства {property.Name}");
}
// ищем нужный нам атрибут
if (attribute is ColumnAttribute columnAttr)
{
column.HeaderText = columnAttr.Title;