Commit 1a116f98 authored by wty's avatar wty

前端更新打包

parent 2014702d
{
"files": {
"main.css": "/static/css/main.63c35fee.chunk.css",
"main.js": "/static/js/main.b54c2f44.chunk.js",
"main.js.map": "/static/js/main.b54c2f44.chunk.js.map",
"main.js": "/static/js/main.003ab051.chunk.js",
"main.js.map": "/static/js/main.003ab051.chunk.js.map",
"runtime-main.js": "/static/js/runtime-main.4628cb4f.js",
"runtime-main.js.map": "/static/js/runtime-main.4628cb4f.js.map",
"static/css/2.1f1ea42e.chunk.css": "/static/css/2.1f1ea42e.chunk.css",
"static/js/2.44df36db.chunk.js": "/static/js/2.44df36db.chunk.js",
"static/js/2.44df36db.chunk.js.map": "/static/js/2.44df36db.chunk.js.map",
"static/js/2.c0da6fb9.chunk.js": "/static/js/2.c0da6fb9.chunk.js",
"static/js/2.c0da6fb9.chunk.js.map": "/static/js/2.c0da6fb9.chunk.js.map",
"static/js/3.4971491c.chunk.js": "/static/js/3.4971491c.chunk.js",
"static/js/3.4971491c.chunk.js.map": "/static/js/3.4971491c.chunk.js.map",
"index.html": "/index.html",
"static/css/2.1f1ea42e.chunk.css.map": "/static/css/2.1f1ea42e.chunk.css.map",
"static/css/main.63c35fee.chunk.css.map": "/static/css/main.63c35fee.chunk.css.map",
"static/js/2.44df36db.chunk.js.LICENSE.txt": "/static/js/2.44df36db.chunk.js.LICENSE.txt",
"static/js/2.c0da6fb9.chunk.js.LICENSE.txt": "/static/js/2.c0da6fb9.chunk.js.LICENSE.txt",
"static/media/dragIcon.268403b1.svg": "/static/media/dragIcon.268403b1.svg",
"static/media/logo.c725c5d1.png": "/static/media/logo.c725c5d1.png",
"static/media/setting.6a716d85.svg": "/static/media/setting.6a716d85.svg",
......@@ -22,8 +22,8 @@
"entrypoints": [
"static/js/runtime-main.4628cb4f.js",
"static/css/2.1f1ea42e.chunk.css",
"static/js/2.44df36db.chunk.js",
"static/js/2.c0da6fb9.chunk.js",
"static/css/main.63c35fee.chunk.css",
"static/js/main.b54c2f44.chunk.js"
"static/js/main.003ab051.chunk.js"
]
}
\ No newline at end of file
<!doctype html><html lang="en"><head><meta charset="utf-8"/><link rel="icon" href="/favicon.ico"/><meta name="viewport" content="width=device-width,initial-scale=1"/><meta name="theme-color" content="#000000"/><meta name="description" content="Web site created using create-react-app"/><link rel="apple-touch-icon" href="/logo192.png"/><link rel="manifest" href="/manifest.json"/><title>React App</title><link href="/static/css/2.1f1ea42e.chunk.css" rel="stylesheet"><link href="/static/css/main.63c35fee.chunk.css" rel="stylesheet"></head><body><noscript>You need to enable JavaScript to run this app.</noscript><div id="root"></div><script>!function(e){function r(r){for(var n,i,a=r[0],c=r[1],l=r[2],s=0,p=[];s<a.length;s++)i=a[s],Object.prototype.hasOwnProperty.call(o,i)&&o[i]&&p.push(o[i][0]),o[i]=0;for(n in c)Object.prototype.hasOwnProperty.call(c,n)&&(e[n]=c[n]);for(f&&f(r);p.length;)p.shift()();return u.push.apply(u,l||[]),t()}function t(){for(var e,r=0;r<u.length;r++){for(var t=u[r],n=!0,a=1;a<t.length;a++){var c=t[a];0!==o[c]&&(n=!1)}n&&(u.splice(r--,1),e=i(i.s=t[0]))}return e}var n={},o={1:0},u=[];function i(r){if(n[r])return n[r].exports;var t=n[r]={i:r,l:!1,exports:{}};return e[r].call(t.exports,t,t.exports,i),t.l=!0,t.exports}i.e=function(e){var r=[],t=o[e];if(0!==t)if(t)r.push(t[2]);else{var n=new Promise((function(r,n){t=o[e]=[r,n]}));r.push(t[2]=n);var u,a=document.createElement("script");a.charset="utf-8",a.timeout=120,i.nc&&a.setAttribute("nonce",i.nc),a.src=function(e){return i.p+"static/js/"+({}[e]||e)+"."+{3:"4971491c"}[e]+".chunk.js"}(e);var c=new Error;u=function(r){a.onerror=a.onload=null,clearTimeout(l);var t=o[e];if(0!==t){if(t){var n=r&&("load"===r.type?"missing":r.type),u=r&&r.target&&r.target.src;c.message="Loading chunk "+e+" failed.\n("+n+": "+u+")",c.name="ChunkLoadError",c.type=n,c.request=u,t[1](c)}o[e]=void 0}};var l=setTimeout((function(){u({type:"timeout",target:a})}),12e4);a.onerror=a.onload=u,document.head.appendChild(a)}return Promise.all(r)},i.m=e,i.c=n,i.d=function(e,r,t){i.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:t})},i.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.t=function(e,r){if(1&r&&(e=i(e)),8&r)return e;if(4&r&&"object"==typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(i.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var n in e)i.d(t,n,function(r){return e[r]}.bind(null,n));return t},i.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(r,"a",r),r},i.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},i.p="/",i.oe=function(e){throw console.error(e),e};var a=this.webpackJsonpdui123=this.webpackJsonpdui123||[],c=a.push.bind(a);a.push=r,a=a.slice();for(var l=0;l<a.length;l++)r(a[l]);var f=c;t()}([])</script><script src="/static/js/2.44df36db.chunk.js"></script><script src="/static/js/main.b54c2f44.chunk.js"></script></body></html>
\ No newline at end of file
<!doctype html><html lang="en"><head><meta charset="utf-8"/><link rel="shortcut icon" type="image/x-icon" href="https://yun.duiba.com.cn/logo.png"><meta name="viewport" content="width=device-width,initial-scale=1"/><meta name="theme-color" content="#000000"/><meta name="description" content="Web site created using create-react-app"/><link rel="apple-touch-icon" href="/logo192.png"/><link rel="manifest" href="/manifest.json"/><title>Dui123工具箱-你的第一个工具箱何必是一个工具箱</title><link href="/static/css/2.1f1ea42e.chunk.css" rel="stylesheet"><link href="/static/css/main.63c35fee.chunk.css" rel="stylesheet"></head><body><noscript>You need to enable JavaScript to run this app.</noscript><div id="root"></div><script>!function(e){function r(r){for(var n,i,a=r[0],c=r[1],l=r[2],s=0,p=[];s<a.length;s++)i=a[s],Object.prototype.hasOwnProperty.call(o,i)&&o[i]&&p.push(o[i][0]),o[i]=0;for(n in c)Object.prototype.hasOwnProperty.call(c,n)&&(e[n]=c[n]);for(f&&f(r);p.length;)p.shift()();return u.push.apply(u,l||[]),t()}function t(){for(var e,r=0;r<u.length;r++){for(var t=u[r],n=!0,a=1;a<t.length;a++){var c=t[a];0!==o[c]&&(n=!1)}n&&(u.splice(r--,1),e=i(i.s=t[0]))}return e}var n={},o={1:0},u=[];function i(r){if(n[r])return n[r].exports;var t=n[r]={i:r,l:!1,exports:{}};return e[r].call(t.exports,t,t.exports,i),t.l=!0,t.exports}i.e=function(e){var r=[],t=o[e];if(0!==t)if(t)r.push(t[2]);else{var n=new Promise((function(r,n){t=o[e]=[r,n]}));r.push(t[2]=n);var u,a=document.createElement("script");a.charset="utf-8",a.timeout=120,i.nc&&a.setAttribute("nonce",i.nc),a.src=function(e){return i.p+"static/js/"+({}[e]||e)+"."+{3:"4971491c"}[e]+".chunk.js"}(e);var c=new Error;u=function(r){a.onerror=a.onload=null,clearTimeout(l);var t=o[e];if(0!==t){if(t){var n=r&&("load"===r.type?"missing":r.type),u=r&&r.target&&r.target.src;c.message="Loading chunk "+e+" failed.\n("+n+": "+u+")",c.name="ChunkLoadError",c.type=n,c.request=u,t[1](c)}o[e]=void 0}};var l=setTimeout((function(){u({type:"timeout",target:a})}),12e4);a.onerror=a.onload=u,document.head.appendChild(a)}return Promise.all(r)},i.m=e,i.c=n,i.d=function(e,r,t){i.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:t})},i.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.t=function(e,r){if(1&r&&(e=i(e)),8&r)return e;if(4&r&&"object"==typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(i.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var n in e)i.d(t,n,function(r){return e[r]}.bind(null,n));return t},i.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(r,"a",r),r},i.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},i.p="/",i.oe=function(e){throw console.error(e),e};var a=this.webpackJsonpdui123=this.webpackJsonpdui123||[],c=a.push.bind(a);a.push=r,a=a.slice();for(var l=0;l<a.length;l++)r(a[l]);var f=c;t()}([])</script><script src="/static/js/2.c0da6fb9.chunk.js"></script><script src="/static/js/main.003ab051.chunk.js"></script></body></html>
\ No newline at end of file
This diff is collapsed.
......@@ -2,7 +2,7 @@
<html lang="en">
<head>
<meta charset="utf-8" />
<link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
<link rel="shortcut icon" type="image/x-icon" href="https://yun.duiba.com.cn/logo.png">
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="theme-color" content="#000000" />
<meta
......@@ -24,7 +24,7 @@
work correctly both with client-side routing and a non-root public URL.
Learn how to configure a non-root public URL by running `npm run build`.
-->
<title>React App</title>
<title>Dui123工具箱-你的第一个工具箱何必是一个工具箱</title>
</head>
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
......
{
"files": {
"main.css": "/static/css/main.63c35fee.chunk.css",
"main.js": "/static/js/main.b54c2f44.chunk.js",
"main.js.map": "/static/js/main.b54c2f44.chunk.js.map",
"main.js": "/static/js/main.003ab051.chunk.js",
"main.js.map": "/static/js/main.003ab051.chunk.js.map",
"runtime-main.js": "/static/js/runtime-main.4628cb4f.js",
"runtime-main.js.map": "/static/js/runtime-main.4628cb4f.js.map",
"static/css/2.1f1ea42e.chunk.css": "/static/css/2.1f1ea42e.chunk.css",
"static/js/2.44df36db.chunk.js": "/static/js/2.44df36db.chunk.js",
"static/js/2.44df36db.chunk.js.map": "/static/js/2.44df36db.chunk.js.map",
"static/js/2.c0da6fb9.chunk.js": "/static/js/2.c0da6fb9.chunk.js",
"static/js/2.c0da6fb9.chunk.js.map": "/static/js/2.c0da6fb9.chunk.js.map",
"static/js/3.4971491c.chunk.js": "/static/js/3.4971491c.chunk.js",
"static/js/3.4971491c.chunk.js.map": "/static/js/3.4971491c.chunk.js.map",
"index.html": "/index.html",
"static/css/2.1f1ea42e.chunk.css.map": "/static/css/2.1f1ea42e.chunk.css.map",
"static/css/main.63c35fee.chunk.css.map": "/static/css/main.63c35fee.chunk.css.map",
"static/js/2.44df36db.chunk.js.LICENSE.txt": "/static/js/2.44df36db.chunk.js.LICENSE.txt",
"static/js/2.c0da6fb9.chunk.js.LICENSE.txt": "/static/js/2.c0da6fb9.chunk.js.LICENSE.txt",
"static/media/dragIcon.268403b1.svg": "/static/media/dragIcon.268403b1.svg",
"static/media/logo.c725c5d1.png": "/static/media/logo.c725c5d1.png",
"static/media/setting.6a716d85.svg": "/static/media/setting.6a716d85.svg",
......@@ -22,8 +22,8 @@
"entrypoints": [
"static/js/runtime-main.4628cb4f.js",
"static/css/2.1f1ea42e.chunk.css",
"static/js/2.44df36db.chunk.js",
"static/js/2.c0da6fb9.chunk.js",
"static/css/main.63c35fee.chunk.css",
"static/js/main.b54c2f44.chunk.js"
"static/js/main.003ab051.chunk.js"
]
}
\ No newline at end of file
<!doctype html><html lang="en"><head><meta charset="utf-8"/><link rel="icon" href="/favicon.ico"/><meta name="viewport" content="width=device-width,initial-scale=1"/><meta name="theme-color" content="#000000"/><meta name="description" content="Web site created using create-react-app"/><link rel="apple-touch-icon" href="/logo192.png"/><link rel="manifest" href="/manifest.json"/><title>React App</title><link href="/static/css/2.1f1ea42e.chunk.css" rel="stylesheet"><link href="/static/css/main.63c35fee.chunk.css" rel="stylesheet"></head><body><noscript>You need to enable JavaScript to run this app.</noscript><div id="root"></div><script>!function(e){function r(r){for(var n,i,a=r[0],c=r[1],l=r[2],s=0,p=[];s<a.length;s++)i=a[s],Object.prototype.hasOwnProperty.call(o,i)&&o[i]&&p.push(o[i][0]),o[i]=0;for(n in c)Object.prototype.hasOwnProperty.call(c,n)&&(e[n]=c[n]);for(f&&f(r);p.length;)p.shift()();return u.push.apply(u,l||[]),t()}function t(){for(var e,r=0;r<u.length;r++){for(var t=u[r],n=!0,a=1;a<t.length;a++){var c=t[a];0!==o[c]&&(n=!1)}n&&(u.splice(r--,1),e=i(i.s=t[0]))}return e}var n={},o={1:0},u=[];function i(r){if(n[r])return n[r].exports;var t=n[r]={i:r,l:!1,exports:{}};return e[r].call(t.exports,t,t.exports,i),t.l=!0,t.exports}i.e=function(e){var r=[],t=o[e];if(0!==t)if(t)r.push(t[2]);else{var n=new Promise((function(r,n){t=o[e]=[r,n]}));r.push(t[2]=n);var u,a=document.createElement("script");a.charset="utf-8",a.timeout=120,i.nc&&a.setAttribute("nonce",i.nc),a.src=function(e){return i.p+"static/js/"+({}[e]||e)+"."+{3:"4971491c"}[e]+".chunk.js"}(e);var c=new Error;u=function(r){a.onerror=a.onload=null,clearTimeout(l);var t=o[e];if(0!==t){if(t){var n=r&&("load"===r.type?"missing":r.type),u=r&&r.target&&r.target.src;c.message="Loading chunk "+e+" failed.\n("+n+": "+u+")",c.name="ChunkLoadError",c.type=n,c.request=u,t[1](c)}o[e]=void 0}};var l=setTimeout((function(){u({type:"timeout",target:a})}),12e4);a.onerror=a.onload=u,document.head.appendChild(a)}return Promise.all(r)},i.m=e,i.c=n,i.d=function(e,r,t){i.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:t})},i.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.t=function(e,r){if(1&r&&(e=i(e)),8&r)return e;if(4&r&&"object"==typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(i.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var n in e)i.d(t,n,function(r){return e[r]}.bind(null,n));return t},i.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(r,"a",r),r},i.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},i.p="/",i.oe=function(e){throw console.error(e),e};var a=this.webpackJsonpdui123=this.webpackJsonpdui123||[],c=a.push.bind(a);a.push=r,a=a.slice();for(var l=0;l<a.length;l++)r(a[l]);var f=c;t()}([])</script><script src="/static/js/2.44df36db.chunk.js"></script><script src="/static/js/main.b54c2f44.chunk.js"></script></body></html>
\ No newline at end of file
<!doctype html><html lang="en"><head><meta charset="utf-8"/><link rel="shortcut icon" type="image/x-icon" href="https://yun.duiba.com.cn/logo.png"><meta name="viewport" content="width=device-width,initial-scale=1"/><meta name="theme-color" content="#000000"/><meta name="description" content="Web site created using create-react-app"/><link rel="apple-touch-icon" href="/logo192.png"/><link rel="manifest" href="/manifest.json"/><title>Dui123工具箱-你的第一个工具箱何必是一个工具箱</title><link href="/static/css/2.1f1ea42e.chunk.css" rel="stylesheet"><link href="/static/css/main.63c35fee.chunk.css" rel="stylesheet"></head><body><noscript>You need to enable JavaScript to run this app.</noscript><div id="root"></div><script>!function(e){function r(r){for(var n,i,a=r[0],c=r[1],l=r[2],s=0,p=[];s<a.length;s++)i=a[s],Object.prototype.hasOwnProperty.call(o,i)&&o[i]&&p.push(o[i][0]),o[i]=0;for(n in c)Object.prototype.hasOwnProperty.call(c,n)&&(e[n]=c[n]);for(f&&f(r);p.length;)p.shift()();return u.push.apply(u,l||[]),t()}function t(){for(var e,r=0;r<u.length;r++){for(var t=u[r],n=!0,a=1;a<t.length;a++){var c=t[a];0!==o[c]&&(n=!1)}n&&(u.splice(r--,1),e=i(i.s=t[0]))}return e}var n={},o={1:0},u=[];function i(r){if(n[r])return n[r].exports;var t=n[r]={i:r,l:!1,exports:{}};return e[r].call(t.exports,t,t.exports,i),t.l=!0,t.exports}i.e=function(e){var r=[],t=o[e];if(0!==t)if(t)r.push(t[2]);else{var n=new Promise((function(r,n){t=o[e]=[r,n]}));r.push(t[2]=n);var u,a=document.createElement("script");a.charset="utf-8",a.timeout=120,i.nc&&a.setAttribute("nonce",i.nc),a.src=function(e){return i.p+"static/js/"+({}[e]||e)+"."+{3:"4971491c"}[e]+".chunk.js"}(e);var c=new Error;u=function(r){a.onerror=a.onload=null,clearTimeout(l);var t=o[e];if(0!==t){if(t){var n=r&&("load"===r.type?"missing":r.type),u=r&&r.target&&r.target.src;c.message="Loading chunk "+e+" failed.\n("+n+": "+u+")",c.name="ChunkLoadError",c.type=n,c.request=u,t[1](c)}o[e]=void 0}};var l=setTimeout((function(){u({type:"timeout",target:a})}),12e4);a.onerror=a.onload=u,document.head.appendChild(a)}return Promise.all(r)},i.m=e,i.c=n,i.d=function(e,r,t){i.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:t})},i.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.t=function(e,r){if(1&r&&(e=i(e)),8&r)return e;if(4&r&&"object"==typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(i.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var n in e)i.d(t,n,function(r){return e[r]}.bind(null,n));return t},i.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(r,"a",r),r},i.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},i.p="/",i.oe=function(e){throw console.error(e),e};var a=this.webpackJsonpdui123=this.webpackJsonpdui123||[],c=a.push.bind(a);a.push=r,a=a.slice();for(var l=0;l<a.length;l++)r(a[l]);var f=c;t()}([])</script><script src="/static/js/2.c0da6fb9.chunk.js"></script><script src="/static/js/main.003ab051.chunk.js"></script></body></html>
\ No newline at end of file
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -43,10 +43,10 @@ function ContentItemAdmin(props) {
<div className="item-name" onClick={() => jumpUrl(toolbox_url)}>{toolbox_name}</div>
<div className="item-desc">{toolbox_desc}</div>
<a className='item-url' href={toolbox_url}>{toolbox_url}</a>
<div className="follow">
<img className='icon-follow' src={follow ? followed : notFollow} alt=""/>
收藏
</div>
{/*<div className="follow">*/}
{/* <img className='icon-follow' src={follow ? followed : notFollow} alt=""/>*/}
{/* 收藏*/}
{/*</div>*/}
{visible && <ToolModal
visible={visible}
onCancel={() =>
......
......@@ -5,13 +5,15 @@ import Content from "../../component/Content/Content";
import {Root} from "../../dataCenter/Root";
import {useContext, useEffect} from "react";
import {NEED_UPDATE_INDEX} from "../../dataCenter/action";
import {useHistory} from "react-router-dom";
function Index() {
const history = useHistory()
const {fetchData, dataCenter, dispatch} = useContext(Root)
const getUser = () => {
fetchData('/users/getUser', {uid: '100001'}, 'userInfo')
.catch(res =>
res.code === 70001 && (window.location.href = '/login')
res.code === 70001 && (history.push('/login'))
)
}
useEffect(() => {
......@@ -58,7 +60,7 @@ function Index() {
<Content/>
</div>
<div className="index-footer">
兑吧研发中心·杭州兑吧网络科技游戏公司版权所有
兑吧研发中心·杭州兑吧网络科技有限公司版权所有
<br/>
浙ICP备14017299号-1
</div>
......
......@@ -6,8 +6,10 @@ import {PopContext, Root} from "../../dataCenter/Root";
import {useContext, useEffect, useState} from "react";
import {NEED_UPDATE_INDEX} from "../../dataCenter/action";
import AdminIndex from "../../component/AdminIndex/AdminIndex";
import {useHistory} from "react-router-dom";
function Index() {
const history = useHistory()
const [pop, setPop] = useState()
const {fetchData, dataCenter, dispatch} = useContext(Root)
const showPop = popComponent => {
......@@ -16,7 +18,7 @@ function Index() {
const getUser = () => {
fetchData('/users/getUser', {uid: '100001'}, 'userInfo')
.catch(res =>
res.code === 70001 && (window.location.href = '/login')
res.code === 70001 && (history.push('/login'))
)
}
......@@ -64,9 +66,6 @@ function Index() {
<div className="container">
<Content/>
</div>
{
pop
}
<div className="index-footer">
兑吧研发中心·杭州兑吧网络科技游戏公司版权所有
<br/>
......
......@@ -2,14 +2,16 @@ import './login.scss'
import {useContext, useEffect, useState} from "react";
import {Root} from "../../dataCenter/Root";
import {useFormState} from "../../utils/hook";
import {useHistory} from "react-router-dom";
function Login(props) {
const history = useHistory()
const {fetchData, dataCenter} = useContext(Root)
const [needLogin,setNeedLogin] = useState(false)
const [input, setInput] = useFormState()
const getUser = ()=>{
fetchData('/users/getUser', {uid:'100001'}, 'userInfo')
.then(res => res.data.uid && (window.location.href = '/index'))
.then(res => res.data.uid && (history.push('/')))
.catch(res =>
res.code === 70001 && setNeedLogin(true)
)
......
......@@ -10214,7 +10214,7 @@ react-router-dom@^5.2.1:
tiny-invariant "^1.0.2"
tiny-warning "^1.0.0"
react-router@5.2.1, react-router@^5.2.1:
react-router@5.2.1:
version "5.2.1"
resolved "http://npm.dui88.com:80/react-router/-/react-router-5.2.1.tgz#4d2e4e9d5ae9425091845b8dbc6d9d276239774d"
integrity sha1-TS5OnVrpQlCRhFuNvG2dJ2I5d00=
......
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