Manager. Mapping Template, изменен метод сравнения и обновления
This commit is contained in:
@@ -1,7 +1,5 @@
|
||||
using Microsoft.Extensions.Logging;
|
||||
using PARR.DAL.Contracts;
|
||||
using PARR.DAL.Models;
|
||||
using PARR.DAL.Services.Interfaces;
|
||||
using PARR.EsppTemplateSync.Domain;
|
||||
using PARR.EsppTemplateSync.Settings;
|
||||
using System.Globalization;
|
||||
|
||||
@@ -30,7 +28,7 @@ namespace PARR.EsppTemplateSync.Services
|
||||
return isSuccess;
|
||||
}
|
||||
|
||||
public Template? ParseString(string str)
|
||||
public EsppTemplate? ParseString(string str)
|
||||
{
|
||||
//TODO: а если формат нет тот? Все будет ок?
|
||||
|
||||
@@ -60,13 +58,26 @@ namespace PARR.EsppTemplateSync.Services
|
||||
var work = splittedContent[15].Trim();
|
||||
var worker = splittedContent[16].Trim();
|
||||
|
||||
var template = new Template
|
||||
var template = new EsppTemplate
|
||||
{
|
||||
Id = Guid.NewGuid(),
|
||||
DateCreated = DateTime.UtcNow,
|
||||
Name = name,
|
||||
IsActive = bool.Parse(isActive),
|
||||
StatusCode = (int)StatusTemplateEnum.Ok
|
||||
WorkGroup = workGroup,
|
||||
ShortDescription = shortDescription,
|
||||
//Category = category,
|
||||
ResponseArea = responseArea,
|
||||
Duration = duration,
|
||||
EK = ek,
|
||||
//Initiator = initiator,
|
||||
FullDescription = fullDescription,
|
||||
//ClosingCode = closingCode,
|
||||
Solution = solution,
|
||||
Process = process,
|
||||
SubProcess = subProcess,
|
||||
TNK = tnk,
|
||||
Work = work,
|
||||
//Worker = worker
|
||||
|
||||
};
|
||||
|
||||
return template;
|
||||
|
||||
Reference in New Issue
Block a user