public async Task <IActionResult> Edit(int id, [Bind("AdTId,Term,TermAmount,TermDate,AdYear,FTId")] AdTypeFee adTypeFee)
        {
            if (string.IsNullOrEmpty(HttpContext.Session.GetString("Session1")))
            {
                return(RedirectToAction("UserLogin", "Login"));
            }
            if (id != adTypeFee.AdTId)
            {
                return(NotFound());
            }

            if (ModelState.IsValid)
            {
                try
                {
                    _context.Update(adTypeFee);
                    await _context.SaveChangesAsync();
                }
                catch (DbUpdateConcurrencyException)
                {
                    if (!AdTypeFeeExists(adTypeFee.AdTId))
                    {
                        return(NotFound());
                    }
                    else
                    {
                        throw;
                    }
                }
                return(RedirectToAction(nameof(Index)));
            }
            return(View(adTypeFee));
        }
        public async Task <IActionResult> Create([Bind("AdTId,Term,TermAmount,TermDate,AdYear,FTId")] AdTypeFee adTypeFee)
        {
            if (string.IsNullOrEmpty(HttpContext.Session.GetString("Session1")))
            {
                return(RedirectToAction("UserLogin", "Login"));
            }
            if (ModelState.IsValid)
            {
                _context.Add(adTypeFee);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(adTypeFee));
        }