动态菜单和动态路由的 antd pro

RegisterResult.js 915B

12345678910111213141516171819202122232425262728293031323334
  1. import React from 'react';
  2. import { Button } from 'antd';
  3. import { Link } from 'dva/router';
  4. import Result from 'components/Result';
  5. import styles from './RegisterResult.less';
  6. const actions = (
  7. <div className={styles.actions}>
  8. <a href="">
  9. <Button size="large" type="primary">
  10. 查看邮箱
  11. </Button>
  12. </a>
  13. <Link to="/">
  14. <Button size="large">返回首页</Button>
  15. </Link>
  16. </div>
  17. );
  18. export default ({ location }) => (
  19. <Result
  20. className={styles.registerResult}
  21. type="success"
  22. title={
  23. <div className={styles.title}>
  24. 你的账户:{location.state ? location.state.account : 'AntDesign@example.com'} 注册成功
  25. </div>
  26. }
  27. description="激活邮件已发送到你的邮箱中,邮件有效期为24小时。请及时登录邮箱,点击邮件中的链接激活帐户。"
  28. actions={actions}
  29. style={{ marginTop: 56 }}
  30. />
  31. );