工作量配置调整

parent 0ef5a6e6
......@@ -381,7 +381,10 @@ public bool DrugtypeDelete(DrugpropRequest request)
/// <returns></returns>
public List<cof_workitem> GetWorkItems(int allotId, int type)
{
var list = _workitemRepository.GetEntities(t => t.AllotID == allotId && t.Type == type);
var list = (type > 0)
? _workitemRepository.GetEntities(t => t.AllotID == allotId && t.Type == type)
: _workitemRepository.GetEntities(t => t.AllotID == allotId);
return Mapper.Map<List<cof_workitem>>(list);
}
......@@ -410,6 +413,7 @@ public cof_workitem WorkItemUpdate(WorkItemRequest request)
throw new PerformanceException($"ID不存在 :{request.ID}");
workyear.Item = request.Item;
workyear.Type = request.Type;
if (!_workitemRepository.Update(workyear))
throw new PerformanceException("保存失败");
......
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