public IActionResult Active()
        {
            var aktifKayıt = service.GetAll(x => x.isActive == true).Data;

            if (aktifKayıt.Count != 0)
            {
                return(Ok(aktifKayıt));
            }
            return(NotFound("Aktif kayıt bulunamadı."));
        }
示例#2
0
        public IActionResult Create()
        {
            ViewModel mymodel = new ViewModel();

            mymodel.Forms        = formService.GetAll().Data;
            mymodel.FormElements = formElementService.GetAll().Data;
            return(View(mymodel));
        }
示例#3
0
        public IActionResult Index()
        {
            if (HttpContext.Session.GetString("Name") == null)
            {
                return(RedirectToAction("Login", "Admin"));
            }
            ViewModel mymodel = new ViewModel();

            mymodel.Forms            = formService.GetAll().Data;
            mymodel.FormElementItems = itemService.GetAll().Data;
            mymodel.FormElements     = formElementService.GetAll().Data;
            mymodel.FormArchives     = formArchiveService.GetAll().Data;
            return(View(mymodel));
        }