Add Force DTOs

This commit is contained in:
Evgeny Redikultsev
2024-10-12 21:30:21 +05:00
parent 2c5c5db43a
commit 7e54aa0407
64 changed files with 1237 additions and 216 deletions

View File

@@ -18,7 +18,7 @@ namespace DataAccess.DTOs
{
public abstract IUpdateStrategy<V> UpdateStrategy { get; }
public abstract T GetMaterialDTO(V source);
private IUpdateStrategy<ILibMaterial> libMaterialUpdateStrategy = new LibMaterialDTOUpdateStrategy();
//private IUpdateStrategy<ILibMaterial> libMaterialUpdateStrategy = new LibMaterialDTOUpdateStrategy();
public Dictionary<(Guid id, Type type), ISaveable> ReferenceDictionary { get; set; }
public IShiftTraceLogger TraceLogger { get; set; }
@@ -29,7 +29,7 @@ namespace DataAccess.DTOs
try
{
UpdateStrategy.Update(newItem, source);
libMaterialUpdateStrategy.Update(newItem, source);
//libMaterialUpdateStrategy.Update(newItem, source);
}
catch (Exception ex)
{
@@ -43,9 +43,7 @@ namespace DataAccess.DTOs
private void Check()
{
var checkLogic = new CheckConvertLogic<T, V>();
checkLogic.ConvertStrategy = this;
checkLogic.TraceLogger = TraceLogger;
var checkLogic = new CheckConvertLogic<T, V>(this);
checkLogic.Check();
}