Skip to content

Commit c34fec6

Browse files
Added icos-agri user option, so one user can handle all icos-agri sites.
1 parent 4f6707f commit c34fec6

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

R/app_server.R

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,15 @@ app_server <- function(input, output, session) {
7474

7575
updateSelectInput(session, "site", choices = site_choices, selected = auth_result$user)
7676

77+
} else if (auth_result$user == "icos_agri_user") {
78+
79+
shinyjs::enable("site")
80+
shinyjs::show("site")
81+
# Subset of site choices for the third user
82+
site_choices <- sites[grepl("icos-agri", sites$site_type),]$site
83+
84+
updateSelectInput(session, "site", choices = site_choices, selected = auth_result$user)
85+
7786
} else {
7887

7988
updateSelectInput(session, "site", selected = auth_result$user)

0 commit comments

Comments
 (0)