import React from 'react'; import './portal.less'; // import ajax from 'jquery/src/ajax/xhr.js'; // import $ from 'jquery/src/ajax'; import $ from 'jquery'; import logoImg from '../../../image/logo-2.png'; function navHover () { $('.header_nav_detail .nav_content>li').hover(function () { $(this).siblings('.active').addClass('hideSub'); }, function () { $(this).siblings('.active').removeClass('hideSub'); }) } const LoginTop = React.createClass({ logOut () { $.ajax({ method: "get", dataType: "json", url: globalConfig.context + "/login", }).done(function (data) { if (window.userData.mobile) { window.location.href = globalConfig.context + "/user/login.html" } else if (window.adminData.mobile) { window.location.href = globalConfig.context + "/admin/login.html" }; }); }, componentDidMount () { navHover(); }, render () { return (