Skip to content

Commit 2c13128

Browse files
committed
feat: add onChange missing handler & id to date-time pickers
1 parent 25f1a18 commit 2c13128

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

app/components/widgets/forms/date-picker.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,9 @@ import Component from '@ember/component';
22
import { merge } from 'lodash-es';
33
import moment from 'moment';
44
import { FORM_DATE_FORMAT } from 'open-event-frontend/utils/dictionary/date-time';
5+
import FormMixin from 'open-event-frontend/mixins/form';
56

6-
export default Component.extend({
7+
export default Component.extend(FormMixin, {
78

89
classNames : ['ui', 'calendar', 'date', 'picker', 'input', 'fluid'],
910
classNameBindings : ['icon:left', 'icon'],
@@ -43,7 +44,7 @@ export default Component.extend({
4344
actions: {
4445
onChange() {
4546
if (this.onChange) {
46-
this.sendAction('onChange', this.value);
47+
this.sendAction('onChange');
4748
}
4849
}
4950
}
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{{#if icon}}
22
<i class="time icon"></i>
33
{{/if}}
4-
{{input type='text' value=value placeholder=placeholder name=name}}
4+
{{input type='text' value=value placeholder=placeholder name=name focus-out=(action 'onChange')}}

0 commit comments

Comments
 (0)