Skip to content

Commit

Permalink
d
Browse files Browse the repository at this point in the history
  • Loading branch information
“rafal.urn” committed Aug 18, 2024
1 parent 222e756 commit d27c7c9
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 7 deletions.
11 changes: 5 additions & 6 deletions inst/source/tabs/tab1/server.R
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,12 @@


# Upload Project File
output$contents <- renderText({

file <- input$UploadProjectFile
output$contents <- renderTable({
file <- input$file1
ext <- tools::file_ext(file$datapath)

req(file)
validate(need(ext == "zip", "Please upload a zip file"))
validate(need(ext == "csv", "Please upload a csv file"))

paste("gfdcvbhg")

read.csv(file$datapath, header = input$header)
})
12 changes: 11 additions & 1 deletion inst/source/tabs/tab1/ui.R
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,16 @@ fluidPage(
)
)

verbatimTextOutput(ns("contents"))
fluidPage(
sidebarLayout(
sidebarPanel(
fileInput("file1", "Choose CSV File", accept = ".csv"),
checkboxInput("header", "Header", TRUE)
),
mainPanel(
tableOutput("contents")
)
)
)

# zawsze ns() do id !!!!! lacznie z output każdy id z ns() !!!!!

0 comments on commit d27c7c9

Please sign in to comment.