R/mod_inicio.R

Defines functions mod_inicio_server mod_inicio_ui

#' inicio UI Function
#'
#' @description A shiny Module.
#'
#' @param id,input,output,session Internal parameters for {shiny}.
#'
#' @noRd 
#'
#' @importFrom shiny NS tagList 
mod_inicio_ui <- function(id){
  ns <- NS(id)
  
  shinyWidgets::switchInput(
    inputId = ns("RAIS_CAGED_"),
    onLabel = "CAGED",
    offLabel = "RAIS",
    value = TRUE
  )
  
  
  
  # radioButtons(ns("caminho_bd"), label = NULL, choices = c("Local" = "C:\\BD",
  #                                                          "Rede" = "\\\\RDPDC1VPR0033\\IBRE-DNIT-Sata\\BD"),
  #              selected = "C:\\BD")
  
}
    
#' inicio Server Function
#'
#' @noRd 
mod_inicio_server <- function(input, output, session){
  ns <- session$ns
    
  return(
    
    list(
      
      origem = reactive({ input$RAIS_CAGED_ })
      
      )
    
  )
  
    
}
    
## To be copied in the UI
# mod_inicio_ui("inicio_ui_1")
    
## To be copied in the server
# callModule(mod_inicio_server, "inicio_ui_1")
 
leandro-vento/projeto documentation built on April 10, 2021, 6:43 p.m.