コード例 #1
0
        public async Task<ActionResult> Index(Guid id)
        {
            var preconsented = await mediator.SendAsync(new GetDraftData<Preconsented>(id));

            var model = new PreconsentedViewModel(preconsented.AllFacilitiesPreconsented);

            return View(model);
        }
コード例 #2
0
        public async Task<ActionResult> Index(Guid id, PreconsentedViewModel model)
        {
            var preconsented = new Preconsented(id)
            {
                AllFacilitiesPreconsented = model.SelectedValue
            };

            await mediator.SendAsync(new SetDraftData<Preconsented>(id, preconsented));

            return RedirectToAction("Index", "Exporter");
        }