diff --git a/src/Foundation/I18n.hs b/src/Foundation/I18n.hs
index 4e4de1cbc..ab0f2d0f3 100644
--- a/src/Foundation/I18n.hs
+++ b/src/Foundation/I18n.hs
@@ -168,12 +168,6 @@ thingEN num t = tshow num <> Text.cons ' ' (thing t)
thing Examinee = pluralENs num "examinee"
-}
-notDE :: Bool -> Text
-notDE = bool "nicht" ""
-
-notEN :: Bool -> Text
-notEN = bool "not" ""
-
-- | Convenience function for i18n messages definitions
maybeToMessage :: ToMessage m => Text -> Maybe m -> Text -> Text
maybeToMessage _ Nothing _ = mempty
diff --git a/src/Foundation/Navigation.hs b/src/Foundation/Navigation.hs
index 39c341b34..f63c1093f 100644
--- a/src/Foundation/Navigation.hs
+++ b/src/Foundation/Navigation.hs
@@ -111,7 +111,7 @@ breadcrumb PrintSendR = i18nCrumb MsgMenuPrintSend $ Just PrintCe
breadcrumb (PrintDownloadR _) = i18nCrumb MsgMenuPrintDownload $ Just PrintCenterR
breadcrumb SchoolListR = i18nCrumb MsgMenuSchoolList $ Just AdminR
-breadcrumb currentRoute@(SchoolR ssh sRoute) = case sRoute of
+breadcrumb (SchoolR ssh sRoute) = case sRoute of
SchoolEditR -> useRunDB . maybeT (i18nCrumb MsgBreadcrumbSchool $ Just SchoolListR) $ do
School{..} <- MaybeT $ get ssh
isAdmin <- lift $ hasReadAccessTo SchoolListR
@@ -2511,51 +2511,6 @@ pageActions PrintCenterR = return
, navChildren = []
}
]
-pageActions ApiDocsR = return
- [ NavPageActionPrimary
- { navLink = NavLink
- { navLabel = MsgMenuSwagger
- , navRoute = SwaggerR
- , navAccess' = NavAccessTrue
- , navType = NavTypeLink { navModal = False }
- , navQuick' = mempty
- , navForceActive = False
- }
- , navChildren = []
- }
- ]
-pageActions (TopWorkflowWorkflowListR lState) =
- let lState' | lState == WorkflowWorkflowListActive = WorkflowWorkflowListArchive
- | otherwise = WorkflowWorkflowListActive
- in return
- [ NavPageActionPrimary
- { navLink = NavLink
- { navLabel = MsgMenuTopWorkflowWorkflowList lState'
- , navRoute = TopWorkflowWorkflowListR lState'
- , navAccess' = NavAccessTrue
- , navType = NavTypeLink { navModal = False }
- , navQuick' = mempty
- , navForceActive = False
- }
- , navChildren = []
- }
- ]
-pageActions (SchoolR ssh (SchoolWorkflowInstanceR swiName (SWIWorkflowsR lState))) =
- let lState' | lState == WorkflowWorkflowListActive = WorkflowWorkflowListArchive
- | otherwise = WorkflowWorkflowListActive
- in return
- [ NavPageActionPrimary
- { navLink = NavLink
- { navLabel = MsgMenuWorkflowWorkflowList lState'
- , navRoute = SchoolR ssh . SchoolWorkflowInstanceR swiName $ SWIWorkflowsR lState'
- , navAccess' = NavAccessTrue
- , navType = NavTypeLink { navModal = False }
- , navQuick' = mempty
- , navForceActive = False
- }
- , navChildren = []
- }
- ]
pageActions _ = return []
submissionList :: ( MonadIO m
diff --git a/src/Handler/Info.hs b/src/Handler/Info.hs
index 170a156f7..b4ce9389d 100644
--- a/src/Handler/Info.hs
+++ b/src/Handler/Info.hs
@@ -42,7 +42,6 @@ getLegalR =
-- | Allgemeine Informationen
getInfoR :: Handler Html
getInfoR = do
- AppSettings{..} <- getsYesod appSettings'
changelogEntries' <- runDB $ selectList [ ChangelogItemFirstSeenItem <-. universeF ] []
let changelogEntries = Map.fromListWith Set.union
[ (Down changelogItemFirstSeenFirstSeen, Set.singleton changelogItemFirstSeenItem)
diff --git a/src/Model/Migration/Definitions.hs b/src/Model/Migration/Definitions.hs
index e9ed2dfd6..7b1526437 100644
--- a/src/Model/Migration/Definitions.hs
+++ b/src/Model/Migration/Definitions.hs
@@ -101,7 +101,6 @@ data ManualMigration
| Migration20210208StudyFeaturesRelevanceCachedUUIDs
| Migration20210318CrontabSubmissionRatedNotification
| Migration20210608SeparateTermActive
- | Migration20220521WorkflowArchivation
deriving (Eq, Ord, Read, Show, Enum, Bounded, Generic, Typeable)
deriving anyclass (Universe, Finite)
@@ -1016,20 +1015,6 @@ customMigrations = mapF $ \case
ALTER TABLE "term" DROP COLUMN "active";
|]
- Migration20220521WorkflowArchivation -> whenM (and2M (tableExists "workflow_workflow") $ not <$> columnExists "workflow_workflow" "archived") $ do
- now <- liftIO getCurrentTime
- -- mArchiveAfter <- lift $ view _appWorkflowWorkflowArchiveAfter
- let mArchiveAfter = Just (5270400 :: NominalDiffTime)
- [executeQQ| ALTER TABLE "workflow_workflow" ADD "archived" timestamp with time zone; |]
- let getWorkflows = [queryQQ| SELECT "workflow_workflow"."id", "workflow_workflow"."state"->-1->'time', "workflow_workflow"."state"->-1->'to', "shared_workflow_graph"."graph" FROM "workflow_workflow" INNER JOIN "shared_workflow_graph" ON "workflow_workflow"."graph" = "shared_workflow_graph"."hash"; |]
- migrateArchived [ fromPersistValue -> Right (wwId :: WorkflowWorkflowId), fmap Aeson.fromJSON . fromPersistValue -> Right (Aeson.Success wpTime), fmap Aeson.fromJSON . fromPersistValue -> Right (Aeson.Success wpTo), fromPersistValue -> Right (wGraph :: DBWorkflowGraph) ] = maybeT_ $ do
- archiveAfter <- hoistMaybe mArchiveAfter
- WGN{wgnFinal} <- hoistMaybe . Map.lookup wpTo $ wgNodes wGraph
- let wwArchived = max now (archiveAfter `addUTCTime` wpTime) <$ wgnFinal
- lift [executeQQ| UPDATE "workflow_workflow" SET "archived" = #{wwArchived} WHERE "id" = #{wwId}; |]
- migrateArchived _ = return ()
- in runConduit $ getWorkflows .| C.mapM_ migrateArchived
-
tableExists :: MonadIO m => Text -> ReaderT SqlBackend m Bool
tableExists table = do
diff --git a/templates/i18n/changelog/workflows-archivation.de-de-formal.hamlet b/templates/i18n/changelog/workflows-archivation.de-de-formal.hamlet
deleted file mode 100644
index c775ce108..000000000
--- a/templates/i18n/changelog/workflows-archivation.de-de-formal.hamlet
+++ /dev/null
@@ -1,11 +0,0 @@
-$newline never
-
-$maybe archived <- appWorkflowWorkflowArchiveAfter
- Workflows werden nun automatisch archiviert, sobald sie #
- $if archived /= 0
- seit #{tshow (nominalDiffTimeToSeconds archived / 86400)} Tagen #
- abgeschlossen sind.
-$nothing
- Workflows können nun archiviert werden.
-
-Archivierte Workflows werden nicht mehr in der Liste laufender Workflows angezeigt, sondern sind über ein separates Archiv verfügbar.
diff --git a/templates/i18n/changelog/workflows-archivation.en-eu.hamlet b/templates/i18n/changelog/workflows-archivation.en-eu.hamlet
deleted file mode 100644
index 1a1fd4e70..000000000
--- a/templates/i18n/changelog/workflows-archivation.en-eu.hamlet
+++ /dev/null
@@ -1,13 +0,0 @@
-$newline never
-
-$maybe archived <- appWorkflowWorkflowArchiveAfter
- Workflows are now being archived automatically #
- $if archived == 0
- immediately #
- $else
- #{tshow (nominalDiffTimeToSeconds archived / 86400)} days #
- after finalization.
-$nothing
- Workflow may now be archived.
-
-Archived workflows are not shown among the list of running workflows, but can instead be accessed via a separate archive list.
diff --git a/test/Database/Fill.hs b/test/Database/Fill.hs
index cce60d648..6797a3515 100644
--- a/test/Database/Fill.hs
+++ b/test/Database/Fill.hs
@@ -880,21 +880,6 @@ fillDb = do
, systemMessageLastChanged = now
, systemMessageLastUnhide = now
}
- void $ insert SystemMessage
- { systemMessageNewsOnly = False
- , systemMessageFrom = Just now
- , systemMessageTo = Nothing
- , systemMessageOnVolatileClusterSettings = Set.singleton (ClusterVolatileWorkflowsEnabled, toJSON False)
- , systemMessageAuthenticatedOnly = False
- , systemMessageSeverity = Warning
- , systemMessageManualPriority = Nothing
- , systemMessageDefaultLanguage = "de"
- , systemMessageContent = "Workflow-System zur Zeit deaktiviert (systemMessageOnVolatileClusterSettings-Test)"
- , systemMessageSummary = Nothing
- , systemMessageCreated = now
- , systemMessageLastChanged = now
- , systemMessageLastUnhide = now
- }
void $ insert SystemMessage
{ systemMessageNewsOnly = True
, systemMessageFrom = Just now