MCPcopy Create free account
hub / github.com/UI5/webcomponents / getSelectedDateTime

Method getSelectedDateTime

packages/main/src/DateTimePicker.ts:444–454  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

442 }
443
444 getSelectedDateTime() {
445 const selectedDate = this.getValueFormat().parse(this._calendarSelectedDates[0]) as Date;
446 const selectedTime = this.getValueFormat().parse(this._timeSelectionValue) as Date;
447 if (selectedTime) {
448 selectedDate.setHours(selectedTime.getHours());
449 selectedDate.setMinutes(selectedTime.getMinutes());
450 selectedDate.setSeconds(selectedTime.getSeconds());
451 }
452
453 return selectedDate;
454 }
455
456 getFormat() {
457 return this._isPattern

Callers 1

_submitClickMethod · 0.95

Calls 2

getValueFormatMethod · 0.95
parseMethod · 0.45

Tested by

no test coverage detected