bug solve

This commit is contained in:
Eudes Inácio
2024-06-04 10:21:40 +01:00
13 changed files with 100 additions and 33 deletions
@@ -1,5 +1,15 @@
import { EventOutputDTO } from "../model/eventDTOOutput"
function getTextInsideParentheses(inputString) {
var startIndex = inputString.indexOf('(');
var endIndex = inputString.indexOf(')');
if (startIndex !== -1 && endIndex !== -1) {
return inputString.substring(startIndex + 1, endIndex);
} else {
return null;
}
}
export class EventMapper {
constructor() {}
@@ -36,7 +46,7 @@ export class EventMapper {
"IsRecurring": dto.isRecurring,
"IsAllDayEvent": dto.isAllDayEvent,
"AppointmentState": 1,
"TimeZone": "UTC",
"TimeZone": getTextInsideParentheses(new Date(dto.startDate)+ ''),
"Organizer": {
"Id": dto.organizer.wxUserId,
"EmailAddress": dto.organizer.wxeMail,