-
Notifications
You must be signed in to change notification settings - Fork 1
/
server.R
70 lines (56 loc) · 2.06 KB
/
server.R
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
####--SERVER------------------------------------------------------------------------------------------------
shinyServer(function(input, output, session, options = options(warn = -1)) {
####--UI BLOCK----------------------------------------------------------------------------------------------
default_tab = "analytics"
current_version = "0.01"
output$app_version <- renderUI({
fluidRow(
column(12,
offset = 1,
br(),
h5(str_c("Version ", current_version)),
h6("Mocha-AI")
)
)
})
output$ui_sidebar <- renderUI({
sidebarMenu(id = "tab",
menuItem(text = "Home",
tabName = "home",
icon = icon("home")
),
menuItem(text = "Analytics",
tabName = "analytics",
icon = icon("chart-line")
),
# menuItem(text = "Descriptives",
# tabName = "descriptives",
# icon = icon("balance-scale")
# ),
# menuItem(text = "Data",
# tabName = "data",
# icon = icon("cube")
# ),
uiOutput("app_version")
# br(),
# br(),
# img(src = "ahpra_logo_30.PNG") #attempt to add the logo
)
})
output$ui_body <- renderUI({
updateTabsetPanel(session, "tab", selected = "home")
tabItems(
tabItem_home,
tabItem_analytics
# tabItem_descriptives,
# tabItem_data
)
})
####--SERVER BLOCK-----------------------------------------------------------------------------------------
## ReactiveValues
v <- reactiveValues(analytics_slider_time = NULL)
# Server modules
# source('server/s_data.R', local = TRUE)
# source('server/s_descriptives.R', local = TRUE)
source('server/s_analytics.R', local = TRUE)
})