Commit ac4dfc12 authored by 张秀玲's avatar 张秀玲

translate exception pages

parent 57fb525e
......@@ -121,4 +121,8 @@ export default {
'The to-do list will be notified in the form of a letter from the station',
'app.settings.open': 'Open',
'app.settings.close': 'Close',
'app.exception.back': 'Back to home',
'app.exception.description.403': "Sorry, you don't have access to this page",
'app.exception.description.404': 'Sorry, the page you visited does not exist',
'app.exception.description.500': 'Sorry, the server is reporting an error',
};
......@@ -117,4 +117,8 @@ export default {
'app.settings.notification.todo-description': '账户密码',
'app.settings.open': '',
'app.settings.close': '',
'app.exception.back': '返回首页',
'app.exception.description.403': '抱歉,你无权访问该页面',
'app.exception.description.404': '抱歉,你访问的页面不存在',
'app.exception.description.500': '抱歉,服务器出错了',
};
import React from 'react';
import React, { Component } from 'react';
import { injectIntl } from 'react-intl';
import { Link } from 'dva/router';
import Exception from 'components/Exception';
export default () => (
<Exception type="403" style={{ minHeight: 500, height: '80%' }} linkElement={Link} />
);
class Exception403 extends Component {
render() {
const { intl } = this.props;
return (
<Exception
type="403"
desc={intl.formatMessage({ id: 'app.exception.description.403' }, {})}
style={{ minHeight: 500, height: '80%' }}
linkElement={Link}
/>
);
}
}
export default injectIntl(Exception403);
import React from 'react';
import React, { Component } from 'react';
import { injectIntl } from 'react-intl';
import { Link } from 'dva/router';
import Exception from 'components/Exception';
export default () => (
<Exception type="404" style={{ minHeight: 500, height: '80%' }} linkElement={Link} />
);
class Exception404 extends Component {
render() {
const { intl } = this.props;
return (
<Exception
type="404"
desc={intl.formatMessage({ id: 'app.exception.description.404' }, {})}
style={{ minHeight: 500, height: '80%' }}
linkElement={Link}
/>
);
}
}
export default injectIntl(Exception404);
import React from 'react';
import React, { Component } from 'react';
import { injectIntl } from 'react-intl';
import { Link } from 'dva/router';
import Exception from 'components/Exception';
export default () => (
<Exception type="500" style={{ minHeight: 500, height: '80%' }} linkElement={Link} />
);
class Exception500 extends Component {
render() {
const { intl } = this.props;
return (
<Exception
type="500"
desc={intl.formatMessage({ id: 'app.exception.description.500' }, {})}
style={{ minHeight: 500, height: '80%' }}
linkElement={Link}
/>
);
}
}
export default injectIntl(Exception500);
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