Example #1
0
        public async Task <IActionResult> NationalIdentityType()
        {
            NationalIdentityTypeViewModel model = new NationalIdentityTypeViewModel
            {
                nationalIdentityTypes = await lostAndFoundType.GetNationalIdentityTypes(),
                fLang = _nLang.PerseLang("MasterData/IdentityTypeEN.json", "MasterData/IdentityTypeBN.json", Request.Cookies["lang"]),
            };

            return(View(model));
        }
Example #2
0
        public async Task <IActionResult> NationalIdentityType([FromForm] NationalIdentityTypeViewModel model)
        {
            NationalIdentityType nationalIdentityType = new NationalIdentityType
            {
                Id = (int)model.nidId,
                nationalIdentityName   = model.nidName,
                nationalIdentityNameBn = model.nationalIdentityNameBn
            };
            await lostAndFoundType.SaveNationalIdentityType(nationalIdentityType);

            return(RedirectToAction(nameof(NationalIdentityType)));
        }