|
@@ -1,6 +1,27 @@
|
|
|
let envHost = process.env.API_ROOT;
|
|
|
|
|
|
-var enter_url = "";
|
|
|
+let enter_url = "";
|
|
|
+
|
|
|
+let mobile = {
|
|
|
+ Android: function() {
|
|
|
+ return navigator.userAgent.match(/Android/i);
|
|
|
+ },
|
|
|
+ BlackBerry: function() {
|
|
|
+ return navigator.userAgent.match(/BlackBerry/i);
|
|
|
+ },
|
|
|
+ iOS: function() {
|
|
|
+ return navigator.userAgent.match(/iPhone|iPad|iPod/i);
|
|
|
+ },
|
|
|
+ Opera: function() {
|
|
|
+ return navigator.userAgent.match(/Opera Mini/i);
|
|
|
+ },
|
|
|
+ Windows: function() {
|
|
|
+ return navigator.userAgent.match(/IEMobile/i);
|
|
|
+ },
|
|
|
+ any: function() {
|
|
|
+ return (mobile.Android() || mobile.BlackBerry() || mobile.iOS() || mobile.Opera() || mobile.Windows());
|
|
|
+ }
|
|
|
+};
|
|
|
|
|
|
class Api
|
|
|
{
|
|
@@ -133,7 +154,7 @@ class Api
|
|
|
|
|
|
static sign_url(href)
|
|
|
{
|
|
|
- if(isMobile.iOS()) {
|
|
|
+ if(mobile.iOS()) {
|
|
|
return enter_url;
|
|
|
} else {
|
|
|
return href;
|