Authored by 于良

修复销售统计页面日期显示7月0号bug review by Author

... ... @@ -8,6 +8,7 @@ import CalendarTrigger from './calendar/CalendarTrigger';
import CalendarPicker from './calendar/CalendarPicker';
import ChartView from './chart/ChartView';
import LoadingIndicator from './indicator/LoadingIndicator';
import moment from 'moment';
const {
Component,
... ... @@ -48,7 +49,7 @@ export default class SaleStatistics extends Component {
constructor(props) {
super(props);
let selectdDate = new Date().getFullYear() + '年' + (new Date().getMonth() + 1) + '月' + (new Date().getDate() - 1) + '日';
let selectdDate = moment().subtract(1,'days').format('YYYY年MM月DD日');
this.state = {
showPicker: false,
selectdDate,
... ... @@ -111,7 +112,7 @@ export default class SaleStatistics extends Component {
}
render() {
return (
<ScrollView contentContainerStyle={styles.contentContainer}>
<CalendarTrigger date={this.state.selectdDate} toogleSelector={this.toogleSelector} />
... ...