|
@@ -9,22 +9,40 @@ import { dayjsFormat } from '@/utils/util'
|
|
|
import { userStore } from '@/store/mobx'
|
|
|
import { Tooltip } from 'antd'
|
|
|
import { observer } from 'mobx-react'
|
|
|
+import { apiGetDashboard } from './api'
|
|
|
+import consts from '@/utils/consts'
|
|
|
+
|
|
|
+interface iState {
|
|
|
+
|
|
|
+}
|
|
|
const Index = () => {
|
|
|
useEffect(() => {
|
|
|
+ initData()
|
|
|
+
|
|
|
+ }, [])
|
|
|
+ useEffect(() => {
|
|
|
if(!userStore.projectInfo.id) {
|
|
|
userStore.getProjectInfo()
|
|
|
}
|
|
|
}, [ userStore.projectInfo.id ])
|
|
|
+ // const [state, setState] = useState(initialState)
|
|
|
+ const initData = async () => {
|
|
|
+ const { code = -1, data } = await apiGetDashboard()
|
|
|
+ if (code !== consts.RET_CODE.SUCCESS) {
|
|
|
+ console.log(data)
|
|
|
+
|
|
|
+ }
|
|
|
+ }
|
|
|
return (
|
|
|
<div className="wrap-contaniner hide-menu">
|
|
|
<Header title="待办事项"></Header>
|
|
|
<div className={styles.content}>
|
|
|
<span>系统消息</span>
|
|
|
<h5 className={styles.title}>{userStore.projectName}</h5>
|
|
|
- <div className={styles.downtime}>
|
|
|
+ {/* <div className={styles.downtime}>
|
|
|
<SvgIcon type="xxh-wrench" style={{ fontSize: '1.5rem' }}></SvgIcon>
|
|
|
<p className={styles.downtimeText}>系统将于 2019年3月10日 14:09 开始停机维护,持续30分钟。造成不便敬请谅解。</p>
|
|
|
- </div>
|
|
|
+ </div> */}
|
|
|
<div className="pi-justify-between">
|
|
|
<div className={[ styles.card, 'pi-flex-quintuple' ].join(' ')}>
|
|
|
<div className={styles.cardHeader}>
|