Định dạng ngày kiểm soát biểu mẫu Reac-bootstrap

Phân tích sâu hơn về trạng thái bảo trì của công cụ chọn ngày-bootstrap dựa trên nhịp phiên bản npm đã phát hành, hoạt động của kho lưu trữ và các điểm dữ liệu khác đã xác định rằng việc bảo trì của nó là Không hoạt động

Một tín hiệu bảo trì dự án quan trọng cần xem xét đối với công cụ chọn ngày khởi động lại phản ứng là nó không thấy bất kỳ phiên bản mới nào được phát hành cho npm trong 12 tháng qua và có thể được coi là một dự án đã ngừng hoặc ít nhận được sự chú ý từ

Trong tháng trước, chúng tôi không tìm thấy bất kỳ hoạt động yêu cầu kéo nào hoặc thay đổi trạng thái vấn đề đã được phát hiện đối với kho lưu trữ GitHub

Bộ chọn ngày dựa trên React-Bootstrap

Định dạng ngày kiểm soát biểu mẫu Reac-bootstrap
Định dạng ngày kiểm soát biểu mẫu Reac-bootstrap
Định dạng ngày kiểm soát biểu mẫu Reac-bootstrap
Định dạng ngày kiểm soát biểu mẫu Reac-bootstrap
Định dạng ngày kiểm soát biểu mẫu Reac-bootstrap

Xem demo tại pushtell. github. io/Reac-bootstrap-date-picker

Định dạng ngày kiểm soát biểu mẫu Reac-bootstrap

Vui lòng ★ trên GitHub

Sử dụng mô-đun này trong sản xuất?

Mục lục
  • Cài đặt
  • Cách sử dụng
  • Tham chiếu API
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      8
  • bài kiểm tra
    • Bảo hiểm trình duyệt
    • Chạy thử nghiệm

Cài đặt

var DatePicker = require("react-bootstrap-date-picker");

 

var App = React.createClass({

  getInitialState: function(){

    var value = new Date().toISOString();

    return {

      value: value

    }

  },

  handleChange: function(value, formattedValue) {

    this.setState({

      value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

      formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

    });

  },

  componentDidUpdate: function(){

    // Access ISO String and formatted values from the DOM.

    var hiddenInputElement = document.getElementById("example-datepicker");

    console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

    console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

  },

  render: function(){

    return <FormGroup>

      <ControlLabel>Label</ControlLabel>

      <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

      <HelpBlock>Help</HelpBlock>

    </FormGroup>;

  }

});

 

9 tương thích với React 0. 14. x và 0. 15. x

npm install react-bootstrap-date-picker

Cách sử dụng

var DatePicker = require("react-bootstrap-date-picker");

 

var App = React.createClass({

  getInitialState: function(){

    var value = new Date().toISOString();

    return {

      value: value

    }

  },

  handleChange: function(value, formattedValue) {

    this.setState({

      value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

      formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

    });

  },

  componentDidUpdate: function(){

    // Access ISO String and formatted values from the DOM.

    var hiddenInputElement = document.getElementById("example-datepicker");

    console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

    console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

  },

  render: function(){

    return <FormGroup>

      <ControlLabel>Label</ControlLabel>

      <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

      <HelpBlock>Help</HelpBlock>

    </FormGroup>;

  }

});

 

Tham chiếu API

