From 0ec48f22737b1c1ea148b7006e99bff8ec237356 Mon Sep 17 00:00:00 2001 From: Alex Axthelm Date: Wed, 11 Dec 2024 17:28:45 +0100 Subject: [PATCH] Output manifest and update param names --- R/build_dashboard.R | 35 ++++++++++++++++++++++++++++++++ R/prepare_pacta_dashboard_data.R | 4 ++-- 2 files changed, 37 insertions(+), 2 deletions(-) diff --git a/R/build_dashboard.R b/R/build_dashboard.R index 4a511f7..b9cf777 100644 --- a/R/build_dashboard.R +++ b/R/build_dashboard.R @@ -33,4 +33,39 @@ build_dashboard <- function( ) } + out <- list( + input_files = c( + list.files( + dashboard_data_dir, + full.names = TRUE, + recursive = TRUE + ), + list.files( + dashboard_skeleton_files_dir, + full.names = TRUE, + recursive = TRUE + ), + list.files( + analysis_output_dir, + full.names = TRUE, + recursive = TRUE + ), + list.files( + benchmarks_dir, + full.names = TRUE, + recursive = TRUE + ) + ), + output_files = c( + list.files( + dashboard_output_dir, + full.names = TRUE, + recursive = TRUE + ) + ), + params = params + ) + + return(out) + } diff --git a/R/prepare_pacta_dashboard_data.R b/R/prepare_pacta_dashboard_data.R index b4ff84e..ee408d8 100644 --- a/R/prepare_pacta_dashboard_data.R +++ b/R/prepare_pacta_dashboard_data.R @@ -10,7 +10,7 @@ log_info("Preparing data for the PACTA dashboard.") # portfolio/user parameters ---------------------------------------------------- log_debug("Reading portfolio/user parameters.") -investor_name <- params[["user"]][["investor_name"]] +investor_name <- params[["user"]][["name"]] portfolio_name <- params[["portfolio"]][["name"]] peer_group <- params[["user"]][["peerGroup"]] language_select <- params[["user"]][["languageSelect"]] @@ -18,7 +18,7 @@ language_select <- params[["user"]][["languageSelect"]] currency_exchange_value <- params[["user"]][["currencyExchangeValue"]] display_currency <- params[["user"]][["displayCurrency"]] -select_scenario_other <- params[["reporting"]][["selectOther"]] +select_scenario_other <- params[["reporting"]][["scenarioOther"]] select_scenario <- params[["reporting"]][["selectScenario"]] green_techs <- params[["reporting"]][["greenTechs"]]