forked from EVOgeek/Vmeda.Online
		
	Merge pull request #4138 from alfonso-salces/MOBILE-4581
MOBILE-4581 utils: Add lang to openInBrowser urls
This commit is contained in:
		
						commit
						071eee20bb
					
				@ -17,7 +17,7 @@ import { InAppBrowserObject, InAppBrowserOptions } from '@awesome-cordova-plugin
 | 
				
			|||||||
import { FileEntry } from '@awesome-cordova-plugins/file/ngx';
 | 
					import { FileEntry } from '@awesome-cordova-plugins/file/ngx';
 | 
				
			||||||
import { CoreEvents } from '@singletons/events';
 | 
					import { CoreEvents } from '@singletons/events';
 | 
				
			||||||
import { CoreFile } from '@services/file';
 | 
					import { CoreFile } from '@services/file';
 | 
				
			||||||
import { CoreLang } from '@services/lang';
 | 
					import { CoreLang, CoreLangFormat } from '@services/lang';
 | 
				
			||||||
import { CoreWS } from '@services/ws';
 | 
					import { CoreWS } from '@services/ws';
 | 
				
			||||||
import { CoreMimetypeUtils } from '@services/utils/mimetype';
 | 
					import { CoreMimetypeUtils } from '@services/utils/mimetype';
 | 
				
			||||||
import { CoreTextUtils } from '@services/utils/text';
 | 
					import { CoreTextUtils } from '@services/utils/text';
 | 
				
			||||||
@ -1173,12 +1173,14 @@ export class CoreUtilsProvider {
 | 
				
			|||||||
            }
 | 
					            }
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        CoreAnalytics.logEvent({
 | 
					        const site = CoreSites.getCurrentSite();
 | 
				
			||||||
            type: CoreAnalyticsEventType.OPEN_LINK,
 | 
					        CoreAnalytics.logEvent({ type: CoreAnalyticsEventType.OPEN_LINK, link: originaUrl });
 | 
				
			||||||
            link: originaUrl,
 | 
					        window.open(
 | 
				
			||||||
        });
 | 
					            site?.containsUrl(url)
 | 
				
			||||||
 | 
					                ? CoreUrl.addParamsToUrl(url, { lang: await CoreLang.getCurrentLanguage(CoreLangFormat.LMS) })
 | 
				
			||||||
        window.open(url, '_system');
 | 
					                : url,
 | 
				
			||||||
 | 
					            '_system',
 | 
				
			||||||
 | 
					        );
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    /**
 | 
					    /**
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user