public IActionResult Dashboard(string user) { ManageDashboardViewModel model = new ManageDashboardViewModel(); model.Sas = new SASViewModel(); model.CBSDVM = new CBSDVendorModel(); model.Sas.SASNames = DropDownBinding.GetDropDown(AppConstants.USP_GETSAS, 0, "SELECT SAS"); model.CBSDVM.CBSDVendorModels = DropDownBinding.GetDropDown(AppConstants.USP_GETCBSDVENDORMODELS, 0, "SELECT CBSD Vendor / Model"); ViewBag.User = user; return(View(model)); }
public ActionResult ManageFloor(int?floorID, int?buildingID, string Name, string operation) { FloorViewModel model = null; if (floorID == null) { model = new FloorViewModel(); } else { //get floor plan by ID model = _FLOORBAL.GetFloorByID(floorID.Value); } if (model == null) { ViewBag.msg = "No record found"; model = new FloorViewModel(); } string message = string.Empty; if (operation != null) { if (operation == AppConstants.ADDED) { message = "Floor added successfully."; } else if (operation == AppConstants.UPDATED) { message = "Floor updated successfully."; } ViewBag.Message = message; } model.Buildings = DropDownBinding.GetDropDown(AppConstants.USP_GETBUILDINGSFORDROPDOWN, 0, "SELECT Building"); ViewBag.BuildingID = buildingID; return(View(model)); }
public ActionResult IndoorStep(int floorID) { FloorViewModel floor = _FLOORBAL.GetFloorByID(23); List <APViewModel> aps = _APBAL.GetAPByFloorID(23); // ViewBag.BuildName = Name; if (!string.IsNullOrEmpty(floor.FloorPlanSHPPath)) { ViewBag.FileName = string.Concat("..", Url.Content("~/ShapeFiles/Columbus Circle - First Floor Lines636984586978583967637001940100847321.json")); // will be used in Indoor/ReadJsonFile ViewBag.FloorPlanSHPPath = "~/ShapeFiles/Columbus Circle - First Floor Lines636984586978583967637001940100847321.json"; } else { ViewBag.FileName = ""; } IndoorStep2ViewModel model = new IndoorStep2ViewModel(); ViewBag.APs = aps; model.InstallationParameters = new InstallationParametersViewModel(); model.OptionalParameters = new OptionalParametersViewModel(); model.CBSD = new CBSDViewModel(); model.APType = new APTypeViewModel(); model.Group = new GroupViewModel(); model.APType.APTypeNames = DropDownBinding.GetDropDown(AppConstants.USP_GETAPTypes, 0, "AP Type"); model.Group.GroupNames = DropDownBinding.GetDropDown(AppConstants.USP_GETGROUPS, 0, "Group"); ViewBag.BuildingID = floor.BuildingID; ViewBag.FloorID = 23; return(View(model)); }
public ActionResult ManageRoleNRights(int?RoleID) { _manageRoleNRightsViewModel.RolesNRightsViewMdoels = _rolesNRightsBAL.GetRolesNRights(RoleID); _manageRoleNRightsViewModel.RolesViewModels = DropDownBinding.GetDropDown(AppConstants.USP_GETROLESFORDROPDOWN, 0, "SELECT Role"); return(View(_manageRoleNRightsViewModel)); }
// GET: ManageAPParameters public IActionResult ManageAPParameters(int?apid, double?lat, double?lng, int?floorID, string section, string operation) { ManageAPParametersViewModal model = new ManageAPParametersViewModal(); if (floorID != 0 && floorID != null) { ViewBag.floorID = floorID; } else { ViewBag.floorID = 0; } if (apid != null) { var installationParameters = _installationParametersBAL.GetInstallationParemetersByAPID(apid.Value); if (installationParameters != null) { model.InstallationParameters = installationParameters; } else { model.InstallationParameters = new InstallationParametersViewModel(); if (lat != null) { model.InstallationParameters.Latitude = lat.Value; } if (lng != null) { model.InstallationParameters.Longitude = lng.Value; } } model.InstallationParameters.APID = apid.Value; model.InstallationParameters.HeightTypes = DropDownBinding.GetDropDown(AppConstants.USP_GETHEIGHTTYPES, 0, "SELECT Height Type"); model.InstallationParameters.AntennaModels = DropDownBinding.GetDropDown(AppConstants.USP_GETANTENNAMODELS, 0, "SELECT Antenna Model"); var optionalParameters = _optionalParametersBAL.GetOptionalParemetersByAPID(apid.Value); if (optionalParameters != null) { model.OptionalParameters = optionalParameters; } else { model.OptionalParameters = new OptionalParametersViewModel(); } model.OptionalParameters.APID = apid.Value; model.OptionalParameters.CallSigns = DropDownBinding.GetDropDown(AppConstants.USP_GETCALLSIGNS, 0, "SELECT Call Sign"); model.OptionalParameters.CbsdInfos = DropDownBinding.GetDropDown(AppConstants.USP_GETCBSDINFOS, 0, "SELECT Cbsd Info"); model.OptionalParameters.GroupingParams = DropDownBinding.GetDropDown(AppConstants.USP_GETGROUPINGPARAMS, 0, "SELECT GroupingParam"); var cbsd = _CBSDBAL.GetCBSDByAPID(apid.Value); if (cbsd != null) { model.CBSD = cbsd; } else { model.CBSD = new CBSDViewModel(); } model.CBSD.APID = apid.Value; model.CBSD.CBSDVendorModels = DropDownBinding.GetDropDown(AppConstants.USP_GETCBSDVENDORMODELS, 0, "SELECT CBSDVendorModels"); } string message = string.Empty; if (section != null && operation != null) { if (section == AppConstants.InstallationParameters) { message = "Installation Parameters "; } else if (section == AppConstants.OptionalParameters) { message = "Optional Parameters "; } else if (section == AppConstants.CBSD) { message = "CBSD "; } if (operation == AppConstants.SaveAsDraft) { message += "Saved as Draft successfully"; } else if (operation == AppConstants.Submit) { message += "Submitted successfully"; } ViewBag.Message = message; } return(View(model)); }