Commit 5a0e5117 authored by Jean-Francois Rey's avatar Jean-Francois Rey
Browse files

shiny : change tab order

parent 8a1fb271
......@@ -179,8 +179,10 @@ server <- function(input, output, session) {
if (advanced_mode()) {
printVerbose("enable mode edition", level=3)
removeCssClass("Mode","btn-default")
updateTabsetPanel(session,inputId = "inputtabpanel", selected = "Cultivars and Genes")
shinyjs::disable(id = "demo")
shinyjs::enable(id = "rotationPeriod")
shinyjs::disable(id = "rotationPeriod")
shiny::updateNumericInput(session, "rotationPeriod", value = 0)
shinyjs::enable(id = "patho_infection_rate")
shinyjs::enable(id = "patho_propagule_prod_rate")
shinyjs::enable(id = "patho_latent_period_exp")
......@@ -197,6 +199,7 @@ server <- function(input, output, session) {
printVerbose("disable mode edition", level=3)
addCssClass("Mode","btn-default")
shinyjs::disable(id = "rotationPeriod")
shiny::updateNumericInput(session, "rotationPeriod", value = 0)
shinyjs::enable(id = "demo")
shinyjs::disable(id = "patho_infection_rate")
shinyjs::disable(id = "patho_propagule_prod_rate")
......@@ -1153,7 +1156,7 @@ server <- function(input, output, session) {
})
observeEvent(input[["inputtabpanel"]], {
if (input[["inputtabpanel"]] == "Cultivars and genes") {
if (input[["inputtabpanel"]] == "Cultivars and Genes") {
removeCssClass("inputside", "col-sm-6")
removeCssClass("inputside", "col-sm-0")
removeCssClass("outputside", "col-sm-12")
......
......@@ -104,12 +104,12 @@ landscapeTab <- {
cultivarTab <- {
shiny::tabPanel(
"Cultivars and Genes",
h3("Genes"),
editableDTUI(id = "genes"),
h3("Cultivars"),
editableDTUI(id = "cultivars"),
h3("Cultivars and Genes"),
editableDTUI(id = "cultivarsgenes"),
h3("Genes"),
editableDTUI(id = "genes"),
)
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment