コード例 #1
0
        public IActionResult Test()
        {
            var viewModel = new DtoA
            {
                Id    = 3,
                DtoBs = new[]
                {
                    new DtoB {
                        Id = 4,
                    },
                    new DtoB
                    {
                        Id    = 5,
                        DtoCs = new[]
                        {
                            new DtoC {
                                Id = 6
                            },
                            new DtoC {
                                Id = 7
                            },
                        }
                    },
                }
            };

            return(View(viewModel));
        }
コード例 #2
0
 public IActionResult PostTest(DtoA dtoA)
 {
     return(View(dtoA));
 }