diff --git a/web/app/components/header/license-env/index.tsx b/web/app/components/header/license-env/index.tsx
new file mode 100644
index 0000000000..800d86d2b8
--- /dev/null
+++ b/web/app/components/header/license-env/index.tsx
@@ -0,0 +1,29 @@
+'use client'
+
+import AppContext from '@/context/app-context'
+import { LicenseStatus } from '@/types/feature'
+import { useTranslation } from 'react-i18next'
+import { useContextSelector } from 'use-context-selector'
+import dayjs from 'dayjs'
+
+const LicenseNav = () => {
+ const { t } = useTranslation()
+ const systemFeatures = useContextSelector(AppContext, s => s.systemFeatures)
+
+ if (systemFeatures.license?.status === LicenseStatus.EXPIRING) {
+ const expiredAt = systemFeatures.license?.expired_at
+ const count = dayjs(expiredAt).diff(dayjs(), 'days')
+ return
+ {count <= 1 && {t('common.license.expiring', { count })}}
+ {count > 1 && {t('common.license.expiring_plural', { count })}}
+
+ }
+ if (systemFeatures.license.status === LicenseStatus.ACTIVE) {
+ return
+ Enterprise
+
+ }
+ return null
+}
+
+export default LicenseNav
diff --git a/web/app/signin/normalForm.tsx b/web/app/signin/normalForm.tsx
index f4f46c68ba..783d8ac507 100644
--- a/web/app/signin/normalForm.tsx
+++ b/web/app/signin/normalForm.tsx
@@ -2,7 +2,7 @@ import React, { useCallback, useEffect, useState } from 'react'
import { useTranslation } from 'react-i18next'
import Link from 'next/link'
import { useRouter, useSearchParams } from 'next/navigation'
-import { RiDoorLockLine } from '@remixicon/react'
+import { RiContractLine, RiDoorLockLine, RiErrorWarningFill } from '@remixicon/react'
import Loading from '../components/base/loading'
import MailAndCodeAuth from './components/mail-and-code-auth'
import MailAndPasswordAuth from './components/mail-and-password-auth'
@@ -10,7 +10,7 @@ import SocialAuth from './components/social-auth'
import SSOAuth from './components/sso-auth'
import cn from '@/utils/classnames'
import { getSystemFeatures, invitationCheck } from '@/service/common'
-import { defaultSystemFeatures } from '@/types/feature'
+import { LicenseStatus, defaultSystemFeatures } from '@/types/feature'
import Toast from '@/app/components/base/toast'
import { IS_CE_EDITION } from '@/config'
@@ -83,6 +83,48 @@ const NormalForm = () => {
}
+ if (systemFeatures.license?.status === LicenseStatus.LOST) {
+ return
+ }
+ if (systemFeatures.license?.status === LicenseStatus.EXPIRED) {
+ return
+ }
+ if (systemFeatures.license?.status === LicenseStatus.INACTIVE) {
+ return
+ }
return (
<>
diff --git a/web/context/app-context.tsx b/web/context/app-context.tsx
index 78ac1c9848..369fe5af19 100644
--- a/web/context/app-context.tsx
+++ b/web/context/app-context.tsx
@@ -144,7 +144,7 @@ export const AppContextProvider: FC