@@ -16,6 +16,7 @@ import EnvironmentHeader from './EnvironmentHeader';
1616import StatsCard from './StatsCard' ;
1717import { Level1SettingPageContent } from "../../styled" ;
1818import history from "@lowcoder-ee/util/history" ;
19+ import { trans } from 'i18n' ;
1920
2021const { Title, Text} = Typography ;
2122
@@ -54,37 +55,37 @@ const UnlicensedEnvironmentView: React.FC<UnlicensedEnvironmentViewProps> = ({
5455
5556switch ( environment . licenseStatus ) {
5657case 'unlicensed' :
57- return 'This environment needs a valid license to unlock its full capabilities and features. Please make sure your API Service URL is correctly configured and Plugin is installed.' ;
58+ return trans ( "enterprise.environments.unlicensed.unlicensedDescription" ) ;
5859case 'error' :
59- return 'We encountered an issue while checking the license. Please review the configuration settings.' ;
60+ return trans ( "enterprise.environments.unlicensed.errorDescription" ) ;
6061default :
61- return 'This environment requires license configuration to proceed.' ;
62+ return trans ( "enterprise.environments.unlicensed.defaultDescription" ) ;
6263}
6364} ;
6465
6566// Stats data consistent with other environment pages
6667const statsData = [
6768{
68- title :"Type" ,
69- value :environment . environmentType || "Unknown" ,
69+ title :trans ( "enterprise.environments.unlicensed.type" ) ,
70+ value :environment . environmentType || trans ( "enterprise.environments.detail.unknown" ) ,
7071icon :< CloudServerOutlined /> ,
7172color :"#1890ff"
7273} ,
7374{
74- title :"Status" ,
75- value :"Unlicensed" ,
75+ title :trans ( "enterprise.environments.unlicensed.status" ) ,
76+ value :trans ( "enterprise.environments.detail.unlicensed" ) ,
7677icon :< CloseCircleOutlined /> ,
7778color :"#ff4d4f"
7879} ,
7980{
80- title :"Master Env" ,
81- value :environment . isMaster ?"Yes" :"No" ,
81+ title :trans ( "enterprise.environments.unlicensed.masterEnv" ) ,
82+ value :environment . isMaster ?trans ( "enterprise.environments.yes" ) :trans ( "enterprise.environments.no" ) ,
8283icon :< CloudServerOutlined /> ,
8384color :environment . isMaster ?"#722ed1" :"#8c8c8c"
8485} ,
8586{
86- title :"License Issue" ,
87- value :environment . licenseStatus === 'error' ?"Error" :"Missing" ,
87+ title :trans ( "enterprise.environments.unlicensed.licenseIssue" ) ,
88+ value :environment . licenseStatus === 'error' ?trans ( "enterprise.environments.unlicensed.error" ) :trans ( "enterprise.environments.unlicensed.missing" ) ,
8889icon :environment . licenseStatus === 'error' ?< ExclamationCircleOutlined /> :< CloseCircleOutlined /> ,
8990color :environment . licenseStatus === 'error' ?"#faad14" :"#ff4d4f"
9091}
@@ -117,12 +118,12 @@ const UnlicensedEnvironmentView: React.FC<UnlicensedEnvironmentViewProps> = ({
117118items = { [
118119{
119120key :'environments' ,
120- title :'Environments' ,
121+ title :trans ( "enterprise.environments.title" ) ,
121122onClick :( ) => history . push ( '/setting/environments' )
122123} ,
123124{
124125key :'current' ,
125- title :environment . environmentName || "Environment Detail"
126+ title :environment . environmentName || trans ( "enterprise.environments.detail.environmentDetail" )
126127}
127128] }
128129/>
@@ -179,7 +180,7 @@ const UnlicensedEnvironmentView: React.FC<UnlicensedEnvironmentViewProps> = ({
179180fontWeight :500
180181} }
181182>
182- Contact Lowcoder Team
183+ { trans ( "enterprise.environments.unlicensed.contactLowcoderTeam" ) }
183184</ Button >
184185
185186< Button
@@ -194,7 +195,7 @@ const UnlicensedEnvironmentView: React.FC<UnlicensedEnvironmentViewProps> = ({
194195fontWeight :500
195196} }
196197>
197- Edit Environment
198+ { trans ( "enterprise.environments.unlicensed.editEnvironment" ) }
198199</ Button >
199200
200201< Button
@@ -209,7 +210,7 @@ const UnlicensedEnvironmentView: React.FC<UnlicensedEnvironmentViewProps> = ({
209210fontWeight :500
210211} }
211212>
212- Back to Environments
213+ { trans ( "enterprise.environments.unlicensed.backToEnvironments" ) }
213214</ Button >
214215</ Space >
215216</ div >
@@ -233,7 +234,7 @@ const UnlicensedEnvironmentView: React.FC<UnlicensedEnvironmentViewProps> = ({
233234display :'block' ,
234235lineHeight :'1.5'
235236} } >
236- Need assistance? Contact our team for licensing support or edit the environment configuration to resolve this issue.
237+ { trans ( "enterprise.environments.unlicensed.helpText" ) }
237238</ Text >
238239</ Card >
239240