Commit 11417a35 authored by iamkun's avatar iamkun Committed by Zhi Cun

update inner check (#16700)

parent e8483acb
...@@ -380,7 +380,7 @@ ...@@ -380,7 +380,7 @@
import compoLang from '../i18n/component.json'; import compoLang from '../i18n/component.json';
import Element from 'main/index.js'; import Element from 'main/index.js';
import themeLoader from './theme/loader'; import themeLoader from './theme/loader';
import { getTestEle, getTestAli } from './theme/loader/api.js'; import { getTestEle } from './theme/loader/api.js';
import bus from '../bus'; import bus from '../bus';
import { ACTION_USER_CONFIG_UPDATE } from './theme/constant.js'; import { ACTION_USER_CONFIG_UPDATE } from './theme/constant.js';
...@@ -434,15 +434,17 @@ ...@@ -434,15 +434,17 @@
ga('send', 'event', 'DocView', 'Ele', 'Outer'); ga('send', 'event', 'DocView', 'Ele', 'Outer');
console.error(err); console.error(err);
}); });
getTestAli()
.then(() => { const testInnerImg = new Image();
this.$isEle = true; testInnerImg.onload = () => {
ga('send', 'event', 'DocView', 'Ali', 'Inner'); this.$isEle = true;
}) ga('send', 'event', 'DocView', 'Ali', 'Inner');
.catch((err) => { };
ga('send', 'event', 'DocView', 'Ali', 'Outer'); testInnerImg.onerror = (err) => {
console.error(err); ga('send', 'event', 'DocView', 'Ali', 'Outer');
}); console.error(err);
};
testInnerImg.src = `https://private-alipayobjects.alipay.com/alipay-rmsdeploy-image/rmsportal/VmvVUItLdPNqKlNGuRHi.png?t=${Date.now()}`;
}, },
methods: { methods: {
switchVersion(version) { switchVersion(version) {
......
...@@ -19,10 +19,6 @@ export const getTestEle = () => { ...@@ -19,10 +19,6 @@ export const getTestEle = () => {
return get(`${hostList.alpha}getVariable`); return get(`${hostList.alpha}getVariable`);
}; };
export const getTestAli = () => {
return get(`https://private-alipayobjects.alipay.com/alipay-rmsdeploy-image/rmsportal/VmvVUItLdPNqKlNGuRHi.png?t=${Date.now()}`);
};
export const updateVars = (data, cb) => { export const updateVars = (data, cb) => {
return post(`${host}updateVariable?version=${version}`, data, cb); return post(`${host}updateVariable?version=${version}`, data, cb);
}; };
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment