예제 #1
0
        public async Task <IActionResult> OnGetAsync(int id)
        {
            RefrcIndLanguage = await _context.RefrcIndLanguage
                               .Include(h => h.RefrcInd)
                               .FirstOrDefaultAsync(m => m.Id == id);

            RefrcIndInvariant = RefrcIndLanguage.RefrcInd;

            return(Page());
        }
예제 #2
0
        public async Task <IActionResult> OnGetAsync(int id)
        {
            RefrcIndLanguage = await _context.RefrcIndLanguage
                               .Include(h => h.RefrcInd)
                               .FirstOrDefaultAsync(m => m.Id == id);

            RefrcIndInvariant = RefrcIndLanguage.RefrcInd;

            var singCodes = await _context.SingTabl.Select(s => s.SingType).Distinct().ToListAsync();

            ViewData["SingCode"] = new SelectList(singCodes);

            return(Page());
        }
예제 #3
0
        public async Task <IActionResult> OnPostAsync(int id)
        {
            RefrcIndLanguage = await _context.RefrcIndLanguage
                               .Include(h => h.RefrcInd)
                               .FirstOrDefaultAsync(m => m.Id == id);

            RefrcIndInvariant = RefrcIndLanguage.RefrcInd;

            _context.RefrcIndLanguage.Remove(RefrcIndLanguage);
            _context.RefrcIndInvariant.Remove(RefrcIndInvariant);


            await _context.SaveChangesAsync();

            var url = _urlBuilder.BuildPropertyLink(
                this.GetLanguage(),
                "Refractive",
                system: _contextUtils.GetSystemUrlByHeadClue(RefrcIndInvariant.HeadClue)

                );

            return(Redirect(url));
        }