ui improvements

This commit is contained in:
friedemann.blume 2024-01-12 23:43:11 +01:00
parent 36b85b24a8
commit 43598d9e40
1 changed files with 10 additions and 6 deletions

View File

@ -33,14 +33,14 @@ ui <- navbarPage("EpriLog",
dateInput("date", "Date:"), #maybe better to automatically generate with time
selectInput("alias", "Whats the nick name of the coffee?", choices = coffees$alias, multiple = FALSE, selected = lastUsedParameters$Alias),
#selectInput("coffeeName", "Whats the name of the coffee?", coffees$coffeeName, multiple = FALSE),
# Grind Time
sliderInput("grindTime", "Ginding Time", value = 14, min = 0, max = 30, step = 0.2),
# Grind Size (my Grinder can go up to 70 but thats no longer Espresso..)
sliderInput("grindSize", "Ginding Size", value = 7, min = 0, max = 30),
# Flow rate (0 = none, 10 = perfect, 20 = water)
sliderInput("flowResult", "Flow rate (10 is Perfect):", value = 10, min = 0, max = 20),
# Taste Rating (sour = none, 10 = perfect, 20 = bitter)
sliderInput("taste", "Taste (0=Sour, 10=perfect, 20=bitter):", value = 10, min = 0, max = 20),
# Flow rate (0 = none, 10 = perfect, 20 = water)
sliderInput("flowResult", "Flow rate (10 is Perfect):", value = lastUsedParameters$FlowResult, min = 0, max = 20),
# Grind Time
sliderInput("grindTime", "Ginding Time", value = lastUsedParameters$GrindTime, min = 0, max = 30, step = 0.2),
# Grind Size (my Grinder can go up to 70 but thats no longer Espresso..)
sliderInput("grindSize", "Ginding Size", value = lastUsedParameters$GrindSize, min = 0, max = 30),
# WDT Tool
checkboxInput("wdt", "WDT Tool used?", value = TRUE),
# Brew Temp
@ -96,6 +96,10 @@ server <- function(input, output, session){
grinders <- (read.csv(file = "./data/grinders.csv", header = TRUE, sep = ",", row.names = 1))
coffees <- (read.csv(file = "./data/coffees.csv", header = TRUE, sep = ",", row.names = 1))
# get last used coffee
lastUsedParameters <- tail(brews, n=1)
lastUsedParameters$Alias
# Render Brew History Table
output$history = DT::renderDataTable(
brews, server = TRUE,