parent
21c5ce25f2
commit
e2cf8b34d0
@ -0,0 +1,9 @@
|
|||||||
|
package com.flagg10ma.taf.dto;
|
||||||
|
|
||||||
|
import java.util.Collection;
|
||||||
|
|
||||||
|
public record CompleteEventDto(
|
||||||
|
EventDto event,
|
||||||
|
Collection<LabelDto> labels
|
||||||
|
) {
|
||||||
|
}
|
@ -0,0 +1,26 @@
|
|||||||
|
package com.flagg10ma.taf.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
|
||||||
|
import java.time.LocalDate;
|
||||||
|
import java.util.Collection;
|
||||||
|
|
||||||
|
public record EventDto(
|
||||||
|
@JsonProperty("event_id") String id,
|
||||||
|
String title,
|
||||||
|
String description,
|
||||||
|
|
||||||
|
@JsonProperty("start_date")
|
||||||
|
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "dd/MM/yyyy")
|
||||||
|
LocalDate startDate,
|
||||||
|
|
||||||
|
@JsonProperty("end_date")
|
||||||
|
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "dd/MM/yyyy")
|
||||||
|
LocalDate endDate,
|
||||||
|
|
||||||
|
@JsonProperty("color_code") String color,
|
||||||
|
@JsonProperty("task_count") int taskCount,
|
||||||
|
Collection<EventTaskDto> tasks
|
||||||
|
) {
|
||||||
|
}
|
@ -0,0 +1,9 @@
|
|||||||
|
package com.flagg10ma.taf.dto;
|
||||||
|
|
||||||
|
import java.util.Collection;
|
||||||
|
|
||||||
|
public record EventListDto(
|
||||||
|
Collection<EventDto> events,
|
||||||
|
Collection<LabelDto> labels
|
||||||
|
) {
|
||||||
|
}
|
@ -0,0 +1,23 @@
|
|||||||
|
package com.flagg10ma.taf.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
|
||||||
|
import java.time.LocalDate;
|
||||||
|
import java.util.Collection;
|
||||||
|
|
||||||
|
public record EventTaskDto(
|
||||||
|
@JsonProperty("task_id") String id,
|
||||||
|
String title,
|
||||||
|
String description,
|
||||||
|
boolean delayed,
|
||||||
|
|
||||||
|
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "dd/MM/yyyy")
|
||||||
|
@JsonProperty("date_assigned") LocalDate assignedDate,
|
||||||
|
|
||||||
|
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "dd/MM/yyyy")
|
||||||
|
@JsonProperty("date_completed") LocalDate completionDate,
|
||||||
|
|
||||||
|
@JsonProperty("label_ids") Collection<String> labels
|
||||||
|
) {
|
||||||
|
}
|
@ -0,0 +1,24 @@
|
|||||||
|
package com.flagg10ma.taf.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
|
||||||
|
import java.time.LocalDate;
|
||||||
|
import java.util.Collection;
|
||||||
|
|
||||||
|
public record SimplifiedTaskDto(
|
||||||
|
@JsonProperty("task_id") String id,
|
||||||
|
String title,
|
||||||
|
String description,
|
||||||
|
boolean delayed,
|
||||||
|
|
||||||
|
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "dd/MM/yyyy")
|
||||||
|
@JsonProperty("date_assigned") LocalDate assignedDate,
|
||||||
|
|
||||||
|
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "dd/MM/yyyy")
|
||||||
|
@JsonProperty("date_completed") LocalDate completionDate,
|
||||||
|
|
||||||
|
@JsonProperty("event_id") String event,
|
||||||
|
@JsonProperty("label_ids") Collection<String> labels
|
||||||
|
) {
|
||||||
|
}
|
@ -0,0 +1,24 @@
|
|||||||
|
package com.flagg10ma.taf.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
|
||||||
|
import java.time.LocalDate;
|
||||||
|
import java.util.Collection;
|
||||||
|
|
||||||
|
public record TaskDto(
|
||||||
|
@JsonProperty("task_id") String id,
|
||||||
|
String title,
|
||||||
|
String description,
|
||||||
|
boolean delayed,
|
||||||
|
|
||||||
|
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "dd/MM/yyyy")
|
||||||
|
@JsonProperty("date_assigned") LocalDate assignedDate,
|
||||||
|
|
||||||
|
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "dd/MM/yyyy")
|
||||||
|
@JsonProperty("date_completed") LocalDate completionDate,
|
||||||
|
|
||||||
|
SimplifiedEventDto event,
|
||||||
|
@JsonProperty("label_ids") Collection<String> labels
|
||||||
|
) {
|
||||||
|
}
|
@ -0,0 +1,10 @@
|
|||||||
|
package com.flagg10ma.taf.dto;
|
||||||
|
|
||||||
|
import java.util.Collection;
|
||||||
|
|
||||||
|
public record TaskListDto(
|
||||||
|
Collection<SimplifiedTaskDto> tasks,
|
||||||
|
Collection<SimplifiedEventDto> events,
|
||||||
|
Collection<LabelDto> labels
|
||||||
|
) {
|
||||||
|
}
|
Loading…
Reference in new issue