Interactively change the selectInput choices

后端 未结 3 1266
滥情空心
滥情空心 2020-12-07 21:12

Originally I create this shiny interface that takes in a parameter \"company id\" and \"date\", but here we have a problem: most people dont know the companies we work with

3条回答
  •  [愿得一人]
    2020-12-07 21:50

    You need to make the UI reactive. I haven't tested this (miss data for it too) but should work I think. In server.R add:

    output$selectUI <- renderUI({ 
    selectInput("partnerName", "Select your choice", searchResult()[,1] ),
    })
    

    And in ui.R replace the selectInput with:

    htmlOutput("selectUI")
    

提交回复
热议问题