/// <summary> /// Get Plot By Its Id /// </summary> /// <param name="plotId"></param> /// <returns></returns> public PlotViewModel GetPlotById(int plotId) { var result = _mapper.Map <Plot, PlotViewModel>(_plotService.GetPlot(plotId)); result.Payments = _paymentService .GetPayments() .Where(x => x.Subscription.Offer.PlotId == result.PlotId) .ToList().Select(_mapper.Map <Payment, PaymentViewModel>); return(result); }