private IList <ConvergenceMasterDataModel> FilterDivisionsForSectorDepartments( List <int> sectorIds) { _filterBusinesslogic = new PMRPublicBusinessLogic(); return(_filterBusinesslogic.FilterDivisions( ClientForGenericReports.GetDivisionFilter( IDBContext.Current.CurrentLanguage, sectorIds))); }
public virtual JsonResult PMRAggregateFilterDivision(PMRAggregateReportModel ModelPMRAggregateReport) { var ListDivision = ClientForGenericReports.GetDivisionFilter(Lang, ModelPMRAggregateReport.SectorDepartment).OrderBy(x => x.Name).ToList(); return(new JsonResult() { Data = ListDivision }); }
public virtual JsonResult PMRAggregateFilterCountrys(PMRAggregateReportModel ModelPMRAggregateReport) { var ListCountrys = ClientForGenericReports.GetCountriesFilter(Lang, ModelPMRAggregateReport.CountryDepartment).OrderBy(x => x.Name).ToList(); return(new JsonResult() { Data = ListCountrys }); }
private void LoadSectorsAndDivisions(PMRPublicReportModel model) { _filterBusinesslogic = new PMRPublicBusinessLogic(); model.SectorDepartments = _filterBusinesslogic.FilterSectorDepartment(ClientForGenericReports .GetSectorDepartment(IDBContext.Current.CurrentLanguage)); List <int> sectorIds = model.SectorDepartments.Select(x => x.ConvergenceMasterDataId).ToList(); model.Divisions = FilterDivisionsForSectorDepartments(sectorIds); }
public virtual JsonResult PMRPublicFilterCountries(PMRPublicReportModel model) { _filterBusinesslogic = new PMRPublicBusinessLogic(); model.Countries = _filterBusinesslogic.FilterCountries(ClientForGenericReports .GetCountriesFilter( IDBContext.Current.CurrentLanguage, model.SelectedCountryDepartments)); return(new JsonResult() { Data = model.Countries }); }
private PMRPublicReportModel CreateModel(PMRPublicFilterModel filterModel) { PMRPublicReportModel result = new PMRPublicReportModel(); string language = IDBContext.Current.CurrentLanguage; _filterBusinesslogic = new PMRPublicBusinessLogic(); result.CountryDepartments = _filterBusinesslogic.FilterCountryDepartments( ClientForGenericReports.GetCountryDepartments(language)); result.PMRCycles = ClientPMRForCycleModel .GetPMRCycles(language).OrderByDescending(x => x.StartDate).ToList(); // don't include DRAFT validation stages, no necessary to list them result.PMRValidationStages = _filterBusinesslogic.FilterPMRValidationStages( ClientForGenericReports.GetPMRValidationStages(language)); result.OperationOverallStages = ClientForGenericReports.GetOperationOverallStages(language) .OrderBy(x => x.Name).ToList(); result.Countries = _filterBusinesslogic.FilterCountries( ClientForGenericReports.GetCountries(language)); LoadSectorsAndDivisions(result); List <TriStateFilter> triState = new List <TriStateFilter>(); triState.Add(new TriStateFilter { Name = Localization.GetText("All"), Value = -1 }); triState.Add(new TriStateFilter { Name = Localization.GetText("Yes"), Value = 1 }); triState.Add(new TriStateFilter { Name = Localization.GetText("No"), Value = 0 }); result.IsActive = triState; result.IsAuthorize = triState; result.Table = ClientForPMRPublic.GetPMRPublicTableData(filterModel); return(result); }
public virtual ActionResult PMRAggregateReportCreate() { PMRAggregateReportModel ModelOperationReport = new PMRAggregateReportModel(); var ListPMRCycles = ClientPMRForCycleModel.GetAllCyclesSeptemberAndMarchCycles(Lang).OrderByDescending(x => x.PmrCycleId).ToList(); var ListContry = ClientForGenericReports.GetCountries(Lang).OrderBy(x => x.Name).ToList(); var ListContryDepartment = ClientForGenericReports.GetCountryDepartments(Lang).OrderBy(x => x.Name).ToList(); var ListSectorDepartment = ClientForGenericReports.GetSectorDepartment(Lang).OrderBy(x => x.Name).ToList(); var ListDivision = ClientForGenericReports.GetDivisions(Lang).OrderBy(x => x.Name).ToList(); var ListEsgTrakingOptions = new Dictionary <bool, string>(); ListEsgTrakingOptions.Add(true, Localization.GetText("Yes")); ListEsgTrakingOptions.Add(false, Localization.GetText("No")); ViewBag.ListPMRCycle = new SelectList(ListPMRCycles, "PMRCycleId", "PmrCycleName"); ViewBag.ListContry = new MultiSelectList(ListContry, "ConvergenceMasterDataId", "Name"); ViewBag.ListContryDepartment = new MultiSelectList(ListContryDepartment, "ConvergenceMasterDataId", "Name"); ViewBag.ListSectorDepartment = new MultiSelectList(ListSectorDepartment, "ConvergenceMasterDataId", "Name"); ViewBag.ListDivision = new MultiSelectList(ListDivision, "ConvergenceMasterDataId", "Name"); ViewBag.ListESGTrakingOptions = new SelectList(ListEsgTrakingOptions, "key", "value"); return(View()); }