import React, { useEffect, useState } from 'react'
import Helmet from 'react-helmet'
import Container, { ContainerBody } from 'components/Container'
import Box from 'components/Box'
import { Col, Icon, Row, Table, Tooltip } from 'antd'
import { PaginationConfig } from 'antd/lib/table'
import { compose } from 'redux'
function DataDictionary() {
const [screenWidth, setScreenWidth] = useState(
document.documentElement.clientWidth
)
const handleSetScreenWidth = () => {
setScreenWidth(document.documentElement.clientWidth)
}
const basePagination: PaginationConfig = {
defaultPageSize: 20,
showSizeChanger: true
}
const tablePagination: PaginationConfig = {
...basePagination,
simple: screenWidth <= 768
}
useEffect(() => {
window.addEventListener('resize', handleSetScreenWidth, false)
return () =>
window.removeEventListener('resize', handleSetScreenWidth, false)
}, [])
return (
数据字典列表
{/* */}
)
}
// const mapDispatchToProps = (dispatch: Dispatch) => ({
// onLoadViews: (projectId) => dispatch(ViewActions.loadViews(projectId)),
// onDeleteView: (viewId, resolve) => dispatch(ViewActions.deleteView(viewId, resolve)),
// onCopyView: (view, resolve) => dispatch(ViewActions.copyView(view, resolve)),
// onCheckName: (data, resolve, reject) => dispatch(checkNameUniqueAction('view', data, resolve, reject))
// })
//
// const mapStateToProps = createStructuredSelector({
// views: makeSelectViews(),
// currentProject: makeSelectCurrentProject(),
// loading: makeSelectLoading()
// })
// const withConnect = connect(mapStateToProps, mapDispatchToProps)
// const withReducer = injectReducer({ key: 'view', reducer })
// const withSaga = injectSaga({ key: 'view', saga: sagas })
export default compose()(DataDictionary)
// withReducer,
// withSaga,
// withConnect