ปรับปรุงตามที่ได้รับแจ้ง

This commit is contained in:
LAPTOP-KB8JC2K2\acer
2021-09-16 11:52:23 +07:00
parent 3016221910
commit dacfe151cf
16 changed files with 100 additions and 9 deletions

View File

@@ -32,6 +32,10 @@ namespace TodoAPI2.Models
public decimal? limit { get; set; }
public int? fiscal_year_search { get; set; }
public int? theRound_search { get; set; }
public string active_mode { get; set; }
public List<eva_adjust_postponement_detail_quota_02InputModel> adjust_postponement_detail_quota_02_model;

View File

@@ -20,6 +20,9 @@ namespace TodoAPI2.Models
public int? theRound { get; set; }
public int? fiscal_year_search { get; set; }
public int? theRound_search { get; set; }
}
}

View File

@@ -77,6 +77,13 @@ namespace TodoAPI2.Models
var all_emp = emp.GetListByemployee_type(null, null);
i.item_managed_by = all_emp.ToList();
i.item_fiscal_year_search = (from x in _repository.Context.eva_adjust_postponement
select new external_linkageViewModel { external_id = x.fiscal_year, external_name = x.fiscal_year.ToString() }
).Distinct().OrderByDescending(x => x.external_id).ToList();
i.item_theRound_search = (from x in _repository.Context.eva_adjust_postponement
select new external_linkageViewModel { external_id = x.theRound, external_name = x.theRound.ToString() }
).Distinct().OrderByDescending(x => x.external_id).ToList();
return i;
}
public eva_adjust_postponement_quotaWithSelectionViewModel GetBlankItem()
@@ -85,6 +92,13 @@ namespace TodoAPI2.Models
var all_emp = emp.GetListByemployee_type(null, null);
i.item_managed_by = all_emp.ToList();
i.item_fiscal_year_search = (from x in _repository.Context.eva_adjust_postponement
select new external_linkageViewModel { external_id = x.fiscal_year, external_name = x.fiscal_year.ToString() }
).Distinct().OrderByDescending(x => x.external_id).ToList();
i.item_theRound_search = (from x in _repository.Context.eva_adjust_postponement
select new external_linkageViewModel { external_id = x.theRound, external_name = x.theRound.ToString() }
).Distinct().OrderByDescending(x => x.external_id).ToList();
return i;
}
@@ -112,6 +126,9 @@ namespace TodoAPI2.Models
&& (m_eva_adjust_postponement_quota.theRound == model.theRound || !model.theRound.HasValue)
&& !m_eva_adjust_postponement_quota.create_evaluation_id.HasValue
&& (!model.fiscal_year_search.HasValue || m_eva_adjust_postponement_quota.fiscal_year == model.fiscal_year_search)
&& (!model.theRound_search.HasValue || m_eva_adjust_postponement_quota.theRound == model.theRound_search)
orderby m_eva_adjust_postponement_quota.created descending
select new eva_adjust_postponement_quotaViewModel()
{

View File

@@ -8,6 +8,7 @@ namespace TodoAPI2.Models
public class eva_adjust_postponement_quotaWithSelectionViewModel: eva_adjust_postponement_quotaViewModel
{
public List<external_employeeViewModel> item_managed_by { get; set; }
public List<external_linkageViewModel> item_fiscal_year_search { get; set; }
public List<external_linkageViewModel> item_theRound_search { get; set; }
}
}