module TUI.OutputScreens
( module TUI.OutputScreens
) where
import qualified Data.Map as Map
import Manager
class Content a where
getContent :: a -> String
nextScreens :: a -> Map.Map Char Screen
instance Content Screen where
getContent :: Screen -> String
getContent Screen
ExitScreen = String
"\nAté a próxima \n\
\e obrigado pelos peixes!\n"
getContent Screen
FirstScreen = String
"\nBEM-VINDO(A) AO SIGES! PARA COMEÇAR, VAMOS CADASRTRAR\n\
\O PRIMEIRO USUÁRIO (ADMINISTRADOR) DO SISTEMA!\n"
getContent Screen
StartScreen =String
"\n=========================\n\
\ BEM-VINDO(A) AO SIGES \n\
\=========================\n\
\\nO que deseja fazer?\n\
\[L]ogin\n\
\[V]isualizar reservas\n\
\[D]esligar"
getContent Screen
LoginScreen =String
"\n\
\=========================\n\
\ LOGIN \n\
\=========================\n\
\[R]etornar (menu inicial)"
getContent Screen
LoggedScreen =String
"\n\
\=========================\n\
\ TELA DE USUÁRIO \n\
\=========================\n\
\[C]adastrar reservas \n\
\[V]isualizar reservas \n\
\[E]ditar reservas \n\
\[R]emover reservas \n\
\[D]eslogar"
getContent Screen
AdminScreen = String
"\n\
\==========================\n\
\ TELA DE ADMINISTRADOR \n\
\==========================\n\
\[I]ncluir novas salas \n\
\[C]adastrar reservas \n\
\[V]isualizar reservas \n\
\[A]lterar reservas \n\
\[D]eletar reservas \n\
\[R]egistrar novo usuário \n\
\[E]xcluir usuário \n\
\[F]azer logout"
getContent Screen
InsertRoomScreen = String
"\n\
\==========================\n\
\ INCLUIR NOVAS SALAS \n\
\=========================="
getContent Screen
SignUpScreen = String
"\n\
\=========================\n\
\ CADASTRAR USUÁRIO \n\
\=========================\n\
\[R]etornar (menu anterior)"
getContent Screen
RemoveUserScreen = String
"\n\
\=========================\n\
\ REMOVER USUÁRIO \n\
\=========================\n\
\[R]etornar (menu anterior)"
getContent Screen
ViewScreen = String
"\n\
\========================== \n\
\ VISUALIZAÇÃO DE SALAS \n\
\========================== \n\
\[D]ados de uma sala específica\n\
\[F]iltrar salas por atributo \n\
\[O]cupação por sala \n\
\[S]alas ocupadas em certo dia \n\
\[R]etornar (menu principal)"
getContent Screen
ViewUserScreen = String
"\n\
\=============================\n\
\ VISUALIZAR SALAS DE USUÁRIO \n\
\=============================\n"
getContent Screen
ViewRoomScreen = String
"\n\
\=============================\n\
\ VISUALIZAR SALA ESPECÍFICA \n\
\=============================\n"
getContent Screen
ViewFilterScreen = String
"\n\
\==========================\n\
\ VISUALIZAR POR FILTROS \n\
\==========================\n"
getContent Screen
ReportRoomScreen = String
"\n\
\=============================\n\
\ RELATÓRIO DE SALA ESPECÍFICA\n\
\=============================\n"
getContent Screen
ReportDayScreen = String
"\n\
\=============================\n\
\ RELATÓRIO DE DIA ESPECÍFICO \n\
\=============================\n"
getContent Screen
CreateReservationScreen = String
"\n\
\=========================\n\
\ CADASTRAR RESERVAS \n\
\=========================\n"
getContent Screen
EditReservationScreen = String
"\n\
\=========================\n\
\ EDITAR RESERVAS \n\
\=========================\n"
getContent Screen
RemoveReservationScreen = String
"\n\
\=========================\n\
\ REMOVER RESERVAS \n\
\=========================\n"
nextScreens :: Screen -> Map Char Screen
nextScreens Screen
StartScreen = [(Char, Screen)] -> Map Char Screen
forall k a. Ord k => [(k, a)] -> Map k a
Map.fromList [(Char
'L', Screen
LoginScreen),(Char
'V', Screen
ViewScreen), (Char
'D', Screen
ExitScreen)]
nextScreens Screen
LoginScreen = [(Char, Screen)] -> Map Char Screen
forall k a. Ord k => [(k, a)] -> Map k a
Map.fromList [(Char
'R', Screen
StartScreen)]
nextScreens Screen
LoggedScreen = [(Char, Screen)] -> Map Char Screen
forall k a. Ord k => [(k, a)] -> Map k a
Map.fromList [(Char
'C', Screen
CreateReservationScreen), (Char
'V', Screen
ViewUserScreen), (Char
'E',Screen
EditReservationScreen), (Char
'R', Screen
RemoveReservationScreen), (Char
'D', Screen
StartScreen)]
nextScreens Screen
AdminScreen = [(Char, Screen)] -> Map Char Screen
forall k a. Ord k => [(k, a)] -> Map k a
Map.fromList [(Char
'I', Screen
InsertRoomScreen), (Char
'C', Screen
CreateReservationScreen), (Char
'V', Screen
ViewUserScreen), (Char
'A',Screen
EditReservationScreen), (Char
'D',Screen
RemoveReservationScreen),(Char
'R', Screen
SignUpScreen), (Char
'E', Screen
RemoveUserScreen), (Char
'F', Screen
StartScreen)]
nextScreens Screen
SignUpScreen = [(Char, Screen)] -> Map Char Screen
forall k a. Ord k => [(k, a)] -> Map k a
Map.fromList [(Char
'R', Screen
StartScreen)]
nextScreens Screen
RemoveUserScreen = [(Char, Screen)] -> Map Char Screen
forall k a. Ord k => [(k, a)] -> Map k a
Map.fromList [(Char
'R', Screen
StartScreen)]
nextScreens Screen
ViewScreen = [(Char, Screen)] -> Map Char Screen
forall k a. Ord k => [(k, a)] -> Map k a
Map.fromList [(Char
'D', Screen
ViewRoomScreen), (Char
'F',Screen
ViewFilterScreen), (Char
'O',Screen
ReportRoomScreen),(Char
'S',Screen
ReportDayScreen), (Char
'R', Screen
StartScreen)]
nextScreens Screen
_ = Map Char Screen
forall k a. Map k a
Map.empty