แก้ไข op หลายข้อ

This commit is contained in:
LAPTOP-KB8JC2K2\acer
2021-04-28 14:12:17 +07:00
parent b84b7cda5f
commit 9f106272c8
6 changed files with 18 additions and 16 deletions

View File

@@ -94,9 +94,9 @@ namespace TodoAPI2.Models
select x.fiscal_year).Distinct().OrderBy(x => x.Value).ToList();
i.item_eva_year = fill_list_number((from x in _repository.Context.eva_adjust_postponement
select x.fiscal_year).Distinct().OrderBy(x => x.Value).ToList());
select x.fiscal_year).Distinct().OrderByDescending(x => x.Value).ToList());
i.item_eva_no = fill_list_number((from x in _repository.Context.eva_adjust_postponement
select x.theRound).Distinct().OrderBy(x => x.Value).ToList());
select x.theRound).Distinct().OrderByDescending(x => x.Value).ToList());
return i;
}
@@ -104,9 +104,9 @@ namespace TodoAPI2.Models
{
var i = new eva_self_reviewWithSelectionViewModel();
i.item_eva_year = fill_list_number((from x in _repository.Context.eva_adjust_postponement
select x.fiscal_year).Distinct().OrderBy(x => x.Value).ToList());
select x.fiscal_year).Distinct().OrderByDescending(x => x.Value).ToList());
i.item_eva_no = fill_list_number((from x in _repository.Context.eva_adjust_postponement
select x.theRound).Distinct().OrderBy(x => x.Value).ToList());
select x.theRound).Distinct().OrderByDescending(x => x.Value).ToList());
return i;
@@ -147,14 +147,16 @@ namespace TodoAPI2.Models
&& (!model.eva_no.HasValue || fk_eva_adjust_postponementResult1.theRound == model.eva_no)
&& fk_eva_adjust_postponementResult1.fiscal_year.HasValue
orderby m_eva_self_review.created descending
orderby
(fk_eva_adjust_postponementResult1.fiscal_year.HasValue ? fk_eva_adjust_postponementResult1.fiscal_year : fk_eva_adjust_postponementResult2.fiscal_year) descending,
(fk_eva_adjust_postponementResult1.theRound.HasValue ? fk_eva_adjust_postponementResult1.theRound : fk_eva_adjust_postponementResult2.theRound) descending
select new eva_self_reviewViewModel()
{
id = m_eva_self_review.id,
adjust_postponement_id = m_eva_self_review.adjust_postponement_id,
adjust_postponement_quota_id = m_eva_self_review.adjust_postponement_quota_id,
employee_id = m_eva_self_review.employee_id,
eva_year = fk_eva_adjust_postponementResult1.fiscal_year.HasValue? fk_eva_adjust_postponementResult1.fiscal_year : fk_eva_adjust_postponementResult2.fiscal_year,
eva_year = (fk_eva_adjust_postponementResult1.fiscal_year.HasValue? fk_eva_adjust_postponementResult1.fiscal_year : fk_eva_adjust_postponementResult2.fiscal_year),
eva_no = fk_eva_adjust_postponementResult1.theRound.HasValue? fk_eva_adjust_postponementResult1.theRound : fk_eva_adjust_postponementResult2.theRound,
adjust_postponement_id_eva_adjust_postponement_fiscal_year = fk_eva_adjust_postponementResult1.fiscal_year.HasValue ? fk_eva_adjust_postponementResult1.fiscal_year : fk_eva_adjust_postponementResult2.fiscal_year,
@@ -166,7 +168,7 @@ namespace TodoAPI2.Models
Created = m_eva_self_review.created,
Updated = m_eva_self_review.updated
}
).OrderBy(x => x.eva_year * 10 + x.eva_no).ToList();
).ToList();
return data;
}

View File

@@ -440,7 +440,7 @@ namespace TodoAPI2.Models
var i = new external_linkageViewModel();
i.external_id = Convert.ToInt32(dr["id"]);
//i.id_guid = Guid.Parse(dr["id"].ToString());
i.external_code = dr["theRound"].ToString();
i.external_code = dr["fiscal_year"].ToString() + dr["theRound"].ToString();
i.external_name = dr["theRound"].ToString() + "/" + dr["fiscal_year"].ToString();
result.Add(i);
}

View File

@@ -58,7 +58,7 @@ namespace TodoAPI2.Models
var entity = _repository.Get(id);
var i = Mapper.Map<rep_eva01WithSelectionViewModel>(entity);
i.item_org_id = (from x in ext.GetSortingDep() select x).ToList();
i.item_round_id = (from x in ext.GetEvaRound() select x).ToList();
i.item_round_id = (from x in ext.GetEvaRound() orderby x.external_code descending select x).ToList();
return i;
@@ -67,7 +67,7 @@ namespace TodoAPI2.Models
{
var i = new rep_eva01WithSelectionViewModel();
i.item_org_id = (from x in ext.GetSortingDep() select x).ToList();
i.item_round_id = (from x in ext.GetEvaRound() select x).ToList();
i.item_round_id = (from x in ext.GetEvaRound() orderby x.external_code descending select x).ToList();
return i;

View File

@@ -58,7 +58,7 @@ namespace TodoAPI2.Models
var entity = _repository.Get(id);
var i = Mapper.Map<rep_eva02WithSelectionViewModel>(entity);
i.item_org_id = (from x in ext.GetSortingDep() select x).ToList();
i.item_round_id = (from x in ext.GetEvaRound() select x).ToList();
i.item_round_id = (from x in ext.GetEvaRound() orderby x.external_code descending select x).ToList();
return i;
@@ -67,7 +67,7 @@ namespace TodoAPI2.Models
{
var i = new rep_eva02WithSelectionViewModel();
i.item_org_id = (from x in ext.GetSortingDep() select x).ToList();
i.item_round_id = (from x in ext.GetEvaRound() select x).ToList();
i.item_round_id = (from x in ext.GetEvaRound() orderby x.external_code descending select x).ToList();
return i;

View File

@@ -137,9 +137,9 @@
<img src="~/BackendScript/images/evaluation.png" class="default">
<img src="~/BackendScript/images/evaluation.png" class="active">
</div>
<span class="desktop-hide">ประวัติเงินเดือนและการเลื่อนเงินเดือน</span>
<span style="font-weight:bold;" class="desktop-hide">ประวัติเงินเดือนและการเลื่อนเงินเดือน</span>
</a>
<ul class="sub" id="mymenu"></ul>
<ul style="font-weight:bold;" class="sub" id="mymenu"></ul>
</li>
@@ -148,7 +148,7 @@
<div>
<i class="fa fa-power-off" style="font-size: 19px;"></i>
</div>
<span class="desktop-hide">ออกจากระบบ</span>
<span style="font-weight:bold;" class="desktop-hide">ออกจากระบบ</span>
</a>
</li>

View File

@@ -638,7 +638,7 @@ function GetMenu(module, mymenu, menu_url){
var tag = '';
if(typeof(data.submenu) === "undefined"){
tag = '<li class="sub-menu">';
tag += '<li><a href="javascript:window_open_from_root('+tmp+data.url+tmp+');" class=""><span class="menu-dot">&middot;</span>'+data.name+'</a>';
tag += '<li><a style="font-weight:bold;" href="javascript:window_open_from_root('+tmp+data.url+tmp+');" class=""><span class="menu-dot">&middot;</span>'+data.name+'</a>';
tag += '</li>';
}else{
tag = '<a href="#" class="disabled">'+data.name+'</a>';