コード例 #1
0
        public async Task <ActionResult> Index()
        {
            IEnumerable <Investment> investments =
                await ServiceBus.InvokeAsync <GetInvestmentsRequest, IEnumerable <Investment> >(new GetInvestmentsRequest());

            return(View(investments));
        }
コード例 #2
0
        public async Task <ActionResult> Index(int id)
        {
            var investment = await ServiceBus.InvokeAsync <GetInvestmentRequest, Investment>(new GetInvestmentRequest { Id = id });

            return(View(investment));
        }