Skip to content

Commit

Permalink
fix pikaday
Browse files Browse the repository at this point in the history
  • Loading branch information
icebob committed Feb 14, 2017
1 parent 3e05e14 commit e7589b3
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion dev/full/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
<script type="text/javascript" src="https://rawgit.com/nosir/cleave.js/master/dist/cleave.min.js"></script>
<script type="text/javascript" src="https://nosir.github.io/cleave.js/lib/cleave-phone.i18n.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/noUiSlider/9.0.0/nouislider.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/pikaday/1.4.0/pikaday.min.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/pikaday/1.5.1/pikaday.min.js"></script>
<script type="text/javascript" src="https://maps.googleapis.com/maps/api/js?key=AIzaSyCEz-sX9bRJorDS-D_JL0JkZVZe2gzoUMw&amp;libraries=places"></script>

</head>
Expand Down
2 changes: 1 addition & 1 deletion dev/full/schema.js
Original file line number Diff line number Diff line change
Expand Up @@ -536,7 +536,7 @@ module.exports = {
required: true,
placeholder: "User's birth of date",
min: moment("1900-01-01").toDate(),
max: moment("2016-01-01").toDate(),
max: moment("2018-01-01").toDate(),
validator: [
validators.date
],
Expand Down
3 changes: 3 additions & 0 deletions src/fields/fieldPikaday.vue
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,9 @@
if (window.Pikaday){
this.picker = new window.Pikaday(defaults(this.schema.pikadayOptions || {}, {
field: this.$el, // bind the datepicker to a form field
onSelect: () => {
this.value = this.picker.toString();
}
// trigger: , // use a different element to trigger opening the datepicker, see [trigger example][] (default to `field`)
}));
} else {
Expand Down

0 comments on commit e7589b3

Please sign in to comment.