Coder Social home page Coder Social logo

dt-editor's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

dt-editor's Issues

Editing using SelectInputs

Hello @jienagu. Thank you creating this amazing DT-Editor! I had a question with regards to the "Edit Modal" part of the shiny app. As of now, all my fields that I want to edit are textInput but I want some of them to be selectInput. Is it possible to have the sample dropdown buttons in the "Edit Modal" like you have it in the "Add Row Modal". If so, could you please guide me? Thank you!

Unable to save updated data frame as .rds file with below replicated r shiny app

I got below replication of R shiny app which is simpler version of yours, when run it and edit the last column of iris data frame, the app always give me this error message: Warning: Error in <<-: invalid (NULL) left side of assignment
Could you please help me to debug it? Thanks.

library(shiny)
library(DT)

ui <- fluidPage(
DTOutput("iris_table")
)

server <- function(input, output, session) {

create a reactive copy of iris data frame

iris_data <- reactiveVal(iris)

render the data table with editable option for the last column

output$iris_table <- renderDT({
datatable(iris_data(), editable = list(target = "column", disable = list(columns = c(0:4))))
})

update the iris data frame when the user edits the last column

observeEvent(input$iris_table_cell_edit, {
info <- input$iris_table_cell_edit
str(info)
i <- info$row
j <- info$col
v <- info$value
iris_data()[i, j] <<- DT::coerceValue(v, iris_data()[i, j])

# save the updated iris data frame as iris_updated.rds file in a directory
saveRDS(iris_data(), file = "iris_updated.rds")

})
}

shinyApp(ui, server)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.