From 31ce2c6cd39a81338174a3251e4395eb0dcec5f9 Mon Sep 17 00:00:00 2001 From: upagge Date: Mon, 2 Mar 2020 13:11:07 +0300 Subject: [PATCH] =?UTF-8?q?=D0=94=D0=BE=D0=B1=D0=B0=D0=B2=D0=B8=D0=BB=20?= =?UTF-8?q?=D0=B2=D0=B5=D1=80=D1=81=D0=B8=D1=8E=20pr?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../domain/entity/PullRequest.java | 19 +++---------------- .../converter/PullRequestJsonConverter.java | 1 + src/main/resources/liquibase/change-log.xml | 1 + .../resources/liquibase/change-set/v1.2.0.xml | 12 ++++++++++++ 4 files changed, 17 insertions(+), 16 deletions(-) create mode 100644 src/main/resources/liquibase/change-set/v1.2.0.xml diff --git a/src/main/java/com/tsc/bitbucketbot/domain/entity/PullRequest.java b/src/main/java/com/tsc/bitbucketbot/domain/entity/PullRequest.java index 0ae7852..613f01d 100644 --- a/src/main/java/com/tsc/bitbucketbot/domain/entity/PullRequest.java +++ b/src/main/java/com/tsc/bitbucketbot/domain/entity/PullRequest.java @@ -49,6 +49,9 @@ public class PullRequest { @Column(name = "repository_id") private Long repositoryId; + @Column(name = "version") + private Integer version; + @ManyToOne @JoinColumn(name = "author_login") private User author; @@ -67,20 +70,4 @@ public class PullRequest { @Column(name = "status") private PullRequestStatus status; -// public void setReviewers(List reviewers) { -// this.reviewers = reviewers; -// this.reviewers.forEach(reviewer -> reviewer.setPullRequest(this)); -// } -// -// public PullRequest(Long bitbucketId, Long repositoryId, User author, List reviewers, String url, String name, PullRequestStatus status) { -// this.bitbucketId = bitbucketId; -// this.repositoryId = repositoryId; -// this.author = author; -// this.reviewers = reviewers; -// this.url = url; -// this.name = name; -// this.status = status; -// this.reviewers.forEach(reviewer -> reviewer.setPullRequest(this)); -// } - } diff --git a/src/main/java/com/tsc/bitbucketbot/service/converter/PullRequestJsonConverter.java b/src/main/java/com/tsc/bitbucketbot/service/converter/PullRequestJsonConverter.java index 9f680c6..19f9bea 100644 --- a/src/main/java/com/tsc/bitbucketbot/service/converter/PullRequestJsonConverter.java +++ b/src/main/java/com/tsc/bitbucketbot/service/converter/PullRequestJsonConverter.java @@ -34,6 +34,7 @@ public class PullRequestJsonConverter implements Converter + \ No newline at end of file diff --git a/src/main/resources/liquibase/change-set/v1.2.0.xml b/src/main/resources/liquibase/change-set/v1.2.0.xml new file mode 100644 index 0000000..84e6784 --- /dev/null +++ b/src/main/resources/liquibase/change-set/v1.2.0.xml @@ -0,0 +1,12 @@ + + + + + + + + + \ No newline at end of file