Skip to content

Commit ffee843

Browse files
samhere06mohas22
andauthored
Fix to avoid error in overrided datetime (#306)
Co-authored-by: mohas22 <[email protected]>
1 parent 620b992 commit ffee843

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/angular-sdk-components/src/lib/_components/field/date-time/date-time.component.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,7 @@ export class DateTimeComponent implements OnInit, OnDestroy {
199199
if (typeof event.value === 'object') {
200200
// convert date to pega "date" format
201201
const dateTime = dayjs(event.value?.toISOString());
202-
const timeZoneDateTime = dayjs.tz(dateTime.format('YYYY-MM-DDTHH:mm:ss'), this.timezone);
202+
const timeZoneDateTime = (dayjs as any).tz(dateTime.format('YYYY-MM-DDTHH:mm:ss'), this.timezone);
203203
event.value = timeZoneDateTime && timeZoneDateTime.isValid() ? timeZoneDateTime.toISOString() : '';
204204
}
205205
handleEvent(this.actionsApi, 'changeNblur', this.propName, event.value);

0 commit comments

Comments
 (0)