Replace Log.EmployeeName with Log.User, drop from database
This commit is contained in:
@@ -18,8 +18,7 @@ namespace MileageTraker.Web.ViewModels.CreateLog
|
||||
static ConfirmCreateLogViewModel()
|
||||
{
|
||||
Mapper.CreateMap<CreateLogViewModel, ConfirmCreateLogViewModel>()
|
||||
.ForMember(c => c.CityName, opt => opt.AddFormatter(new TitleCaseFormatter()))
|
||||
.ForMember(c => c.EmployeeName, opt => opt.AddFormatter(new TitleCaseFormatter()));
|
||||
.ForMember(c => c.CityName, opt => opt.AddFormatter(new TitleCaseFormatter()));
|
||||
}
|
||||
|
||||
public ConfirmCreateLogViewModel(CreateLogViewModel createLogViewModel)
|
||||
@@ -41,11 +40,6 @@ namespace MileageTraker.Web.ViewModels.CreateLog
|
||||
Miles = endOdometer - previousLog.EndOdometer;
|
||||
}
|
||||
|
||||
var matchingEmployeeName = dataService.GetEmployeeNameCorrected(EmployeeName);
|
||||
|
||||
if (!string.IsNullOrEmpty(matchingEmployeeName))
|
||||
EmployeeName = matchingEmployeeName;
|
||||
|
||||
var matchingCity = dataService.GetCitiesCorrected(CityName);
|
||||
|
||||
if (!string.IsNullOrEmpty(matchingCity))
|
||||
|
||||
Reference in New Issue
Block a user