summaryrefslogtreecommitdiffstats
path: root/usecaseui-portal/src/app/app.component.ts
diff options
context:
space:
mode:
Diffstat (limited to 'usecaseui-portal/src/app/app.component.ts')
-rw-r--r--usecaseui-portal/src/app/app.component.ts17
1 files changed, 4 insertions, 13 deletions
diff --git a/usecaseui-portal/src/app/app.component.ts b/usecaseui-portal/src/app/app.component.ts
index be13c1a1..42907270 100644
--- a/usecaseui-portal/src/app/app.component.ts
+++ b/usecaseui-portal/src/app/app.component.ts
@@ -13,22 +13,13 @@ export class AppComponent {
translate.setDefaultLang('en');
// translate.use('en');
}
- changeLanguage(Language): void {
- switch(Language){
- case 'en':
- this.translate.use('en');
- break;
- case 'zh':
- this.translate.use('zh');
- }
- }
+
// 多语言
Language:String[] = ["zh","en"];
selectLanguage = "en";
- changeLanguage1(){
- this.translate.use(this.selectLanguage);
- }
- changeLanguage2(item){
+
+ changeLanguage(item){
+ this.selectLanguage = item;
this.translate.use(item);
}
}