public virtual ActionResult Index(string operationNumber) { TimeSpan stop; TimeSpan start = new TimeSpan(DateTime.Now.Ticks); SetPermissionMatrixChanges(); var rspnse = _tcmUniverseService.GetParentOperation(operationNumber); if (!rspnse.IsValid) { throw new Exception(rspnse.ErrorMessage); } var request = new GetMatrixChangesRequest { OperationNumber = rspnse.OperationNumber, TCReportingPeriod = null, Section = null, ChangeType = null, ChangeSubType = null }; var response = _matrixChangesService.GetMatrixChanges(request); if (!response.IsValid) { throw new Exception(response.ErrorMessage); } var viewModel = _viewModelMapperHelper.ConvertMatrixChangesViewModel(response.MatrixChangesDTO); if (viewModel.MatrixChangesList == null || viewModel.MatrixChangesList.Count == 0) { viewModel.MatrixChangesList = new List <MatrixChangesItem>(); } viewModel.FieldAccessList = _viewModelMapperHelper.GetFieldAccessModelList(operationNumber, PAGE_CHART); stop = new TimeSpan(DateTime.Now.Ticks); var resultado = stop.Subtract(start).Seconds; return(View(viewModel)); }
public virtual ActionResult Index(string operationNumber) { var operationResponse = _tcmUniverseService.GetParentOperation(operationNumber); if (!operationResponse.IsValid) { throw new Exception(operationResponse.ErrorMessage); } var operation = _operationRepository.GetOne(o => o.OperationNumber == operationResponse.OperationNumber); var outcomesResponse = _outcomesService.GetOutcomesData(operation); TempData["ResultMatrix" + outcomesResponse.ResultsMatrix.ResultsMatrixId] = outcomesResponse.ResultsMatrix; outcomesResponse.OutcomesData.FieldAccessList = _viewModelMapperHelper.GetFieldAccessModelList(operationNumber, PAGE_CHART); return(View(outcomesResponse.OutcomesData)); }
public virtual ActionResult Index( string operationNumber, bool isMilestonesEnabled = false, bool isDisaggregationsEnabled = false, bool unlock = false) { var predefModel = _linkPredefinedIndicatorService .GetLinkIndicatorModel(LinkIndicatorTypeEnum.Outputs, false, "Outputs", true).Filter; ViewBag.LinkIndicatorModel = predefModel; var rspnse = _tcmUniverseService.GetParentOperation(operationNumber); if (unlock) { UnlockRegister(operationNumber, TCMGlobalValues.URL_PHYSICAL_PROGRESS); } if (!rspnse.IsValid) { throw new Exception(rspnse.ErrorMessage); } var model = _componentService.GetResultsMatrix( rspnse.OperationNumber, Localization.CurrentLanguage, isMilestonesEnabled, isDisaggregationsEnabled, false).Components; model.FieldAccessList = _viewModelMapperHelper.GetFieldAccessModelList(operationNumber, PAGE_CHART); model.PhysicalProgress.FieldAccessList = model.FieldAccessList; model.MappingProgress.FieldAccessList = model.FieldAccessList; return(View(model)); }