Commit a5d88318 by lcx

Merge tag '划拨提交' into develop

parents fef4968b efe7dd73
......@@ -274,8 +274,8 @@ public bool Applicat(CostTransferRequest request)
if (request.Adopted.Department == request.Applicant.Department && request.Adopted.UnitType == request.Applicant.UnitType)
throw new PerformanceException("参数错误,提交科室相同");
var item = request.Items.Where(t => string.IsNullOrEmpty(t.Source) || string.IsNullOrEmpty(t.Category));
if (item.Count() > 0) throw new PerformanceException("参数错误,申请信息填写不完整");
if (request.Items.Any(t => string.IsNullOrEmpty(t.Category))
|| request.Items.Any(t => t.IsUseRatio == 1 && string.IsNullOrEmpty(t.Source))) throw new PerformanceException("参数错误,申请信息填写不完整");
var allot = perallotRepository.GetEntity(t => t.ID == request.AllotId);
var allotStatus = new[] { (int)AllotStates.GenerateSucceed, (int)AllotStates.Archive };
......
......@@ -1551,7 +1551,7 @@ private List<ag_secondallot> SecondList(per_allot allot, List<res_account> accou
};
});
var enums = EnumHelper.GetItems<UnitType>();
return result.Where(w => w.RealGiveFee != 0)
return result.Where(w => w.RealGiveFee.HasValue && w.RealGiveFee != 0)
.OrderBy(t => t.Status == 4 ? 2 : t.Status)
.ThenBy(t => enums.FirstOrDefault(f => f.Name == t.UnitType)?.Value)
.ThenBy(t => t.Department)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment