From a997f5fffa12875c4cc6ef87e79da1009749743c Mon Sep 17 00:00:00 2001
From: Anton Romanov
Date: Sun, 3 Feb 2019 14:54:02 +0000
Subject: [PATCH 1/6] Update README.md
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index b324350..ca4db83 100644
--- a/README.md
+++ b/README.md
@@ -8,6 +8,6 @@
3. Получить платформу для обкатки научных проектов магистрантов по созданию интеллектуальны систем.
4. Получить проект для обучения бакалавров современым технологиям разработки.
-[Демо версия доступна здесь](https://193.110.3.124:8080)
+[Демо версия доступна здесь](http://193.110.3.124:8080)
[Для разворачивания проекта и ведения разработки ознакомьтесь с wiki](https://gitlab.com/romanov73/ng-tracker/wikis/home)
\ No newline at end of file
From 39c25c7b203c6b8500d852ee3b08c06a5320969b Mon Sep 17 00:00:00 2001
From: Anton Romanov
Date: Fri, 1 Mar 2019 11:21:25 +0400
Subject: [PATCH 2/6] add links to papers
---
.../resources/mail_templates/paperDeadlineNotification.html | 2 +-
src/main/resources/mail_templates/paperFailedNotification.html | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/main/resources/mail_templates/paperDeadlineNotification.html b/src/main/resources/mail_templates/paperDeadlineNotification.html
index f81e904..fb5ff32 100644
--- a/src/main/resources/mail_templates/paperDeadlineNotification.html
+++ b/src/main/resources/mail_templates/paperDeadlineNotification.html
@@ -10,7 +10,7 @@
Уважаемый(ая) Ivan Ivanov
- Приближается дедлайн статьи "Title".
+ Приближается дедлайн статьи "Title".
Срок исполнения: .
diff --git a/src/main/resources/mail_templates/paperFailedNotification.html b/src/main/resources/mail_templates/paperFailedNotification.html
index 3eb1399..e17ee38 100644
--- a/src/main/resources/mail_templates/paperFailedNotification.html
+++ b/src/main/resources/mail_templates/paperFailedNotification.html
@@ -10,7 +10,7 @@
Уважаемый(ая) Ivan Ivanov
- Статья "Title" провалена.
+ Статья "Title" провалена.
Предыдущий статус - "oldStatus".
From 0fccbdc97357eb10f79d01fd7c9c021d4c95ddeb Mon Sep 17 00:00:00 2001
From: Anton Romanov
Date: Fri, 1 Mar 2019 11:22:25 +0400
Subject: [PATCH 3/6] add links to papers
---
.../resources/mail_templates/paperStatusChangeNotification.html | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/main/resources/mail_templates/paperStatusChangeNotification.html b/src/main/resources/mail_templates/paperStatusChangeNotification.html
index 853458d..db58347 100644
--- a/src/main/resources/mail_templates/paperStatusChangeNotification.html
+++ b/src/main/resources/mail_templates/paperStatusChangeNotification.html
@@ -10,7 +10,7 @@
Уважаемый(ая) Ivan Ivanov
- Статус статьи "Title" сменился с
+ Статус статьи "Title" сменился с
"oldStatus" на "newStatus".
From 3d8e8ca4f2dc99a51d093182c05e64f641cac9d9 Mon Sep 17 00:00:00 2001
From: Anton Romanov
Date: Fri, 1 Mar 2019 11:27:57 +0400
Subject: [PATCH 4/6] fix branch
---
.gitlab-ci.yml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 8d76138..c3ff3e3 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -31,7 +31,7 @@ deploy:
script:
- sh deploy/gdccloud/deploy.sh
only:
- - master
+ - dev
cache:
key: "$CI_PROJECT_ID"
policy: pull
From e2c12d9fb2757ff17bb8d5db85b598405393dc66 Mon Sep 17 00:00:00 2001
From: Anton Romanov
Date: Mon, 4 Mar 2019 10:24:30 +0400
Subject: [PATCH 5/6] fix code
---
.../java/ru/ulstu/grant/model/GrantDto.java | 20 +++++++++++++------
1 file changed, 14 insertions(+), 6 deletions(-)
diff --git a/src/main/java/ru/ulstu/grant/model/GrantDto.java b/src/main/java/ru/ulstu/grant/model/GrantDto.java
index 0f1850a..e56896a 100644
--- a/src/main/java/ru/ulstu/grant/model/GrantDto.java
+++ b/src/main/java/ru/ulstu/grant/model/GrantDto.java
@@ -4,7 +4,6 @@ import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonProperty;
import org.hibernate.validator.constraints.NotEmpty;
import ru.ulstu.deadline.model.DeadlineDto;
-import ru.ulstu.grant.model.Grant;
import ru.ulstu.project.model.ProjectDto;
import java.util.ArrayList;
@@ -56,13 +55,17 @@ public class GrantDto {
return id;
}
- public void setId(Integer id) {this.id = id;}
+ public void setId(Integer id) {
+ this.id = id;
+ }
public String getTitle() {
return title;
}
- public void setTitle(String title) {this.title = title;}
+ public void setTitle(String title) {
+ this.title = title;
+ }
public Grant.GrantStatus getStatus() {
return status;
@@ -84,18 +87,23 @@ public class GrantDto {
return comment;
}
- public void setComment(String comment) {this.comment = comment;}
+ public void setComment(String comment) {
+ this.comment = comment;
+ }
public ProjectDto getProject() {
return project;
}
- public void setProject(ProjectDto project) {this.project = project;}
+ public void setProject(ProjectDto project) {
+ this.project = project;
+ }
public String getApplicationFileName() {
return applicationFileName;
}
public void setApplicationFileName(String applicationFileName) {
- this.applicationFileName = applicationFileName;}
+ this.applicationFileName = applicationFileName;
+ }
}
From 4f47b1beb6b1627c396593a1bde9bc4322b46ca7 Mon Sep 17 00:00:00 2001
From: Anton Romanov
Date: Mon, 4 Mar 2019 10:28:46 +0400
Subject: [PATCH 6/6] fix code
---
.../ru/ulstu/grant/service/GrantService.java | 4 +--
.../paper/controller/PaperController.java | 4 +--
.../paper/controller/PaperRestController.java | 2 +-
.../ru/ulstu/project/model/ProjectDto.java | 25 ++++++++++---------
4 files changed, 18 insertions(+), 17 deletions(-)
diff --git a/src/main/java/ru/ulstu/grant/service/GrantService.java b/src/main/java/ru/ulstu/grant/service/GrantService.java
index 31d0a04..d5beec3 100644
--- a/src/main/java/ru/ulstu/grant/service/GrantService.java
+++ b/src/main/java/ru/ulstu/grant/service/GrantService.java
@@ -107,11 +107,11 @@ public class GrantService {
}
@Transactional
- public Grant create(String title, Project project_id, Date deadlineDate) {
+ public Grant create(String title, Project projectId, Date deadlineDate) {
Grant grant = new Grant();
grant.setTitle(title);
grant.setComment("Комментарий к гранту 1");
- grant.setProject(project_id);
+ grant.setProject(projectId);
grant.setStatus(APPLICATION);
grant.getDeadlines().add(new Deadline(deadlineDate, "первый дедлайн"));
grant = grantRepository.save(grant);
diff --git a/src/main/java/ru/ulstu/paper/controller/PaperController.java b/src/main/java/ru/ulstu/paper/controller/PaperController.java
index 6f475bf..cb34a8a 100644
--- a/src/main/java/ru/ulstu/paper/controller/PaperController.java
+++ b/src/main/java/ru/ulstu/paper/controller/PaperController.java
@@ -65,7 +65,7 @@ public class PaperController {
public String save(@Valid PaperDto paperDto, Errors errors) throws IOException {
filterEmptyDeadlines(paperDto);
if (paperDto.getDeadlines().isEmpty()) {
- errors.rejectValue("deadlines", "errorCode","Не может быть пустым");
+ errors.rejectValue("deadlines", "errorCode", "Не может быть пустым");
}
if (errors.hasErrors()) {
return "/papers/paper";
@@ -103,7 +103,7 @@ public class PaperController {
@ModelAttribute("allYears")
public List getAllYears() {
List years = new ArrayList<>();
- for (int i = Calendar.getInstance().get(Calendar.YEAR); i > 2010; i-- ) {
+ for (int i = Calendar.getInstance().get(Calendar.YEAR); i > 2010; i--) {
years.add(i);
}
return years;
diff --git a/src/main/java/ru/ulstu/paper/controller/PaperRestController.java b/src/main/java/ru/ulstu/paper/controller/PaperRestController.java
index 66efcc7..5dd6b9f 100644
--- a/src/main/java/ru/ulstu/paper/controller/PaperRestController.java
+++ b/src/main/java/ru/ulstu/paper/controller/PaperRestController.java
@@ -37,7 +37,7 @@ public class PaperRestController {
}
@GetMapping("/{paper-id}")
- public Response getPaper(@PathVariable("paper-id") Integer paperId){
+ public Response getPaper(@PathVariable("paper-id") Integer paperId) {
return new Response(paperService.findById(paperId));
}
diff --git a/src/main/java/ru/ulstu/project/model/ProjectDto.java b/src/main/java/ru/ulstu/project/model/ProjectDto.java
index 7c2664e..fdce26b 100644
--- a/src/main/java/ru/ulstu/project/model/ProjectDto.java
+++ b/src/main/java/ru/ulstu/project/model/ProjectDto.java
@@ -4,7 +4,6 @@ import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonProperty;
import org.hibernate.validator.constraints.NotEmpty;
import ru.ulstu.deadline.model.DeadlineDto;
-import ru.ulstu.project.model.Project;
import java.util.ArrayList;
import java.util.List;
@@ -12,14 +11,15 @@ import java.util.List;
import static ru.ulstu.core.util.StreamApiUtils.convert;
public class ProjectDto {
- private Integer id;
+ private Integer id;
@NotEmpty
- private String title;
+ private String title;
- private List deadlines = new ArrayList<>();
+ private List deadlines = new ArrayList<>();
- public ProjectDto() {}
+ public ProjectDto() {
+ }
public ProjectDto(String title) {
this.title = title;
@@ -45,22 +45,23 @@ public class ProjectDto {
return id;
}
- public String getTitle() {
- return title;
- }
-
public void setId(Integer id) {
this.id = id;
}
+ public String getTitle() {
+ return title;
+ }
+
public void setTitle(String title) {
this.title = title;
}
- public void setDeadlines(List deadlines) {
- this.deadlines = deadlines;
- }
public List getDeadlines() {
return deadlines;
}
+
+ public void setDeadlines(List deadlines) {
+ this.deadlines = deadlines;
+ }
}