Emelyanov A.S. LabWork_3_Hard #12
@ -81,19 +81,6 @@ namespace FishFactoryBusinessLogic.BusinessLogics
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
model.Status = newStatus;
|
||||
if (model.Status == OrderStatus.Выдан)
|
||||
model.DateImplement = DateTime.SpecifyKind(DateTime.Now, DateTimeKind.Utc);
|
||||
if (_orderStorage.Update(model) == null)
|
||||
{
|
||||
_logger.LogWarning("Update operation failed");
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
_logger.LogWarning("Changing status operation faled: Current-{Status}:required-{requiredStatus}.", model.Status, newStatus);
|
||||
throw new ArgumentException($"Невозможно приствоить статус {newStatus} заказу с текущим статусом {model.Status}");
|
||||
}
|
||||
public bool DeliveryOrder(OrderBindingModel model)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user