public async Task <IHttpActionResult> Get(int mockId, bool includesAccount = false) { try { var model = await _banking.Get(mockId, includesAccount : includesAccount); if (model == null) { return(NotFound()); } var map = _mapper.Map <Usermodel>(model); return(Ok(map)); } catch (Exception e) { return(InternalServerError(e)); } }
public async Task <IHttpActionResult> Get(int mockId) { try { var model = await _banking.Get(mockId, true); if (model != null) { var getallmodel = await _banking.GellAllAccounts(model.Id); if (getallmodel != null) { return(Ok(getallmodel)); } } } catch (Exception e) { InternalServerError(e); } return(NotFound()); }