remove unused code in demo

This commit is contained in:
afc163 2016-11-23 20:24:36 +08:00
parent 2260701865
commit a8c4f53922

View File

@ -36,12 +36,6 @@ const columns = [{
dataIndex: 'age', dataIndex: 'age',
}]; }];
const customLocale = {
timezoneOffset: 8 * 60,
firstDayOfWeek: 1,
minimalDaysInFirstWeek: 1,
};
const Page = React.createClass({ const Page = React.createClass({
getInitialState() { getInitialState() {
return { return {
@ -127,10 +121,6 @@ const App = React.createClass({
} }
}, },
render() { render() {
const locale = { ...this.state.locale };
if (locale.DatePicker) {
locale.DatePicker = { ...locale.DatePicker, ...customLocale };
}
return ( return (
<div> <div>
<div className="change-locale"> <div className="change-locale">
@ -140,7 +130,7 @@ const App = React.createClass({
<Radio.Button key="cn">中文</Radio.Button> <Radio.Button key="cn">中文</Radio.Button>
</Radio.Group> </Radio.Group>
</div> </div>
<LocaleProvider locale={locale}><Page /></LocaleProvider> <LocaleProvider locale={this.state.locale}><Page /></LocaleProvider>
</div> </div>
); );
}, },