Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pass the check status to the main teal_data function call #1070

Merged
merged 4 commits into from
Jan 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ Encoding: UTF-8
Language: en-US
LazyData: true
Roxygen: list(markdown = TRUE)
RoxygenNote: 7.3.0
RoxygenNote: 7.3.1
Collate:
'dummy_functions.R'
'get_rcode_utils.R'
Expand Down
8 changes: 7 additions & 1 deletion R/module_nested_tabs.R
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
#' @param is_module_specific (`logical(1)`)\cr
#' flag determining if the filter panel is global or module-specific.
#' When set to `TRUE`, a filter panel is called inside of each module tab.
#'
#' @return depending on class of `modules`, `ui_nested_tabs` returns:
#' - `teal_module`: instantiated UI of the module
#' - `teal_modules`: `tabsetPanel` with each tab corresponding to recursively
Expand Down Expand Up @@ -267,6 +268,7 @@ srv_nested_tabs.teal_module <- function(id, datasets, modules, is_module_specifi
#'
#' @param module (`teal_module`) module where needed filters are taken from
#' @param datasets (`FilteredData`) object where needed data are taken from
#'
#' @return A `teal_data` object.
#'
#' @keywords internal
Expand All @@ -291,10 +293,14 @@ srv_nested_tabs.teal_module <- function(id, datasets, modules, is_module_specifi
get_datasets_code(datanames, datasets, hashes)
)

do.call(

data <- do.call(
teal.data::teal_data,
args = c(data, code = list(code), join_keys = list(datasets$get_join_keys()[datanames]))
)

data@verified <- attr(datasets, "verification_status")
return(data)
vedhav marked this conversation as resolved.
Show resolved Hide resolved
}

#' Get the hash of a dataset
Expand Down
1 change: 1 addition & 0 deletions R/utils.R
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ teal_data_to_filtered_data <- function(x, datanames = teal_data_datanames(x)) {
)
# Piggy-back entire pre-processing code so that filtering code can be appended later.
attr(ans, "preprocessing_code") <- teal.code::get_code(x)
attr(ans, "verification_status") <- x@verified
ans
}

Expand Down
Loading