public async Task UpdateAsync(EmployeeRequireInput input) { var model = input.MapTo <EmployeeRequire>(); var job = _postinfo.Get(input.Job); var org = _organization.Get(input.Department); model.Title = org.DisplayName + "-" + job.Name; await _repository.UpdateAsync(model); }
public async Task <EmployeeRequireOutput> CreateAsync(EmployeeRequireInput input) { var model = input.MapTo <EmployeeRequire>(); var job = _postinfo.Get(input.Job); var org = _organization.Get(input.Department); model.Title = org.DisplayName + "-" + job.Name; var id = await _repository.InsertAndGetIdAsync(model); var ret = new EmployeeRequireOutput(); ret.InStanceId = model.Id.ToString(); return(ret); }