//set Search Owner Type
 public SelectList getSearchOwnerTypeDB()
 {
     try
     {
         EnumsForViews EnumsForViews = new EnumsForViews();
         return(EnumsToSelectList.ToSelectList(typeof(EnumsForViews.OwnerSearchType), "0"));
     }
     catch (Exception)
     {
         throw;
     }
 }
 //set Application Type
 public SelectList getApplicationSelectListDB()
 {
     try
     {
         EnumsForViews EnumsForViews = new EnumsForViews();
         return(EnumsToSelectList.ToSelectList(typeof(EnumsForViews.VesselApplicationType), "0"));
     }
     catch (Exception)
     {
         throw;
     }
 }
Example #3
0
 //set Longitude Directions
 public SelectList getLongitudeDirectionsDB()
 {
     try
     {
         EnumsForViews EnumsForViews = new EnumsForViews();
         return(EnumsToSelectList.ToSelectList(typeof(EnumsForViews.LongDirections), "0"));
     }
     catch (Exception)
     {
         throw;
     }
 }
Example #4
0
        // GET: RaportController
        public async Task <ActionResult> IndexAsync()
        {
            string role = User.IsInRole("HR") ? "HR" : "Administrator";

            ViewBag.RaportiId = EnumsToSelectList <Raportet> .GetSelectList();

            ViewBag.KompaniaId = await kompaniaRepository.KompaniaSelectListBasedOnRole(role, user.KompaniaId);

            ViewBag.PunetoriId = new SelectList(new List <string>(), "Value", "Text");
            ViewBag.GradaId    = await gradaRepository.GradaSelectList(null, false, false);

            ViewBag.BankaId = await bankRepository.BankaSelectList(null, false, false);

            return(View());
        }