예제 #1
0
        public ActionResult Create(CreateDerLayoutViewModel viewModel)
        {
            var request = new CreateOrUpdateDerLayoutRequest();
            request.Id = viewModel.Id;
            request.IsActive = viewModel.IsActive;
            request.Title = viewModel.Title;
            var response = _derService.CreateOrUpdateDerLayout(request);
            if (response.IsSuccess)
            {
                return RedirectToAction("Index");
            }

            return View(viewModel);
        }
예제 #2
0
        public ActionResult Edit(int id)
        {
            var viewModel = new CreateDerLayoutViewModel();
            var response = _derService.GetDerLayout(id);
            viewModel.Id = response.Id;
            viewModel.Title = response.Title;
            viewModel.IsActive = response.IsActive;

            return View(viewModel);
        }
예제 #3
0
        public ActionResult Create()
        {
            var viewModel = new CreateDerLayoutViewModel();

            return View(viewModel);
        }