public OrdConsDTO GetApConsById(OrdConsDTO dto) { CiorappconsultAggDO aggDo = consAggService.findById(dto.Id_apcons); foreach (CiordInviteConsDO inviteConsDo in aggDo.getCiordInviteConsDO()) { if (inviteConsDo.Id_dep == UserManager.getInstance().CurrentDept.Id_dep) { if (inviteConsDo.Id_emp != null) { dto.Id_emp = inviteConsDo.Id_emp; } else { dto.Id_emp = UserManager.getInstance().CurrentUser.Id_user; } } } PsndocAggDO psn = psndocCrudService.findById(dto.Id_emp); if (psn != null) { dto.Emp_name = psn.getParentDO().Name; } return(dto); }
public XapAggDO <CiorappconsultAggDO> GetAggDo(string id) { CiorappconsultAggDO aggdo = consAggService.findById(id); if (aggdo == null) { return(null); } return(new XapAggDO <CiorappconsultAggDO>(consAggService, aggdo)); }
public void GetConsApData(string id_apcons, string type) { consAggDo = consAggService.findById(id_apcons); //if (type == CiDictCodeConst.CONS_RESPONSE) //{ // List<CiordInviteConsDO> invitelist = new List<CiordInviteConsDO>(); // foreach (CiordInviteConsDO obj in consAggDo.getCiordInviteConsDO()) // { // if (obj.Id_dep == UserManager.getInstance().CurrentDept.Id_dep) // { // invitelist.Add(obj); // } // } // consAggDo.setCiordInviteConsDO(invitelist.ToArray()); //} if (consAggDo == null) { return; } consAggDo = AuditResult(consAggDo); xapAggDo = new XapAggDO <CiorappconsultAggDO>(consAggService, consAggDo); //return xapAggDo; }