diff --git a/frontend/src/utils/hide-columns/hide-columns.js b/frontend/src/utils/hide-columns/hide-columns.js index 712de7d68..fa7122228 100644 --- a/frontend/src/utils/hide-columns/hide-columns.js +++ b/frontend/src/utils/hide-columns/hide-columns.js @@ -4,6 +4,7 @@ import './hide-columns.sass'; const HIDE_COLUMNS_CONTAINER_IDENT = 'uw-hide-columns'; const TABLE_HEADER_IDENT = 'uw-hide-column-header'; +const HIDE_COLUMNS_HIDER_LABEL = 'uw-hide-columns--hider-label'; const TABLE_UTILS_ATTR = 'table-utils'; const TABLE_UTILS_CONTAINER_SELECTOR = `[${TABLE_UTILS_ATTR}]`; @@ -80,7 +81,7 @@ export class HideColumns { const hiderContent = document.createElement('span'); hiderContent.classList.add('table-hider__label'); - hiderContent.innerHTML = th.innerText; + hiderContent.innerHTML = th.getAttribute(HIDE_COLUMNS_HIDER_LABEL) || th.innerText; hider.appendChild(hiderContent); this.addHeaderHider(th, hider); diff --git a/messages/uniworx/de-de-formal.msg b/messages/uniworx/de-de-formal.msg index 4ebfac7e6..81f167a74 100644 --- a/messages/uniworx/de-de-formal.msg +++ b/messages/uniworx/de-de-formal.msg @@ -1435,6 +1435,8 @@ TutorialRoomPlaceholder: Raum TutorialTutors: Tutoren TutorialTutorAlreadyAdded: Ein Tutor mit dieser E-Mail ist bereits für dieses Tutorium eingetragen +TutorialActionsHead: Aktionen + OccurrenceNoneScheduled: (Noch) keine planmäßigen Termine OccurrenceNoneExceptions: (Noch) keine Termin-Ausnahmen diff --git a/messages/uniworx/en-eu.msg b/messages/uniworx/en-eu.msg index effb79604..0651e5591 100644 --- a/messages/uniworx/en-eu.msg +++ b/messages/uniworx/en-eu.msg @@ -1433,6 +1433,8 @@ TutorialRoomPlaceholder: Room TutorialTutors: Tutors TutorialTutorAlreadyAdded: An user with this email address is already registered as tutor +TutorialActionsHead: Actions + OccurrenceNoneScheduled: No regular occurrences (yet) OccurrenceNoneExceptions: No exceptions (yet) diff --git a/src/Handler/Tutorial/List.hs b/src/Handler/Tutorial/List.hs index 11ae3dc41..dc936bd63 100644 --- a/src/Handler/Tutorial/List.hs +++ b/src/Handler/Tutorial/List.hs @@ -16,6 +16,7 @@ import qualified Data.CaseInsensitive as CI getCTutorialListR :: TermId -> SchoolId -> CourseShorthand -> Handler Html getCTutorialListR tid ssh csh = do Entity cid Course{..} <- runDB . getBy404 $ TermSchoolCourseShort tid ssh csh + MsgRenderer mr <- getMsgRenderer let tutorialDBTable = DBTable{..} @@ -51,7 +52,7 @@ getCTutorialListR tid ssh csh = do , sortable (Just "register-from") (i18nCell MsgTutorialRegisterFrom) $ \DBRow{ dbrOutput = (Entity _ Tutorial{..}, _) } -> maybeDateTimeCell tutorialRegisterFrom , sortable (Just "register-to") (i18nCell MsgTutorialRegisterTo) $ \DBRow{ dbrOutput = (Entity _ Tutorial{..}, _) } -> maybeDateTimeCell tutorialRegisterTo , sortable (Just "deregister-until") (i18nCell MsgTutorialDeregisterUntil) $ \DBRow{ dbrOutput = (Entity _ Tutorial{..}, _) } -> maybeDateTimeCell tutorialDeregisterUntil - , sortable Nothing mempty $ \DBRow{ dbrOutput = (Entity _ Tutorial{..}, _) } -> cell $ do + , sortable Nothing (mempty & cellAttrs <>~ pure ("uw-hide-columns--hider-label", mr MsgTutorialActionsHead)) $ \DBRow{ dbrOutput = (Entity _ Tutorial{..}, _) } -> cell $ do linkButton mempty [whamlet|_{MsgTutorialEdit}|] [BCIsButton] . SomeRoute $ CTutorialR tid ssh csh tutorialName TEditR linkButton mempty [whamlet|_{MsgTutorialDelete}|] [BCIsButton, BCDanger] . SomeRoute $ CTutorialR tid ssh csh tutorialName TDeleteR ]