Commit 79ac2457fde182867a27522a1a1ae437bf5643b1
1 parent
b42322fe
Allow DatePicker to receive TimePicker options
Showing
4 changed files
with
12 additions
and
0 deletions
Show diff stats
src/components/date-picker/panel/Date/date-panel-mixin.js
@@ -32,6 +32,10 @@ export default { | @@ -32,6 +32,10 @@ export default { | ||
32 | type: Array, | 32 | type: Array, |
33 | default: () => [initTimeDate(), initTimeDate()] | 33 | default: () => [initTimeDate(), initTimeDate()] |
34 | }, | 34 | }, |
35 | + timePickerOptions: { | ||
36 | + default: () => ({}), | ||
37 | + type: Object, | ||
38 | + }, | ||
35 | showWeekNumbers: { | 39 | showWeekNumbers: { |
36 | type: Boolean, | 40 | type: Boolean, |
37 | default: false | 41 | default: false |
src/components/date-picker/panel/Date/date-range.vue
@@ -91,6 +91,7 @@ | @@ -91,6 +91,7 @@ | ||
91 | :value="dates" | 91 | :value="dates" |
92 | :format="format" | 92 | :format="format" |
93 | :time-disabled="timeDisabled" | 93 | :time-disabled="timeDisabled" |
94 | + v-bind="timePickerOptions" | ||
94 | @on-pick="handleRangePick" | 95 | @on-pick="handleRangePick" |
95 | @on-pick-click="handlePickClick" | 96 | @on-pick-click="handlePickClick" |
96 | @on-pick-clear="handlePickClear" | 97 | @on-pick-clear="handlePickClear" |
src/components/date-picker/panel/Date/date.vue
@@ -50,6 +50,7 @@ | @@ -50,6 +50,7 @@ | ||
50 | :value="dates" | 50 | :value="dates" |
51 | :format="format" | 51 | :format="format" |
52 | :time-disabled="timeDisabled" | 52 | :time-disabled="timeDisabled" |
53 | + v-bind="timePickerOptions" | ||
53 | @on-pick="handlePick" | 54 | @on-pick="handlePick" |
54 | @on-pick-click="handlePickClick" | 55 | @on-pick-click="handlePickClick" |
55 | @on-pick-clear="handlePickClear" | 56 | @on-pick-clear="handlePickClear" |
src/components/date-picker/picker.vue
@@ -48,6 +48,8 @@ | @@ -48,6 +48,8 @@ | ||
48 | :show-week-numbers="showWeekNumbers" | 48 | :show-week-numbers="showWeekNumbers" |
49 | :picker-type="type" | 49 | :picker-type="type" |
50 | 50 | ||
51 | + :time-picker-options="timePickerOptions" | ||
52 | + | ||
51 | v-bind="ownPickerProps" | 53 | v-bind="ownPickerProps" |
52 | 54 | ||
53 | @on-pick="onPick" | 55 | @on-pick="onPick" |
@@ -113,6 +115,10 @@ | @@ -113,6 +115,10 @@ | ||
113 | type: Boolean, | 115 | type: Boolean, |
114 | default: false | 116 | default: false |
115 | }, | 117 | }, |
118 | + timePickerOptions: { | ||
119 | + default: () => ({}), | ||
120 | + type: Object, | ||
121 | + }, | ||
116 | splitPanels: { | 122 | splitPanels: { |
117 | type: Boolean, | 123 | type: Boolean, |
118 | default: false | 124 | default: false |