public string AddOrUpdateLoanRequestOkyAssistant(Guid loanRequestId, LoanRequestOkyDto loanRequestOkyDto) { try { LoanRequestRepository repository = new LoanRequestRepository(); LoanRequest loanRequest = repository.ActiveContext.LoanRequests.FirstOrDefault(lr => lr.Id == loanRequestId); if (loanRequest == null) { return("this request with this Request no :" + loanRequestOkyDto.ReqNo.ToString() + " is not there"); } this.TranslateLoanRequestOkyDto(loanRequestOkyDto, loanRequest); repository.Update(loanRequest); return("requestOkyAss added successfully"); } catch (Exception exception) { return(exception.Message); } }
public string UpdaeLoanRequest(LoanRequestDto loanRequestDto) { try { Guid id = loanRequestDto.Id; LoanRequestRepository repository = new LoanRequestRepository(); LoanRequest loanRequest = repository.ActiveContext.LoanRequests.Where(lr => lr.Id == id).FirstOrDefault(); if (loanRequest == null) { return("request is not there "); } loanRequest.InjectFrom <UnflatLoopValueInjection>(loanRequestDto); repository.Update(loanRequest); return("updated successfully"); } catch (Exception exception) { return(exception.Message); } }
public string AddOrUpdateLoanRequestOkyAssistant(Guid loanRequestId, LoanRequestOkyDto loanRequestOkyDto) { try { LoanRequestRepository repository = new LoanRequestRepository(); LoanRequest loanRequest = repository.ActiveContext.LoanRequests.FirstOrDefault(lr => lr.Id == loanRequestId); if (loanRequest == null) return "this request with this Request no :" + loanRequestOkyDto.ReqNo.ToString() + " is not there"; this.TranslateLoanRequestOkyDto(loanRequestOkyDto , loanRequest); repository.Update(loanRequest); return "requestOkyAss added successfully"; } catch (Exception exception) { return exception.Message; } }
public string UpdaeLoanRequest(LoanRequestDto loanRequestDto) { try { Guid id = loanRequestDto.Id; LoanRequestRepository repository = new LoanRequestRepository(); LoanRequest loanRequest = repository.ActiveContext.LoanRequests.Where(lr => lr.Id == id).FirstOrDefault(); if (loanRequest == null) return "request is not there "; loanRequest.InjectFrom<UnflatLoopValueInjection>(loanRequestDto); repository.Update(loanRequest); return "updated successfully"; } catch (Exception exception) { return exception.Message; } }