17 lines
512 B
JavaScript
17 lines
512 B
JavaScript
|
|
import React from 'react';
|
||
|
|
import ReactDOM from 'react-dom';
|
||
|
|
import { WeaTools } from 'ecCom';
|
||
|
|
import WeaPlugin from './index.js';
|
||
|
|
|
||
|
|
(function () {
|
||
|
|
WeaTools.callApi('/api/portal/systemInfo/getIsCheck', 'GET', {}).then((result) => {
|
||
|
|
const { data } = result;
|
||
|
|
const { isCheck } = data;
|
||
|
|
if (isCheck) {
|
||
|
|
const div = document.createElement('div');
|
||
|
|
document.body.appendChild(div);
|
||
|
|
ReactDOM.render(<WeaPlugin visible={true} />, div);
|
||
|
|
}
|
||
|
|
});
|
||
|
|
}());
|