import React, { PureComponent } from 'react'; import router from 'umi/router'; import { Form, Card, Button } from 'antd'; import { connect } from 'dva'; import Panel from '../../../components/Panel'; import styles from '../../../layouts/Sword.less'; import { CLIENT_DETAIL } from '../../../actions/client'; const FormItem = Form.Item; @connect(({ client }) => ({ client, })) @Form.create() class ClientView extends PureComponent { componentWillMount() { const { dispatch, match: { params: { id }, }, } = this.props; dispatch(CLIENT_DETAIL(id)); } handleEdit = () => { const { match: { params: { id }, }, } = this.props; router.push(`/system/client/edit/${id}`); }; render() { const { client: { detail }, } = this.props; const formItemLayout = { labelCol: { xs: { span: 24 }, sm: { span: 7 }, }, wrapperCol: { xs: { span: 24 }, sm: { span: 12 }, md: { span: 10 }, }, }; const action = ( ); return (
{detail.clientId} {detail.clientSecret} {detail.resourceIds} {detail.scope} {detail.authorizedGrantTypes} {detail.accessTokenValidity} {detail.refreshTokenValidity} {detail.webServerRedirectUri} {detail.authorities} {detail.additionalInformation} {detail.autoapprove}
); } } export default ClientView;