Commit 440805cd authored by Alish's avatar Alish
Browse files

fix: default language #1010

parent 8f551b85
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -28,7 +28,7 @@ export function HttpLoaderFactory(http: HttpClient) {
})
export class I18nModule {
	constructor(translate: TranslateService) {
		translate.setDefaultLang('en');
		translate.use('en');
		translate.setDefaultLang('en-US');
		translate.use('en-US');
	}
}
+2 −2
Original line number Diff line number Diff line
@@ -66,8 +66,8 @@ export class CategoriesTableComponent implements OnInit, OnDestroy {
		private readonly _notifyService: NotifyService,
		private readonly modalService: NgbModal
	) {
		this._translateService.setDefaultLang('en');
		this._translateService.use('en');
		this._translateService.setDefaultLang('en-US');
		this._translateService.use('en-US');
	}

	get hasSelectedCategories(): boolean {
+2 −2
Original line number Diff line number Diff line
@@ -29,8 +29,8 @@ export class CategoryCreateComponent implements OnDestroy {
		private readonly _notifyService: NotifyService,
		private readonly _productsCategoryService: ProductsCategoryService
	) {
		this._translateService.setDefaultLang('en');
		this._translateService.use('en');
		this._translateService.setDefaultLang('en-US');
		this._translateService.use('en-US');
	}

	ngOnDestroy() {
+2 −2
Original line number Diff line number Diff line
@@ -39,8 +39,8 @@ export class DeviceComponent implements OnDestroy, OnInit {
		this._setupDataForSmartTable();
		this._listenForEntityLocaleTranslate();
		this._applyTranslationOnSmartTable();
		this._translateService.setDefaultLang('en');
		this._translateService.use('en');
		this._translateService.setDefaultLang('en-US');
		this._translateService.use('en-US');
	}

	// Maybe "updateDevice" this function is not in use?!
+1 −1
Original line number Diff line number Diff line
@@ -22,7 +22,7 @@ export class ServerDownPage implements OnDestroy {
		private serverConnectionService: ServerConnectionService
	) {
		const browserLang = translate.getBrowserLang();
		translate.use(browserLang.match(/en|bg|he|ru/) ? browserLang : 'en');
		translate.use(browserLang.match(/en|bg|he|ru/) ? browserLang : 'en-US');

		this.noInternetLogo = environment['NO_INTERNET_LOGO'];
		this.testConnection();