Beispiel #1
0
        public async Task OnGetAsync(Guid id)
        {
            var dto = await _employeeAppService.GetEditorAsync(id);

            Employee          = ObjectMapper.Map <GetEmployeeForEditorOutput, EmployeeEditViewModel>(dto);
            Employee.Id       = id;
            Employee.Calendar = dto.IsGregorianCalendar ? Calendar.GregorianCalendar : Calendar.ChineseCalendar;

            Calendars = typeof(Calendar).GetDescriptionAndValue()
                        .Select(r =>
                                new SelectListItem(r.Key, r.Value.ToString())).ToList();
        }
Beispiel #2
0
 public virtual async Task <GetEmployeeForEditorOutput> GetEditorAsync(Guid id)
 {
     return(await _employeeAppService.GetEditorAsync(id));
 }