var DatePicker = require("react-bootstrap-date-picker"); var App = React.createClass({  getInitialState: function(){    var value = new Date().toISOString();    return {      value: value    }  },  handleChange: function(value, formattedValue) {    this.setState({      value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"      formattedValue: formattedValue // Formatted String, ex: "11/19/2016"    });  },  componentDidUpdate: function(){    // Access ISO String and formatted values from the DOM.    var hiddenInputElement = document.getElementById("example-datepicker");    console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"    console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"  },  render: function(){    return       Label            Help    ;  }}); 8

Thành phần DatePicker. Hiển thị dưới dạng Nhóm đầu vào React-Bootstrap

Các thuộc tính của Nhóm đầu vào được chuyển qua nhóm đầu vào

  • Tính chất

    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      1 - Chuỗi ngày ISO đại diện cho giá trị hiện tại
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        2
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        3
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      0 - Chuỗi ngày ISO đại diện cho giá trị mặc định. Không thể được đặt với 'giá trị'
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        2
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        3
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      3 - Chuỗi ngày ISO để đặt giá trị ngày thấp nhất cho phép
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        2
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        3
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      6 - Chuỗi ngày ISO để đặt giá trị ngày cao nhất cho phép
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        2
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        3
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      9 - Đối tượng kiểu được chuyển đến phần tử đầu vào

       

      npm test

       

      0
      • Không bắt buộc
      • Loại.

         

        npm test

         

        1
      • Ví dụ.

         

        npm test

         

        2
    •  

      npm test

       

      3 - Tên lớp được truyền cho phần tử đầu vào

       

      npm test

       

      0
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        2
      • Ví dụ.

         

        npm test

         

        6
    •  

      npm test

       

      7 - thuộc tính autoComplete được truyền cho phần tử đầu vào

       

      npm test

       

      0
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        2
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        40
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      41 - Thành phần có bắt đầu bằng tiêu điểm hay không
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        42
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        43
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      44 - Thành phần có bị vô hiệu hóa hay không
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        42
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        43
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      47 - Chức năng gọi lại tập trung
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        48
      • Đối số gọi lại
        • var DatePicker = require("react-bootstrap-date-picker");

           

          var App = React.createClass({

            getInitialState: function(){

              var value = new Date().toISOString();

              return {

                value: value

              }

            },

            handleChange: function(value, formattedValue) {

              this.setState({

                value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

                formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

              });

            },

            componentDidUpdate: function(){

              // Access ISO String and formatted values from the DOM.

              var hiddenInputElement = document.getElementById("example-datepicker");

              console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

              console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

            },

            render: function(){

              return <FormGroup>

                <ControlLabel>Label</ControlLabel>

                <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

                <HelpBlock>Help</HelpBlock>

              </FormGroup>;

            }

          });

           

          1 - Chuỗi ngày ISO đại diện cho giá trị đã chọn
          • Loại.

            var DatePicker = require("react-bootstrap-date-picker");

             

            var App = React.createClass({

              getInitialState: function(){

                var value = new Date().toISOString();

                return {

                  value: value

                }

              },

              handleChange: function(value, formattedValue) {

                this.setState({

                  value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

                  formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

                });

              },

              componentDidUpdate: function(){

                // Access ISO String and formatted values from the DOM.

                var hiddenInputElement = document.getElementById("example-datepicker");

                console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

                console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

              },

              render: function(){

                return <FormGroup>

                  <ControlLabel>Label</ControlLabel>

                  <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

                  <HelpBlock>Help</HelpBlock>

                </FormGroup>;

              }

            });

             

            80
          • Ví dụ.

            var DatePicker = require("react-bootstrap-date-picker");

             

            var App = React.createClass({

              getInitialState: function(){

                var value = new Date().toISOString();

                return {

                  value: value

                }

              },

              handleChange: function(value, formattedValue) {

                this.setState({

                  value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

                  formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

                });

              },

              componentDidUpdate: function(){

                // Access ISO String and formatted values from the DOM.

                var hiddenInputElement = document.getElementById("example-datepicker");

                console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

                console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

              },

              render: function(){

                return <FormGroup>

                  <ControlLabel>Label</ControlLabel>

                  <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

                  <HelpBlock>Help</HelpBlock>

                </FormGroup>;

              }

            });

             

            3
        • var DatePicker = require("react-bootstrap-date-picker");

           

          var App = React.createClass({

            getInitialState: function(){

              var value = new Date().toISOString();

              return {

                value: value

              }

            },

            handleChange: function(value, formattedValue) {

              this.setState({

                value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

                formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

              });

            },

            componentDidUpdate: function(){

              // Access ISO String and formatted values from the DOM.

              var hiddenInputElement = document.getElementById("example-datepicker");

              console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

              console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

            },

            render: function(){

              return <FormGroup>

                <ControlLabel>Label</ControlLabel>

                <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

                <HelpBlock>Help</HelpBlock>

              </FormGroup>;

            }

          });

           

          82 - Chuỗi đại diện cho giá trị được định dạng như được xác định bởi thuộc tính

          var DatePicker = require("react-bootstrap-date-picker");

           

          var App = React.createClass({

            getInitialState: function(){

              var value = new Date().toISOString();

              return {

                value: value

              }

            },

            handleChange: function(value, formattedValue) {

              this.setState({

                value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

                formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

              });

            },

            componentDidUpdate: function(){

              // Access ISO String and formatted values from the DOM.

              var hiddenInputElement = document.getElementById("example-datepicker");

              console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

              console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

            },

            render: function(){

              return <FormGroup>

                <ControlLabel>Label</ControlLabel>

                <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

                <HelpBlock>Help</HelpBlock>

              </FormGroup>;

            }

          });

           

          83
          • Loại.

            var DatePicker = require("react-bootstrap-date-picker");

             

            var App = React.createClass({

              getInitialState: function(){

                var value = new Date().toISOString();

                return {

                  value: value

                }

              },

              handleChange: function(value, formattedValue) {

                this.setState({

                  value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

                  formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

                });

              },

              componentDidUpdate: function(){

                // Access ISO String and formatted values from the DOM.

                var hiddenInputElement = document.getElementById("example-datepicker");

                console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

                console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

              },

              render: function(){

                return <FormGroup>

                  <ControlLabel>Label</ControlLabel>

                  <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

                  <HelpBlock>Help</HelpBlock>

                </FormGroup>;

              }

            });

             

            80
          • Ví dụ.

            var DatePicker = require("react-bootstrap-date-picker");

             

            var App = React.createClass({

              getInitialState: function(){

                var value = new Date().toISOString();

                return {

                  value: value

                }

              },

              handleChange: function(value, formattedValue) {

                this.setState({

                  value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

                  formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

                });

              },

              componentDidUpdate: function(){

                // Access ISO String and formatted values from the DOM.

                var hiddenInputElement = document.getElementById("example-datepicker");

                console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

                console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

              },

              render: function(){

                return <FormGroup>

                  <ControlLabel>Label</ControlLabel>

                  <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

                  <HelpBlock>Help</HelpBlock>

                </FormGroup>;

              }

            });

             

            85
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      86 - Chức năng gọi lại tập trung
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        48
      • Đối số gọi lại
        • var DatePicker = require("react-bootstrap-date-picker");

           

          var App = React.createClass({

            getInitialState: function(){

              var value = new Date().toISOString();

              return {

                value: value

              }

            },

            handleChange: function(value, formattedValue) {

              this.setState({

                value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

                formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

              });

            },

            componentDidUpdate: function(){

              // Access ISO String and formatted values from the DOM.

              var hiddenInputElement = document.getElementById("example-datepicker");

              console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

              console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

            },

            render: function(){

              return <FormGroup>

                <ControlLabel>Label</ControlLabel>

                <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

                <HelpBlock>Help</HelpBlock>

              </FormGroup>;

            }

          });

           

          88 - Sự kiện tiêu điểm
          • Loại.

            var DatePicker = require("react-bootstrap-date-picker");

             

            var App = React.createClass({

              getInitialState: function(){

                var value = new Date().toISOString();

                return {

                  value: value

                }

              },

              handleChange: function(value, formattedValue) {

                this.setState({

                  value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

                  formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

                });

              },

              componentDidUpdate: function(){

                // Access ISO String and formatted values from the DOM.

                var hiddenInputElement = document.getElementById("example-datepicker");

                console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

                console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

              },

              render: function(){

                return <FormGroup>

                  <ControlLabel>Label</ControlLabel>

                  <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

                  <HelpBlock>Help</HelpBlock>

                </FormGroup>;

              }

            });

             

            89
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      90 - Chức năng gọi lại làm mờ
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        48
      • Đối số gọi lại
        • var DatePicker = require("react-bootstrap-date-picker");

           

          var App = React.createClass({

            getInitialState: function(){

              var value = new Date().toISOString();

              return {

                value: value

              }

            },

            handleChange: function(value, formattedValue) {

              this.setState({

                value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

                formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

              });

            },

            componentDidUpdate: function(){

              // Access ISO String and formatted values from the DOM.

              var hiddenInputElement = document.getElementById("example-datepicker");

              console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

              console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

            },

            render: function(){

              return <FormGroup>

                <ControlLabel>Label</ControlLabel>

                <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

                <HelpBlock>Help</HelpBlock>

              </FormGroup>;

            }

          });

           

          88 - Sự kiện mờ
          • Loại.

            var DatePicker = require("react-bootstrap-date-picker");

             

            var App = React.createClass({

              getInitialState: function(){

                var value = new Date().toISOString();

                return {

                  value: value

                }

              },

              handleChange: function(value, formattedValue) {

                this.setState({

                  value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

                  formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

                });

              },

              componentDidUpdate: function(){

                // Access ISO String and formatted values from the DOM.

                var hiddenInputElement = document.getElementById("example-datepicker");

                console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

                console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

              },

              render: function(){

                return <FormGroup>

                  <ControlLabel>Label</ControlLabel>

                  <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

                  <HelpBlock>Help</HelpBlock>

                </FormGroup>;

              }

            });

             

            89
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      83 - Định dạng ngày tháng. Bất kỳ sự kết hợp nào giữa DD, MM, YYYY và dấu phân cách
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        2
      • ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        96,

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        97,

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        98, hoặc

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        99
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      80 - Ký tự hoặc thành phần để sử dụng cho nút xóa
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        2 hoặc

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        82
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        83
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      84 - Chuyển chế độ hiển thị của ClearButton
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        42
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        43
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      87 - Xác định điều gì sẽ xảy ra khi nhấp vào nút xóa
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        48
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      89 - Ký tự hoặc thành phần để sử dụng cho nút trước đó của lịch
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        2 hoặc

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        82
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        12
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      13 - Ký tự hoặc thành phần để sử dụng cho nút tiếp theo của lịch
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        2 hoặc

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        82
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        16
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      17 - Giá trị đệm CSS cho các ô ngày theo lịch
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        2
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        19
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      20 - Mảng tên ngày để sử dụng trong lịch. bắt đầu từ chủ nhật
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        21
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        22
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      23 - Mảng tên tháng để sử dụng trong lịch
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        21
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        25
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      26 - Vị trí lớp phủ cho lịch bật lên
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        2 hoặc

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        48
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        29
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      30 - Vùng chứa lớp phủ cho lịch bật lên. Khi đặt công cụ chọn ngày trong vùng chứa cuộn, hãy đặt giá đỡ này thành tổ tiên nào đó của vùng chứa cuộn
      • Không bắt buộc
      • Loại. Một phần tử DOM hoặc một thành phần
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        31
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      32 - Sử dụng LỖI THỜI

      var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      33
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      33 - Làm cho tuần của lịch bắt đầu vào một ngày cụ thể. 0 = Chủ Nhật, 1 = Thứ Hai, v.v.
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        35
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        36
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      37 - Chuyển chế độ hiển thị của nút hôm nay
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        38
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        43
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      00 - Nhãn cho nút hôm nay
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        2
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        02
    • var DatePicker = require("react-bootstrap-date-picker");

       

      var App = React.createClass({

        getInitialState: function(){

          var value = new Date().toISOString();

          return {

            value: value

          }

        },

        handleChange: function(value, formattedValue) {

          this.setState({

            value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

            formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

          });

        },

        componentDidUpdate: function(){

          // Access ISO String and formatted values from the DOM.

          var hiddenInputElement = document.getElementById("example-datepicker");

          console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

          console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

        },

        render: function(){

          return <FormGroup>

            <ControlLabel>Label</ControlLabel>

            <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

            <HelpBlock>Help</HelpBlock>

          </FormGroup>;

        }

      });

       

      03 - Ghi đè thành phần

       

      npm test

       

      0 mặc định bằng thành phần của riêng bạn
      • Không bắt buộc
      • Loại.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        05
      • Ví dụ.

        var DatePicker = require("react-bootstrap-date-picker");

         

        var App = React.createClass({

          getInitialState: function(){

            var value = new Date().toISOString();

            return {

              value: value

            }

          },

          handleChange: function(value, formattedValue) {

            this.setState({

              value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

              formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

            });

          },

          componentDidUpdate: function(){

            // Access ISO String and formatted values from the DOM.

            var hiddenInputElement = document.getElementById("example-datepicker");

            console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

            console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

          },

          render: function(){

            return <FormGroup>

              <ControlLabel>Label</ControlLabel>

              <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

              <HelpBlock>Help</HelpBlock>

            </FormGroup>;

          }

        });

         

        06
  • phương pháp

bài kiểm tra

Bảo hiểm trình duyệt

Kiểm tra Karma được thực hiện trên Browserstack trong các trình duyệt sau

  • TỨC LÀ 9, Windows 7
  • TỨC LÀ 10, Windows 7
  • TỨC LÀ 11, Windows 7
  • Opera (phiên bản mới nhất), Windows 7
  • Firefox (phiên bản mới nhất), Windows 7
  • Chrome (phiên bản mới nhất), Windows 7
  • Safari (phiên bản mới nhất), OSX Yosemite
  • Mobile Safari (phiên bản mới nhất), iPhone 6, iOS 8. 3

Vui lòng cho chúng tôi biết nếu một cấu hình khác nên được đưa vào đây

Chạy thử nghiệm

tại địa phương

 

npm test

 

Trên trình duyệt

var DatePicker = require("react-bootstrap-date-picker");

 

var App = React.createClass({

  getInitialState: function(){

    var value = new Date().toISOString();

    return {

      value: value

    }

  },

  handleChange: function(value, formattedValue) {

    this.setState({

      value: value, // ISO String, ex: "2016-11-19T12:00:00.000Z"

      formattedValue: formattedValue // Formatted String, ex: "11/19/2016"

    });

  },

  componentDidUpdate: function(){

    // Access ISO String and formatted values from the DOM.

    var hiddenInputElement = document.getElementById("example-datepicker");

    console.log(hiddenInputElement.value); // ISO String, ex: "2016-11-19T12:00:00.000Z"

    console.log(hiddenInputElement.getAttribute('data-formattedvalue')) // Formatted String, ex: "11/19/2016"

  },

  render: function(){

    return <FormGroup>

      <ControlLabel>Label</ControlLabel>

      <DatePicker id="example-datepicker" value={this.state.value} onChange={this.handleChange} />

      <HelpBlock>Help</HelpBlock>

    </FormGroup>;

  }

});

 

4