Unverified Commit 7420c35a authored by Jérémie Bresson's avatar Jérémie Bresson Committed by GitHub
Browse files

Fix Milestone class (#1060)

parent f2fe6932
......@@ -4,11 +4,15 @@ import java.util.Date;
import org.gitlab4j.api.utils.JacksonJson;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
public class Milestone {
private Date createdAt;
private String description;
@JsonSerialize(using = JacksonJson.DateOnlySerializer.class)
private Date startDate;
@JsonSerialize(using = JacksonJson.DateOnlySerializer.class)
private Date dueDate;
private Long id;
private Long iid;
......@@ -17,6 +21,8 @@ public class Milestone {
private String state;
private String title;
private Date updatedAt;
private Boolean expired;
private String webUrl;
public Date getCreatedAt() {
return this.createdAt;
......@@ -106,6 +112,22 @@ public class Milestone {
this.updatedAt = updatedAt;
}
public Boolean getExpired() {
return expired;
}
public void setExpired(Boolean expired) {
this.expired = expired;
}
public String getWebUrl() {
return webUrl;
}
public void setWebUrl(String webUrl) {
this.webUrl = webUrl;
}
@Override
public String toString() {
return (JacksonJson.toJsonString(this));
......
......@@ -4,8 +4,8 @@
"group_id":14,
"title":"10.0",
"description":"Version",
"start_date":"2013-11-01T00:00:00Z",
"due_date":"2013-11-29T00:00:00Z",
"start_date":"2013-11-01",
"due_date":"2013-11-29",
"state":"active",
"updated_at":"2013-10-02T09:24:18Z",
"created_at":"2013-10-02T09:24:18Z"
......
{
"id":12,
"iid":3,
"project_id":16,
"title":"10.0",
"description":"Version",
"start_date":"2013-11-01T00:00:00Z",
"due_date":"2013-11-29T00:00:00Z",
"state":"active",
"updated_at":"2013-10-02T09:24:18Z",
"created_at":"2013-10-02T09:24:18Z"
"id": 12,
"iid": 3,
"project_id": 16,
"title": "1.0",
"description": "Version",
"state": "active",
"created_at": "2013-10-02T09:24:18Z",
"updated_at": "2013-10-02T09:24:18Z",
"due_date": "2013-11-29",
"start_date": "2013-11-01",
"expired": false,
"web_url": "http://gitlab.example.com/my-group/my-project/-/milestones/3"
}
......@@ -40,8 +40,8 @@
"state":"closed",
"created_at":"2019-07-12T19:45:44.256Z",
"updated_at":"2019-07-12T19:45:44.256Z",
"due_date":"2019-08-16T11:00:00.256Z",
"start_date":"2019-07-30T12:00:00.256Z"
"due_date":"2019-08-16",
"start_date":"2019-07-30"
},
{
"id":52,
......@@ -52,8 +52,8 @@
"state":"closed",
"created_at":"2019-07-16T14:00:12.256Z",
"updated_at":"2019-07-16T14:00:12.256Z",
"due_date":"2019-08-16T11:00:00.256Z",
"start_date":"2019-07-30T12:00:00.256Z"
"due_date":"2019-08-16",
"start_date":"2019-07-30"
}
],
"commit_path":"/root/awesome-app/commit/588440f66559714280628a4f9799f0c4eb880a4a",
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment