Esempio n. 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());
        }
Esempio n. 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());
        }
Esempio n. 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));
        }