Compare commits
8 Commits
master
...
SpringBoot
Author | SHA1 | Date |
---|---|---|
|
678fe95b3e | |
|
f618469463 | |
|
de67331baf | |
|
5257027643 | |
|
6139125e43 | |
|
76f0281ef9 | |
|
8bbcda241f | |
|
f0f607d1d5 |
|
@ -11,7 +11,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-common-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -52,7 +52,7 @@ INSERT INTO CLASSIFICATION VALUES('CLI:100000000000000000000000000000000005', 'L
|
|||
INSERT INTO CLASSIFICATION VALUES('CLI:100000000000000000000000000000000006', 'L110105' , 'CLI:100000000000000000000000000000000004', 'L11010' , 'EXTERNAL' , 'TASK' , 'DOMAIN_A', TRUE , RELATIVE_DATE(0) , RELATIVE_DATE(0) , 'Dynamik-Ausschluss' , 'Dynamik-Ausschluss' , 5 , 'P16D' , '' , 'VNR,RVNR,KOLVNR' , 'TEXT_2' , '' , '' , '' , '' , '' , '' );
|
||||
INSERT INTO CLASSIFICATION VALUES('CLI:100000000000000000000000000000000007', 'L110107' , 'CLI:100000000000000000000000000000000004', 'L11010' , 'EXTERNAL' , 'TASK' , 'DOMAIN_A', TRUE , RELATIVE_DATE(0) , RELATIVE_DATE(0) , 'Dynamik-Einschluss/Änd.' , 'Dynamik-Einschluss/Änd.' , 5 , 'P5D' , 'point0815' , 'VNR,RVNR,KOLVNR' , 'TEXT_1' , '' , '' , '' , '' , '' , '' );
|
||||
INSERT INTO CLASSIFICATION VALUES('CLI:100000000000000000000000000000000008', 'L12010' , '' , '' , 'EXTERNAL' , 'TASK' , 'DOMAIN_A', TRUE , RELATIVE_DATE(0) , RELATIVE_DATE(0) , 'Gewährung-Policendarlehen' , 'Gewährung-Policendarlehen' , 1 , 'P1D' , '' , 'VNR,RVNR,KOLVNR' , '' , '' , '' , '' , '' , '' , '' );
|
||||
INSERT INTO CLASSIFICATION VALUES('CLI:100000000000000000000000000000000009', 'L140101' , '' , '' , 'EXTERNAL' , 'TASK' , 'DOMAIN_A', TRUE , RELATIVE_DATE(0) , RELATIVE_DATE(0) , 'Zustimmungserklärung' , 'Zustimmungserklärung' , 2 , 'P2D' , '' , 'VNR' , '' , '' , '' , '' , '' , '' , '' );
|
||||
INSERT INTO CLASSIFICATION VALUES('CLI:100000000000000000000000000000000009', 'L140101' , '' , '' , 'EXTERNAL' , 'TASK' , 'DOMAIN_A', TRUE ,'2018-02-01 12:00:00','2018-02-01 12:00:00', 'Zustimmungserklärung' , 'Zustimmungserklärung' , 2 , 'P2D' , '' , 'VNR' , '' , '' , '' , '' , '' , '' , '' );
|
||||
INSERT INTO CLASSIFICATION VALUES('CLI:100000000000000000000000000000000010', 'T2100' , '' , '' , 'MANUAL' , 'TASK' , 'DOMAIN_A', TRUE , RELATIVE_DATE(0) , RELATIVE_DATE(0) , 'T-Vertragstermin VERA' , 'T-Vertragstermin VERA' , 2 , 'P2D' , '' , 'VNR' , 'cust2' , 'cust3' , 'cust4' , 'cust5' , 'cust6' , 'cust7' , 'cust8' );
|
||||
INSERT INTO CLASSIFICATION VALUES('CLI:100000000000000000000000000000000011', 'T6310' , '' , '' , 'AUTOMATIC' , 'TASK' , 'DOMAIN_A', TRUE , RELATIVE_DATE(0) , RELATIVE_DATE(0) , 'T-GUK Honorarrechnung erstellen', 'Unterstützungskasse Honorar wird fällig', 2 , 'P2D' , 'point0815' , 'VNR' , 'custom2' , 'custom3' , 'custom4' , 'custom5' , 'custom6' , 'custom7' , 'custom8' );
|
||||
INSERT INTO CLASSIFICATION VALUES('CLI:100000000000000000000000000000000013', 'DOCTYPE_DEFAULT', '' , '' , 'EXTERNAL' , 'DOCUMENT' , 'DOMAIN_A', TRUE , RELATIVE_DATE(0) , RELATIVE_DATE(0) , 'EP allgemein' , 'EP allgemein' , 99 , 'P2000D' , '' , 'VNR' , '' , '' , '' , '' , '' , '' , '' );
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
-- sample-data is used for rest tests and for the example application
|
||||
-- sample-data is used for rest tests and for the example application
|
||||
|
||||
-- TASK_COMMENT TABLE ( ID , TASK_ID , TEXTFIELD , CREATOR , CREATED , MODIFIED
|
||||
-- TaskComments for GetTaskCommentAccTest + UpdateTaskCommentAccTest
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
INSERT INTO TASK VALUES('TKI:000000000000000000000000000000000000', 'ETI:000000000000000000000000000000000000', RELATIVE_DATE(-1) , RELATIVE_DATE(0) , null , RELATIVE_DATE(0) , RELATIVE_DATE(0) , RELATIVE_DATE(-1) , RELATIVE_DATE(0) , 'Task99' , 'creator_user_id' , 'Lorem ipsum was n Quatsch dolor sit amet.', 'Some custom Note' , 1 , -1 , 'CLAIMED' , 'MANUAL' , 'T2000' , 'CLI:100000000000000000000000000000000016', 'WBI:100000000000000000000000000000000006' , 'USER-1-1' , 'DOMAIN_A', 'BPI21' , 'PBPI21' , 'user-1-1' , 'MyCompany1', 'MySystem1', 'MyInstance1' , 'MyType1', 'MyValue1' , true , false , null , 'NONE' , null , 'custom1' , 'custom2' , 'custom3' , 'custom4' , 'custom5' , 'custom6' , 'custom7' , 'custom8' , 'custom9' , 'custom10' , 'custom11' , 'custom12' , 'custom13' , 'abc' , 'custom15' , 'custom16' , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 );
|
||||
INSERT INTO TASK VALUES('TKI:000000000000000000000000000000000001', 'ETI:000000000000000000000000000000000001', RELATIVE_DATE(-2) , RELATIVE_DATE(0) , null , RELATIVE_DATE(0) , null , RELATIVE_DATE(-2) , RELATIVE_DATE(0) , 'Task01' , 'creator_user_id' , 'Lorem ipsum was n Quatsch dolor sit amet.', 'Some custom Note' , 2 , -1 , 'CLAIMED' , 'EXTERN' , 'L110102' , 'CLI:100000000000000000000000000000000005', 'WBI:100000000000000000000000000000000006' , 'USER-1-1' , 'DOMAIN_A', 'BPI21' , 'PBPI21' , 'user-1-1' , 'MyCompany1', 'MySystem1', 'MyInstance1' , 'MyType1', 'MyValue1' , true , false , null , 'NONE' , null , 'pqr' , null , null , null , null , null , null , null , null , null , null , null , null , 'abc' , null , null , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 );
|
||||
INSERT INTO TASK VALUES('TKI:000000000000000000000000000000000002', 'ETI:000000000000000000000000000000000002', RELATIVE_DATE(-2) , RELATIVE_DATE(0) , null , RELATIVE_DATE(0) , RELATIVE_DATE(0) , RELATIVE_DATE(-2) , RELATIVE_DATE(0) , 'Task02' , 'creator_user_id' , 'Lorem ipsum was n Quatsch t. Aber stimmt.', 'Some custom Note' , 2 , -1 , 'CLAIMED' , 'MANUAL' , 'T2000' , 'CLI:100000000000000000000000000000000016', 'WBI:100000000000000000000000000000000006' , 'USER-1-1' , 'DOMAIN_A', 'BPI21' , 'PBPI21' , 'user-1-1' , 'MyCompany1', 'MySystem1', 'MyInstance1' , 'MyType1', 'MyValue1' , true , false , null , 'NONE' , null , null , null , null , null , null , null , null , null , null , null , null , null , null , 'abc' , null , null , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 );
|
||||
INSERT INTO TASK VALUES('TKI:000000000000000000000000000000000003', 'ETI:000000000000000000000000000000000003', RELATIVE_DATE(-2) , null , null , RELATIVE_DATE(0) , RELATIVE_DATE(0) , RELATIVE_DATE(-2) , RELATIVE_DATE(0) , 'Widerruf' , 'creator_user_id' , 'Widerruf' , null , 2 , -1 , 'READY' , 'EXTERN' , 'L1050' , 'CLI:100000000000000000000000000000000003', 'WBI:100000000000000000000000000000000001' , 'GPK_KSC' , 'DOMAIN_A', 'PI_0000000000003' , 'DOC_0000000000000000003' , null , '00' , 'PASystem' , '00' , 'VNR' , '11223344' , false , false , null , 'NONE' , null , 'efg' , null , null , null , null , null , null , null , null , null , null , null , null , 'abc' , null , null , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 );
|
||||
INSERT INTO TASK VALUES('TKI:000000000000000000000000000000000003', 'ETI:000000000000000000000000000000000003','2018-02-01 12:00:00', null , null , '2018-02-01 12:00:00', RELATIVE_DATE(0) , RELATIVE_DATE(-2) , RELATIVE_DATE(0) , 'Widerruf' , 'creator_user_id' , 'Widerruf' , null , 2 , -1 , 'READY' , 'EXTERN' , 'L1050' , 'CLI:100000000000000000000000000000000003', 'WBI:100000000000000000000000000000000001' , 'GPK_KSC' , 'DOMAIN_A', 'PI_0000000000003' , 'DOC_0000000000000000003' , null , '00' , 'PASystem' , '00' , 'VNR' , '11223344' , false , false , null , 'NONE' , null , 'efg' , null , null , null , null , null , null , null , null , null , null , null , null , 'abc' , null , null , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 );
|
||||
INSERT INTO TASK VALUES('TKI:000000000000000000000000000000000004', 'ETI:000000000000000000000000000000000004', RELATIVE_DATE(-3) , null , null , RELATIVE_DATE(0) , RELATIVE_DATE(0) , RELATIVE_DATE(-3) , RELATIVE_DATE(0) , 'Widerruf' , 'creator_user_id' , 'Widerruf' , null , 2 , -1 , 'READY' , 'EXTERN' , 'L1050' , 'CLI:100000000000000000000000000000000003', 'WBI:100000000000000000000000000000000001' , 'GPK_KSC' , 'DOMAIN_A', 'PI_0000000000004' , 'DOC_0000000000000000004' , null , '00' , 'PASystem' , '00' , 'VNR' , '11223344' , false , false , null , 'NONE' , null , null , 'ade' , null , null , null , '074' , '' , null , null , null , null , null , null , 'abc' , null , null , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 );
|
||||
INSERT INTO TASK VALUES('TKI:000000000000000000000000000000000005', 'ETI:000000000000000000000000000000000005', RELATIVE_DATE(-4) , null , null , RELATIVE_DATE(0) , RELATIVE_DATE(-3) , RELATIVE_DATE(-4) , RELATIVE_DATE(0) , 'Widerruf' , 'creator_user_id' , 'Widerruf' , null , 2 , -1 , 'READY' , 'EXTERN' , 'L1050' , 'CLI:100000000000000000000000000000000003', 'WBI:100000000000000000000000000000000001' , 'GPK_KSC' , 'DOMAIN_A', 'PI_0000000000005' , 'DOC_0000000000000000005' , null , '00' , 'PASystem' , '00' , 'VNR' , '11223344' , false , false , null , 'NONE' , null , null , null , null , null , null , '074' , '' , null , null , null , null , null , null , 'abc' , null , null , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 );
|
||||
INSERT INTO TASK VALUES('TKI:000000000000000000000000000000000006', 'ETI:000000000000000000000000000000000006', RELATIVE_DATE(-5) , null , null , RELATIVE_DATE(0) , RELATIVE_DATE(-3) , RELATIVE_DATE(-5) , RELATIVE_DATE(0) , 'Widerruf' , 'creator_user_id' , 'Widerruf' , null , 2000 , -1 , 'READY' , 'EXTERN' , 'L1050' , 'CLI:100000000000000000000000000000000003', 'WBI:100000000000000000000000000000000001' , 'GPK_KSC' , 'DOMAIN_A', 'PI_0000000000006' , 'DOC_0000000000000000006' , null , '00' , 'PASystem' , '00' , 'VNR' , '11223344' , false , false , null , 'NONE' , null , null , null , null , null , null , '075' , '' , null , null , null , null , null , null , 'abc' , null , null , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 );
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-common-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<dependencies>
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-common-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<properties>
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-common-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-common-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<dependencies>
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana.history</groupId>
|
||||
<artifactId>taskana-history-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana.history</groupId>
|
||||
<artifactId>taskana-history-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana.history</groupId>
|
||||
<artifactId>taskana-history-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@ -132,12 +132,6 @@
|
|||
<artifactId>h2</artifactId>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>capital.scalable</groupId>
|
||||
<artifactId>spring-auto-restdocs-core</artifactId>
|
||||
<version>${version.auto-restdocs}</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-validation</artifactId>
|
||||
|
@ -147,28 +141,6 @@
|
|||
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<artifactId>maven-resources-plugin</artifactId>
|
||||
<version>${version.maven.resources}</version>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>copy-resources</id>
|
||||
<phase>validate</phase>
|
||||
<goals>
|
||||
<goal>copy-resources</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<outputDirectory>${basedir}/target/generated-javadoc-json</outputDirectory>
|
||||
<resources>
|
||||
<resource>
|
||||
<directory>../../rest/taskana-rest-spring/target/generated-javadoc-json
|
||||
</directory>
|
||||
</resource>
|
||||
</resources>
|
||||
</configuration>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-javadoc-plugin</artifactId>
|
||||
|
@ -182,61 +154,6 @@
|
|||
</tag>
|
||||
</tags>
|
||||
</configuration>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>generate-javadoc-json</id>
|
||||
<phase>validate</phase>
|
||||
<goals>
|
||||
<goal>javadoc-no-fork</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<doclet>capital.scalable.restdocs.jsondoclet.ExtractDocumentationAsJsonDoclet</doclet>
|
||||
<docletArtifact>
|
||||
<groupId>capital.scalable</groupId>
|
||||
<artifactId>spring-auto-restdocs-json-doclet-jdk9</artifactId>
|
||||
<version>${version.auto-restdocs}</version>
|
||||
</docletArtifact>
|
||||
<destDir>generated-javadoc-json</destDir>
|
||||
<reportOutputDirectory>${project.build.directory}</reportOutputDirectory>
|
||||
<useStandardDocletOptions>false</useStandardDocletOptions>
|
||||
<show>package</show>
|
||||
</configuration>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.asciidoctor</groupId>
|
||||
<artifactId>asciidoctor-maven-plugin</artifactId>
|
||||
<version>${version.maven.asciidoctor}</version>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>generate-docs</id>
|
||||
<phase>prepare-package</phase>
|
||||
<goals>
|
||||
<goal>process-asciidoc</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
<configuration>
|
||||
<backend>html5</backend>
|
||||
<doctype>book</doctype>
|
||||
<attributes>
|
||||
<snippets>${project.build.directory}/generated-snippets</snippets>
|
||||
<doctype>book</doctype>
|
||||
<icons>font</icons>
|
||||
<source-highlighter>highlightjs</source-highlighter>
|
||||
<toc>left</toc>
|
||||
<docinfo>shared</docinfo>
|
||||
<toclevels>4</toclevels>
|
||||
<sectlinks/>
|
||||
</attributes>
|
||||
<logHandler>
|
||||
<outputToConsole>false</outputToConsole>
|
||||
<failIf>
|
||||
<severity>ERROR</severity>
|
||||
</failIf>
|
||||
</logHandler>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
|
|
@ -99,7 +99,8 @@ public class TaskHistoryEventController {
|
|||
@GetMapping(path = HistoryRestEndpoints.URL_HISTORY_EVENTS_ID)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskHistoryEventRepresentationModel> getTaskHistoryEvent(
|
||||
@PathVariable String historyEventId) throws TaskanaHistoryEventNotFoundException {
|
||||
@PathVariable("historyEventId") String historyEventId)
|
||||
throws TaskanaHistoryEventNotFoundException {
|
||||
TaskHistoryEvent resultEvent = simpleHistoryService.getTaskHistoryEvent(historyEventId);
|
||||
|
||||
TaskHistoryEventRepresentationModel taskEventResource = assembler.toModel(resultEvent);
|
||||
|
|
|
@ -2,10 +2,12 @@ package pro.taskana.simplehistory.rest;
|
|||
|
||||
import static org.springframework.restdocs.mockmvc.RestDocumentationRequestBuilders.get;
|
||||
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.springframework.test.web.servlet.result.MockMvcResultMatchers;
|
||||
import pro.taskana.rest.test.BaseRestDocTest;
|
||||
|
||||
@Disabled
|
||||
class TaskHistoryEventControllerRestDocTest extends BaseRestDocTest {
|
||||
|
||||
@Test
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-lib-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -57,7 +57,7 @@ public class ExampleBootstrapTest {
|
|||
// Delete Taskana folder if exists
|
||||
Path taskanaH2Data = Path.of(System.getProperty("user.home"), "taskana-h2-data");
|
||||
if (Files.exists(taskanaH2Data)) {
|
||||
FileUtils.deleteDirectory(taskanaH2Data.toFile());
|
||||
FileUtils.forceDelete(taskanaH2Data.toFile());
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -89,7 +89,7 @@ public class ExampleBootstrapTest {
|
|||
"jdbc:h2:~/taskana-h2-data/testdb;NON_KEYWORDS=KEY,VALUE;AUTO_SERVER=TRUE;"
|
||||
+ "IGNORECASE=TRUE;LOCK_MODE=0",
|
||||
"sa",
|
||||
"");
|
||||
"sa");
|
||||
}
|
||||
|
||||
private int countTasksByName(String taskName) throws Exception {
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<defaultProtocol type="Servlet 6.0"/>
|
||||
<container qualifier="wildfly" default="true">
|
||||
<configuration>
|
||||
<property name="jbossHome">target/wildfly-27.0.1.Final</property>
|
||||
<property name="jbossHome">target/wildfly-31.0.1.Final</property>
|
||||
<property name="serverConfig">int-test-standalone.xml</property>
|
||||
<!-- <property name="javaVmArguments">-->
|
||||
<!-- -Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=y-->
|
||||
|
|
|
@ -36,7 +36,6 @@
|
|||
<extension module="org.wildfly.extension.metrics"/>
|
||||
<extension module="org.wildfly.extension.microprofile.config-smallrye"/>
|
||||
<extension module="org.wildfly.extension.microprofile.jwt-smallrye"/>
|
||||
<extension module="org.wildfly.extension.microprofile.opentracing-smallrye"/>
|
||||
<extension module="org.wildfly.extension.request-controller"/>
|
||||
<extension module="org.wildfly.extension.security.manager"/>
|
||||
<extension module="org.wildfly.extension.undertow"/>
|
||||
|
@ -92,6 +91,9 @@
|
|||
<logger category="com.arjuna">
|
||||
<level name="WARN"/>
|
||||
</logger>
|
||||
<logger category="com.networknt.schema">
|
||||
<level name="WARN"/>
|
||||
</logger>
|
||||
<logger category="io.jaegertracing.Configuration">
|
||||
<level name="WARN"/>
|
||||
</logger>
|
||||
|
@ -104,6 +106,47 @@
|
|||
<logger category="sun.rmi">
|
||||
<level name="WARN"/>
|
||||
</logger>
|
||||
<logger category="org.slf4j"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<logger category="org.springframework.security"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<logger category="org.jboss.security"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<logger category="org.jboss.as.security"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<logger category="org.picketbox"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<logger
|
||||
category="org.jboss.as.domain.management.security"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<logger category="org.wildfly.security"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<logger category="org.wildfly.elytron"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<logger category="org.apache.catalina"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<logger category="org.wildfly.extension.undertow"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<root-logger>
|
||||
<level name="INFO"/>
|
||||
<handlers>
|
||||
|
@ -121,6 +164,7 @@
|
|||
<subsystem xmlns="urn:jboss:domain:batch-jberet:3.0">
|
||||
<default-job-repository name="in-memory"/>
|
||||
<default-thread-pool name="batch"/>
|
||||
<security-domain name="ApplicationDomain"/>
|
||||
<job-repository name="in-memory">
|
||||
<in-memory/>
|
||||
</job-repository>
|
||||
|
@ -131,17 +175,14 @@
|
|||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:bean-validation:1.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:core-management:1.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:datasources:7.0">
|
||||
<subsystem xmlns="urn:jboss:domain:datasources:7.1">
|
||||
<datasources>
|
||||
<datasource jndi-name="java:jboss/datasources/ExampleDS" pool-name="ExampleDS"
|
||||
enabled="true" use-java-context="true"
|
||||
statistics-enabled="${wildfly.datasources.statistics-enabled:${wildfly.statistics-enabled:false}}">
|
||||
<connection-url>jdbc:h2:mem:test;DB_CLOSE_DELAY=-1;DB_CLOSE_ON_EXIT=FALSE</connection-url>
|
||||
<driver>h2</driver>
|
||||
<security>
|
||||
<user-name>sa</user-name>
|
||||
<password></password>
|
||||
</security>
|
||||
<security user-name="sa" password="sa"/>
|
||||
</datasource>
|
||||
<datasource jndi-name="java:jboss/datasources/Taskana"
|
||||
pool-name="TASKANA H2 Datasource"
|
||||
|
@ -152,10 +193,7 @@
|
|||
jdbc:h2:~/taskana-h2-data/testdb;NON_KEYWORDS=KEY,VALUE;AUTO_SERVER=TRUE;IGNORECASE=TRUE;LOCK_MODE=0
|
||||
</connection-url>
|
||||
<driver>h2</driver>
|
||||
<security>
|
||||
<user-name>sa</user-name>
|
||||
<password></password>
|
||||
</security>
|
||||
<security user-name="sa" password="sa"/>
|
||||
</datasource>
|
||||
<drivers>
|
||||
<driver name="h2" module="com.h2database.h2">
|
||||
|
@ -179,7 +217,7 @@
|
|||
<infinispan-timer-management name="transient" cache-container="ejb" cache="transient"
|
||||
max-active-timers="10000"/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:distributable-web:3.0" default-session-management="default"
|
||||
<subsystem xmlns="urn:jboss:domain:distributable-web:4.0" default-session-management="default"
|
||||
default-single-sign-on-management="default">
|
||||
<infinispan-session-management name="default" cache-container="web" granularity="SESSION">
|
||||
<local-affinity/>
|
||||
|
@ -191,8 +229,7 @@
|
|||
<spec-descriptor-property-replacement>false</spec-descriptor-property-replacement>
|
||||
<concurrent>
|
||||
<context-services>
|
||||
<context-service name="default" jndi-name="java:jboss/ee/concurrency/context/default"
|
||||
use-transaction-setup-provider="true"/>
|
||||
<context-service name="default" jndi-name="java:jboss/ee/concurrency/context/default" />
|
||||
</context-services>
|
||||
<managed-thread-factories>
|
||||
<managed-thread-factory name="default"
|
||||
|
@ -275,7 +312,7 @@
|
|||
<statistics enabled="${wildfly.ejb3.statistics-enabled:${wildfly.statistics-enabled:false}}"/>
|
||||
<log-system-exceptions value="true"/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:wildfly:elytron:16.0" final-providers="combined-providers"
|
||||
<subsystem xmlns="urn:wildfly:elytron:18.0" final-providers="combined-providers"
|
||||
disallowed-providers="OracleUcrypto">
|
||||
<providers>
|
||||
<aggregate-providers name="combined-providers">
|
||||
|
@ -290,16 +327,16 @@
|
|||
format="JSON"/>
|
||||
</audit-logging>
|
||||
<security-domains>
|
||||
<security-domain name="ManagementDomain" default-realm="ManagementRealm"
|
||||
permission-mapper="default-permission-mapper">
|
||||
<realm name="ManagementRealm" role-decoder="groups-to-roles"/>
|
||||
<realm name="local" role-mapper="super-user-mapper"/>
|
||||
</security-domain>
|
||||
<security-domain name="ApplicationDomain" default-realm="ApplicationRealm"
|
||||
permission-mapper="default-permission-mapper">
|
||||
<realm name="ApplicationRealm" role-decoder="groups-to-roles"/>
|
||||
<realm name="local"/>
|
||||
</security-domain>
|
||||
<security-domain name="ManagementDomain" default-realm="ManagementRealm"
|
||||
permission-mapper="default-permission-mapper">
|
||||
<realm name="ManagementRealm" role-decoder="groups-to-roles"/>
|
||||
<realm name="local" role-mapper="super-user-mapper"/>
|
||||
</security-domain>
|
||||
</security-domains>
|
||||
<security-realms>
|
||||
<identity-realm name="local" identity="$local"/>
|
||||
|
@ -338,24 +375,15 @@
|
|||
<permission class-name="org.wildfly.security.auth.permission.LoginPermission"/>
|
||||
</permission-set>
|
||||
<permission-set name="default-permissions">
|
||||
<permission class-name="org.wildfly.extension.batch.jberet.deployment.BatchPermission"
|
||||
module="org.wildfly.extension.batch.jberet" target-name="*"/>
|
||||
<permission class-name="org.wildfly.transaction.client.RemoteTransactionPermission"
|
||||
module="org.wildfly.transaction.client"/>
|
||||
<permission class-name="org.jboss.ejb.client.RemoteEJBPermission"
|
||||
module="org.jboss.ejb-client"/>
|
||||
<permission class-name="org.wildfly.extension.batch.jberet.deployment.BatchPermission"
|
||||
module="org.wildfly.extension.batch.jberet" target-name="*"/>
|
||||
</permission-set>
|
||||
</permission-sets>
|
||||
<http>
|
||||
<http-authentication-factory name="management-http-authentication"
|
||||
security-domain="ManagementDomain"
|
||||
http-server-mechanism-factory="global">
|
||||
<mechanism-configuration>
|
||||
<mechanism mechanism-name="DIGEST">
|
||||
<mechanism-realm realm-name="ManagementRealm"/>
|
||||
</mechanism>
|
||||
</mechanism-configuration>
|
||||
</http-authentication-factory>
|
||||
<http-authentication-factory name="application-http-authentication"
|
||||
security-domain="ApplicationDomain"
|
||||
http-server-mechanism-factory="global">
|
||||
|
@ -365,19 +393,18 @@
|
|||
</mechanism>
|
||||
</mechanism-configuration>
|
||||
</http-authentication-factory>
|
||||
<provider-http-server-mechanism-factory name="global"/>
|
||||
</http>
|
||||
<sasl>
|
||||
<sasl-authentication-factory name="management-sasl-authentication"
|
||||
sasl-server-factory="configured"
|
||||
security-domain="ManagementDomain">
|
||||
<http-authentication-factory name="management-http-authentication"
|
||||
security-domain="ManagementDomain"
|
||||
http-server-mechanism-factory="global">
|
||||
<mechanism-configuration>
|
||||
<mechanism mechanism-name="JBOSS-LOCAL-USER" realm-mapper="local"/>
|
||||
<mechanism mechanism-name="DIGEST-MD5">
|
||||
<mechanism mechanism-name="DIGEST">
|
||||
<mechanism-realm realm-name="ManagementRealm"/>
|
||||
</mechanism>
|
||||
</mechanism-configuration>
|
||||
</sasl-authentication-factory>
|
||||
</http-authentication-factory>
|
||||
<provider-http-server-mechanism-factory name="global"/>
|
||||
</http>
|
||||
<sasl>
|
||||
<sasl-authentication-factory name="application-sasl-authentication"
|
||||
sasl-server-factory="configured"
|
||||
security-domain="ApplicationDomain">
|
||||
|
@ -388,6 +415,16 @@
|
|||
</mechanism>
|
||||
</mechanism-configuration>
|
||||
</sasl-authentication-factory>
|
||||
<sasl-authentication-factory name="management-sasl-authentication"
|
||||
sasl-server-factory="configured"
|
||||
security-domain="ManagementDomain">
|
||||
<mechanism-configuration>
|
||||
<mechanism mechanism-name="JBOSS-LOCAL-USER" realm-mapper="local"/>
|
||||
<mechanism mechanism-name="DIGEST-MD5">
|
||||
<mechanism-realm realm-name="ManagementRealm"/>
|
||||
</mechanism>
|
||||
</mechanism-configuration>
|
||||
</sasl-authentication-factory>
|
||||
<configurable-sasl-server-factory name="configured" sasl-server-factory="elytron">
|
||||
<properties>
|
||||
<property name="wildfly.sasl.local-user.default-user" value="$local"/>
|
||||
|
@ -421,8 +458,11 @@
|
|||
<server-ssl-context name="applicationSSC" key-manager="applicationKM"/>
|
||||
</server-ssl-contexts>
|
||||
</tls>
|
||||
<policy name="jacc">
|
||||
<jacc-policy/>
|
||||
</policy>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:wildfly:elytron-oidc-client:1.0"/>
|
||||
<subsystem xmlns="urn:wildfly:elytron-oidc-client:2.0"/>
|
||||
<subsystem xmlns="urn:wildfly:health:1.0" security-enabled="false"/>
|
||||
<subsystem xmlns="urn:jboss:domain:iiop-openjdk:3.0">
|
||||
<orb socket-binding="iiop"/>
|
||||
|
@ -430,6 +470,22 @@
|
|||
<security server-requires-ssl="false" client-requires-ssl="false"/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:infinispan:14.0">
|
||||
<cache-container name="hibernate" marshaller="JBOSS" modules="org.infinispan.hibernate-cache">
|
||||
<local-cache name="entity">
|
||||
<heap-memory size="10000"/>
|
||||
<expiration max-idle="100000"/>
|
||||
</local-cache>
|
||||
<local-cache name="local-query">
|
||||
<heap-memory size="10000"/>
|
||||
<expiration max-idle="100000"/>
|
||||
</local-cache>
|
||||
<local-cache name="timestamps">
|
||||
<expiration interval="0"/>
|
||||
</local-cache>
|
||||
<local-cache name="pending-puts">
|
||||
<expiration max-idle="60000"/>
|
||||
</local-cache>
|
||||
</cache-container>
|
||||
<cache-container name="ejb" default-cache="passivation" marshaller="PROTOSTREAM"
|
||||
aliases="sfsb" modules="org.wildfly.clustering.ejb.infinispan">
|
||||
<local-cache name="passivation">
|
||||
|
@ -459,33 +515,11 @@
|
|||
<expiration interval="0"/>
|
||||
</local-cache>
|
||||
</cache-container>
|
||||
<cache-container name="server" default-cache="default" marshaller="PROTOSTREAM"
|
||||
modules="org.wildfly.clustering.singleton.server">
|
||||
<local-cache name="default">
|
||||
<expiration interval="0"/>
|
||||
</local-cache>
|
||||
</cache-container>
|
||||
<cache-container name="hibernate" marshaller="JBOSS" modules="org.infinispan.hibernate-cache">
|
||||
<local-cache name="entity">
|
||||
<heap-memory size="10000"/>
|
||||
<expiration max-idle="100000"/>
|
||||
</local-cache>
|
||||
<local-cache name="local-query">
|
||||
<heap-memory size="10000"/>
|
||||
<expiration max-idle="100000"/>
|
||||
</local-cache>
|
||||
<local-cache name="timestamps">
|
||||
<expiration interval="0"/>
|
||||
</local-cache>
|
||||
<local-cache name="pending-puts">
|
||||
<expiration max-idle="60000"/>
|
||||
</local-cache>
|
||||
</cache-container>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:io:3.0">
|
||||
<worker name="default"/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:jaxrs:2.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:jaxrs:3.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:jca:6.0">
|
||||
<archive-validation enabled="true" fail-on-error="true" fail-on-warn="false"/>
|
||||
<bean-validation enabled="true"/>
|
||||
|
@ -520,7 +554,7 @@
|
|||
<smtp-server outbound-socket-binding-ref="mail-smtp"/>
|
||||
</mail-session>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:messaging-activemq:14.0">
|
||||
<subsystem xmlns="urn:jboss:domain:messaging-activemq:16.0">
|
||||
<server name="default">
|
||||
<security elytron-domain="ApplicationDomain"/>
|
||||
<statistics
|
||||
|
@ -564,21 +598,17 @@
|
|||
prefix="${wildfly.metrics.prefix:wildfly}"/>
|
||||
<subsystem xmlns="urn:wildfly:microprofile-config-smallrye:2.0"/>
|
||||
<subsystem xmlns="urn:wildfly:microprofile-jwt-smallrye:1.0"/>
|
||||
<subsystem xmlns="urn:wildfly:microprofile-opentracing-smallrye:3.0" default-tracer="jaeger">
|
||||
<jaeger-tracer name="jaeger">
|
||||
<sampler-configuration sampler-type="const" sampler-param="1.0"/>
|
||||
</jaeger-tracer>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:naming:2.0">
|
||||
<remote-naming/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:pojo:1.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:remoting:5.0">
|
||||
<subsystem xmlns="urn:jboss:domain:remoting:6.0">
|
||||
<endpoint worker="default"/>
|
||||
<http-connector name="http-remoting-connector" connector-ref="default"
|
||||
sasl-authentication-factory="application-sasl-authentication"/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:request-controller:1.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:resource-adapters:6.1"/>
|
||||
<subsystem xmlns="urn:jboss:domain:resource-adapters:7.1"/>
|
||||
<subsystem xmlns="urn:jboss:domain:sar:1.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:security-manager:1.0">
|
||||
<deployment-permissions>
|
||||
|
@ -599,10 +629,10 @@
|
|||
statistics-enabled="${wildfly.transactions.statistics-enabled:${wildfly.statistics-enabled:false}}"/>
|
||||
<object-store path="tx-object-store" relative-to="jboss.server.data.dir"/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:undertow:13.0" default-server="default-server"
|
||||
default-virtual-host="default-host" default-servlet-container="default"
|
||||
default-security-domain="other"
|
||||
statistics-enabled="${wildfly.undertow.statistics-enabled:${wildfly.statistics-enabled:false}}">
|
||||
<subsystem xmlns="urn:jboss:domain:undertow:14.0" default-virtual-host="default-host"
|
||||
default-servlet-container="default" default-server="default-server"
|
||||
statistics-enabled="${wildfly.undertow.statistics-enabled:${wildfly.statistics-enabled:false}}"
|
||||
default-security-domain="other">
|
||||
<byte-buffer-pool name="default"/>
|
||||
<buffer-cache name="default"/>
|
||||
<server name="default-server">
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<module name="com.h2database.h2" xmlns="urn:jboss:module:1.9">
|
||||
|
||||
<resources>
|
||||
<resource-root path="h2-2.1.214.jar"/>
|
||||
<resource-root path="h2-2.2.224.jar"/>
|
||||
</resources>
|
||||
<dependencies>
|
||||
<module name="java.compiler"/>
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-lib-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -77,7 +77,7 @@ public class TaskanaProducersTest {
|
|||
// Delete Taskana folder if exists
|
||||
Path taskanaH2Data = Path.of(System.getProperty("user.home"), "taskana-h2-data");
|
||||
if (Files.exists(taskanaH2Data)) {
|
||||
FileUtils.deleteDirectory(taskanaH2Data.toFile());
|
||||
FileUtils.forceDelete(taskanaH2Data.toFile());
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -111,7 +111,7 @@ public class TaskanaProducersTest {
|
|||
"jdbc:h2:~/taskana-h2-data/testdb;NON_KEYWORDS=KEY,VALUE;AUTO_SERVER=TRUE;"
|
||||
+ "IGNORECASE=TRUE;LOCK_MODE=0",
|
||||
"sa",
|
||||
"");
|
||||
"sa");
|
||||
}
|
||||
|
||||
private int countTasksByName(String taskName) throws Exception {
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<defaultProtocol type="Servlet 6.0"/>
|
||||
<container qualifier="wildfly" default="true">
|
||||
<configuration>
|
||||
<property name="jbossHome">target/wildfly-27.0.1.Final</property>
|
||||
<property name="jbossHome">target/wildfly-31.0.1.Final</property>
|
||||
<property name="serverConfig">int-test-standalone.xml</property>
|
||||
<!-- <property name="javaVmArguments">-->
|
||||
<!-- -Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=y-->
|
||||
|
|
|
@ -36,7 +36,6 @@
|
|||
<extension module="org.wildfly.extension.metrics"/>
|
||||
<extension module="org.wildfly.extension.microprofile.config-smallrye"/>
|
||||
<extension module="org.wildfly.extension.microprofile.jwt-smallrye"/>
|
||||
<extension module="org.wildfly.extension.microprofile.opentracing-smallrye"/>
|
||||
<extension module="org.wildfly.extension.request-controller"/>
|
||||
<extension module="org.wildfly.extension.security.manager"/>
|
||||
<extension module="org.wildfly.extension.undertow"/>
|
||||
|
@ -92,6 +91,9 @@
|
|||
<logger category="com.arjuna">
|
||||
<level name="WARN"/>
|
||||
</logger>
|
||||
<logger category="com.networknt.schema">
|
||||
<level name="WARN"/>
|
||||
</logger>
|
||||
<logger category="io.jaegertracing.Configuration">
|
||||
<level name="WARN"/>
|
||||
</logger>
|
||||
|
@ -104,6 +106,47 @@
|
|||
<logger category="sun.rmi">
|
||||
<level name="WARN"/>
|
||||
</logger>
|
||||
<logger category="org.slf4j"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<logger category="org.springframework.security"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<logger category="org.jboss.security"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<logger category="org.jboss.as.security"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<logger category="org.picketbox"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<logger
|
||||
category="org.jboss.as.domain.management.security"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<logger category="org.wildfly.security"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<logger category="org.wildfly.elytron"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<logger category="org.apache.catalina"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<logger category="org.wildfly.extension.undertow"
|
||||
use-parent-handlers="true">
|
||||
<level name="INFO"/>
|
||||
</logger>
|
||||
<root-logger>
|
||||
<level name="INFO"/>
|
||||
<handlers>
|
||||
|
@ -121,6 +164,7 @@
|
|||
<subsystem xmlns="urn:jboss:domain:batch-jberet:3.0">
|
||||
<default-job-repository name="in-memory"/>
|
||||
<default-thread-pool name="batch"/>
|
||||
<security-domain name="ApplicationDomain"/>
|
||||
<job-repository name="in-memory">
|
||||
<in-memory/>
|
||||
</job-repository>
|
||||
|
@ -131,17 +175,14 @@
|
|||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:bean-validation:1.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:core-management:1.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:datasources:7.0">
|
||||
<subsystem xmlns="urn:jboss:domain:datasources:7.1">
|
||||
<datasources>
|
||||
<datasource jndi-name="java:jboss/datasources/ExampleDS" pool-name="ExampleDS"
|
||||
enabled="true" use-java-context="true"
|
||||
statistics-enabled="${wildfly.datasources.statistics-enabled:${wildfly.statistics-enabled:false}}">
|
||||
<connection-url>jdbc:h2:mem:test;DB_CLOSE_DELAY=-1;DB_CLOSE_ON_EXIT=FALSE</connection-url>
|
||||
<driver>h2</driver>
|
||||
<security>
|
||||
<user-name>sa</user-name>
|
||||
<password></password>
|
||||
</security>
|
||||
<security user-name="sa" password="sa"/>
|
||||
</datasource>
|
||||
<datasource jndi-name="java:jboss/datasources/TestDS"
|
||||
pool-name="TASKANA H2 Datasource"
|
||||
|
@ -152,10 +193,7 @@
|
|||
jdbc:h2:~/taskana-h2-data/testdb;NON_KEYWORDS=KEY,VALUE;AUTO_SERVER=TRUE;IGNORECASE=TRUE;LOCK_MODE=0
|
||||
</connection-url>
|
||||
<driver>h2</driver>
|
||||
<security>
|
||||
<user-name>sa</user-name>
|
||||
<password></password>
|
||||
</security>
|
||||
<security user-name="sa" password="sa"/>
|
||||
</datasource>
|
||||
<drivers>
|
||||
<driver name="h2" module="com.h2database.h2">
|
||||
|
@ -179,7 +217,7 @@
|
|||
<infinispan-timer-management name="transient" cache-container="ejb" cache="transient"
|
||||
max-active-timers="10000"/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:distributable-web:3.0" default-session-management="default"
|
||||
<subsystem xmlns="urn:jboss:domain:distributable-web:4.0" default-session-management="default"
|
||||
default-single-sign-on-management="default">
|
||||
<infinispan-session-management name="default" cache-container="web" granularity="SESSION">
|
||||
<local-affinity/>
|
||||
|
@ -191,8 +229,7 @@
|
|||
<spec-descriptor-property-replacement>false</spec-descriptor-property-replacement>
|
||||
<concurrent>
|
||||
<context-services>
|
||||
<context-service name="default" jndi-name="java:jboss/ee/concurrency/context/default"
|
||||
use-transaction-setup-provider="true"/>
|
||||
<context-service name="default" jndi-name="java:jboss/ee/concurrency/context/default" />
|
||||
</context-services>
|
||||
<managed-thread-factories>
|
||||
<managed-thread-factory name="default"
|
||||
|
@ -275,7 +312,7 @@
|
|||
<statistics enabled="${wildfly.ejb3.statistics-enabled:${wildfly.statistics-enabled:false}}"/>
|
||||
<log-system-exceptions value="true"/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:wildfly:elytron:16.0" final-providers="combined-providers"
|
||||
<subsystem xmlns="urn:wildfly:elytron:18.0" final-providers="combined-providers"
|
||||
disallowed-providers="OracleUcrypto">
|
||||
<providers>
|
||||
<aggregate-providers name="combined-providers">
|
||||
|
@ -290,16 +327,16 @@
|
|||
format="JSON"/>
|
||||
</audit-logging>
|
||||
<security-domains>
|
||||
<security-domain name="ManagementDomain" default-realm="ManagementRealm"
|
||||
permission-mapper="default-permission-mapper">
|
||||
<realm name="ManagementRealm" role-decoder="groups-to-roles"/>
|
||||
<realm name="local" role-mapper="super-user-mapper"/>
|
||||
</security-domain>
|
||||
<security-domain name="ApplicationDomain" default-realm="ApplicationRealm"
|
||||
permission-mapper="default-permission-mapper">
|
||||
<realm name="ApplicationRealm" role-decoder="groups-to-roles"/>
|
||||
<realm name="local"/>
|
||||
</security-domain>
|
||||
<security-domain name="ManagementDomain" default-realm="ManagementRealm"
|
||||
permission-mapper="default-permission-mapper">
|
||||
<realm name="ManagementRealm" role-decoder="groups-to-roles"/>
|
||||
<realm name="local" role-mapper="super-user-mapper"/>
|
||||
</security-domain>
|
||||
</security-domains>
|
||||
<security-realms>
|
||||
<identity-realm name="local" identity="$local"/>
|
||||
|
@ -338,24 +375,15 @@
|
|||
<permission class-name="org.wildfly.security.auth.permission.LoginPermission"/>
|
||||
</permission-set>
|
||||
<permission-set name="default-permissions">
|
||||
<permission class-name="org.wildfly.extension.batch.jberet.deployment.BatchPermission"
|
||||
module="org.wildfly.extension.batch.jberet" target-name="*"/>
|
||||
<permission class-name="org.wildfly.transaction.client.RemoteTransactionPermission"
|
||||
module="org.wildfly.transaction.client"/>
|
||||
<permission class-name="org.jboss.ejb.client.RemoteEJBPermission"
|
||||
module="org.jboss.ejb-client"/>
|
||||
<permission class-name="org.wildfly.extension.batch.jberet.deployment.BatchPermission"
|
||||
module="org.wildfly.extension.batch.jberet" target-name="*"/>
|
||||
</permission-set>
|
||||
</permission-sets>
|
||||
<http>
|
||||
<http-authentication-factory name="management-http-authentication"
|
||||
security-domain="ManagementDomain"
|
||||
http-server-mechanism-factory="global">
|
||||
<mechanism-configuration>
|
||||
<mechanism mechanism-name="DIGEST">
|
||||
<mechanism-realm realm-name="ManagementRealm"/>
|
||||
</mechanism>
|
||||
</mechanism-configuration>
|
||||
</http-authentication-factory>
|
||||
<http-authentication-factory name="application-http-authentication"
|
||||
security-domain="ApplicationDomain"
|
||||
http-server-mechanism-factory="global">
|
||||
|
@ -365,19 +393,18 @@
|
|||
</mechanism>
|
||||
</mechanism-configuration>
|
||||
</http-authentication-factory>
|
||||
<provider-http-server-mechanism-factory name="global"/>
|
||||
</http>
|
||||
<sasl>
|
||||
<sasl-authentication-factory name="management-sasl-authentication"
|
||||
sasl-server-factory="configured"
|
||||
security-domain="ManagementDomain">
|
||||
<http-authentication-factory name="management-http-authentication"
|
||||
security-domain="ManagementDomain"
|
||||
http-server-mechanism-factory="global">
|
||||
<mechanism-configuration>
|
||||
<mechanism mechanism-name="JBOSS-LOCAL-USER" realm-mapper="local"/>
|
||||
<mechanism mechanism-name="DIGEST-MD5">
|
||||
<mechanism mechanism-name="DIGEST">
|
||||
<mechanism-realm realm-name="ManagementRealm"/>
|
||||
</mechanism>
|
||||
</mechanism-configuration>
|
||||
</sasl-authentication-factory>
|
||||
</http-authentication-factory>
|
||||
<provider-http-server-mechanism-factory name="global"/>
|
||||
</http>
|
||||
<sasl>
|
||||
<sasl-authentication-factory name="application-sasl-authentication"
|
||||
sasl-server-factory="configured"
|
||||
security-domain="ApplicationDomain">
|
||||
|
@ -388,6 +415,16 @@
|
|||
</mechanism>
|
||||
</mechanism-configuration>
|
||||
</sasl-authentication-factory>
|
||||
<sasl-authentication-factory name="management-sasl-authentication"
|
||||
sasl-server-factory="configured"
|
||||
security-domain="ManagementDomain">
|
||||
<mechanism-configuration>
|
||||
<mechanism mechanism-name="JBOSS-LOCAL-USER" realm-mapper="local"/>
|
||||
<mechanism mechanism-name="DIGEST-MD5">
|
||||
<mechanism-realm realm-name="ManagementRealm"/>
|
||||
</mechanism>
|
||||
</mechanism-configuration>
|
||||
</sasl-authentication-factory>
|
||||
<configurable-sasl-server-factory name="configured" sasl-server-factory="elytron">
|
||||
<properties>
|
||||
<property name="wildfly.sasl.local-user.default-user" value="$local"/>
|
||||
|
@ -421,8 +458,11 @@
|
|||
<server-ssl-context name="applicationSSC" key-manager="applicationKM"/>
|
||||
</server-ssl-contexts>
|
||||
</tls>
|
||||
<policy name="jacc">
|
||||
<jacc-policy/>
|
||||
</policy>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:wildfly:elytron-oidc-client:1.0"/>
|
||||
<subsystem xmlns="urn:wildfly:elytron-oidc-client:2.0"/>
|
||||
<subsystem xmlns="urn:wildfly:health:1.0" security-enabled="false"/>
|
||||
<subsystem xmlns="urn:jboss:domain:iiop-openjdk:3.0">
|
||||
<orb socket-binding="iiop"/>
|
||||
|
@ -430,6 +470,22 @@
|
|||
<security server-requires-ssl="false" client-requires-ssl="false"/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:infinispan:14.0">
|
||||
<cache-container name="hibernate" marshaller="JBOSS" modules="org.infinispan.hibernate-cache">
|
||||
<local-cache name="entity">
|
||||
<heap-memory size="10000"/>
|
||||
<expiration max-idle="100000"/>
|
||||
</local-cache>
|
||||
<local-cache name="local-query">
|
||||
<heap-memory size="10000"/>
|
||||
<expiration max-idle="100000"/>
|
||||
</local-cache>
|
||||
<local-cache name="timestamps">
|
||||
<expiration interval="0"/>
|
||||
</local-cache>
|
||||
<local-cache name="pending-puts">
|
||||
<expiration max-idle="60000"/>
|
||||
</local-cache>
|
||||
</cache-container>
|
||||
<cache-container name="ejb" default-cache="passivation" marshaller="PROTOSTREAM"
|
||||
aliases="sfsb" modules="org.wildfly.clustering.ejb.infinispan">
|
||||
<local-cache name="passivation">
|
||||
|
@ -459,33 +515,11 @@
|
|||
<expiration interval="0"/>
|
||||
</local-cache>
|
||||
</cache-container>
|
||||
<cache-container name="server" default-cache="default" marshaller="PROTOSTREAM"
|
||||
modules="org.wildfly.clustering.singleton.server">
|
||||
<local-cache name="default">
|
||||
<expiration interval="0"/>
|
||||
</local-cache>
|
||||
</cache-container>
|
||||
<cache-container name="hibernate" marshaller="JBOSS" modules="org.infinispan.hibernate-cache">
|
||||
<local-cache name="entity">
|
||||
<heap-memory size="10000"/>
|
||||
<expiration max-idle="100000"/>
|
||||
</local-cache>
|
||||
<local-cache name="local-query">
|
||||
<heap-memory size="10000"/>
|
||||
<expiration max-idle="100000"/>
|
||||
</local-cache>
|
||||
<local-cache name="timestamps">
|
||||
<expiration interval="0"/>
|
||||
</local-cache>
|
||||
<local-cache name="pending-puts">
|
||||
<expiration max-idle="60000"/>
|
||||
</local-cache>
|
||||
</cache-container>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:io:3.0">
|
||||
<worker name="default"/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:jaxrs:2.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:jaxrs:3.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:jca:6.0">
|
||||
<archive-validation enabled="true" fail-on-error="true" fail-on-warn="false"/>
|
||||
<bean-validation enabled="true"/>
|
||||
|
@ -520,7 +554,7 @@
|
|||
<smtp-server outbound-socket-binding-ref="mail-smtp"/>
|
||||
</mail-session>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:messaging-activemq:14.0">
|
||||
<subsystem xmlns="urn:jboss:domain:messaging-activemq:16.0">
|
||||
<server name="default">
|
||||
<security elytron-domain="ApplicationDomain"/>
|
||||
<statistics
|
||||
|
@ -564,21 +598,17 @@
|
|||
prefix="${wildfly.metrics.prefix:wildfly}"/>
|
||||
<subsystem xmlns="urn:wildfly:microprofile-config-smallrye:2.0"/>
|
||||
<subsystem xmlns="urn:wildfly:microprofile-jwt-smallrye:1.0"/>
|
||||
<subsystem xmlns="urn:wildfly:microprofile-opentracing-smallrye:3.0" default-tracer="jaeger">
|
||||
<jaeger-tracer name="jaeger">
|
||||
<sampler-configuration sampler-type="const" sampler-param="1.0"/>
|
||||
</jaeger-tracer>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:naming:2.0">
|
||||
<remote-naming/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:pojo:1.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:remoting:5.0">
|
||||
<subsystem xmlns="urn:jboss:domain:remoting:6.0">
|
||||
<endpoint worker="default"/>
|
||||
<http-connector name="http-remoting-connector" connector-ref="default"
|
||||
sasl-authentication-factory="application-sasl-authentication"/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:request-controller:1.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:resource-adapters:6.1"/>
|
||||
<subsystem xmlns="urn:jboss:domain:resource-adapters:7.1"/>
|
||||
<subsystem xmlns="urn:jboss:domain:sar:1.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:security-manager:1.0">
|
||||
<deployment-permissions>
|
||||
|
@ -599,10 +629,10 @@
|
|||
statistics-enabled="${wildfly.transactions.statistics-enabled:${wildfly.statistics-enabled:false}}"/>
|
||||
<object-store path="tx-object-store" relative-to="jboss.server.data.dir"/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:undertow:13.0" default-server="default-server"
|
||||
default-virtual-host="default-host" default-servlet-container="default"
|
||||
default-security-domain="other"
|
||||
statistics-enabled="${wildfly.undertow.statistics-enabled:${wildfly.statistics-enabled:false}}">
|
||||
<subsystem xmlns="urn:jboss:domain:undertow:14.0" default-virtual-host="default-host"
|
||||
default-servlet-container="default" default-server="default-server"
|
||||
statistics-enabled="${wildfly.undertow.statistics-enabled:${wildfly.statistics-enabled:false}}"
|
||||
default-security-domain="other">
|
||||
<byte-buffer-pool name="default"/>
|
||||
<buffer-cache name="default"/>
|
||||
<server name="default-server">
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<module name="com.h2database.h2" xmlns="urn:jboss:module:1.9">
|
||||
|
||||
<resources>
|
||||
<resource-root path="h2-2.1.214.jar"/>
|
||||
<resource-root path="h2-2.2.224.jar"/>
|
||||
</resources>
|
||||
<dependencies>
|
||||
<module name="java.compiler"/>
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-lib-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-lib-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-lib-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-lib-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-lib-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
9
pom.xml
9
pom.xml
|
@ -4,7 +4,7 @@
|
|||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<packaging>pom</packaging>
|
||||
|
||||
<name>${project.groupId}:${project.artifactId}</name>
|
||||
|
@ -60,17 +60,17 @@
|
|||
<version.maven.sonar>3.11.0.3922</version.maven.sonar>
|
||||
|
||||
<!-- release dependencies -->
|
||||
<version.maven.gpg>3.2.3</version.maven.gpg>
|
||||
<version.maven.gpg>3.2.4</version.maven.gpg>
|
||||
<version.sonatype>1.6.13</version.sonatype>
|
||||
|
||||
<!-- spring dependencies -->
|
||||
<version.jakarta.annotation-api>2.1.1</version.jakarta.annotation-api>
|
||||
<version.spring.plugin.core>3.0.0</version.spring.plugin.core>
|
||||
<version.spring.boot>3.1.5</version.spring.boot>
|
||||
<version.spring.boot>3.2.4</version.spring.boot>
|
||||
<version.spring.mybatis>3.0.2</version.spring.mybatis>
|
||||
|
||||
<!-- wildfly dependencies -->
|
||||
<version.wildfly>27.0.1.Final</version.wildfly>
|
||||
<version.wildfly>31.0.1.Final</version.wildfly>
|
||||
|
||||
<!-- camunda dependencies -->
|
||||
<version.camunda.dmn>7.21.0</version.camunda.dmn>
|
||||
|
@ -89,6 +89,7 @@
|
|||
<version.jacoco>0.8.11</version.jacoco>
|
||||
<version.slf4j-test>3.0.1</version.slf4j-test>
|
||||
<version.auto-restdocs>2.0.11</version.auto-restdocs>
|
||||
<version.spring-openapi>2.5.0</version.spring-openapi>
|
||||
<version.testcontainers>1.19.7</version.testcontainers>
|
||||
|
||||
<!-- AspectJ dependencies -->
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-rest-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@ -50,6 +50,11 @@
|
|||
<artifactId>taskana-rest-spring-example-common</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springdoc</groupId>
|
||||
<artifactId>springdoc-openapi-starter-webmvc-ui</artifactId>
|
||||
<version>${version.spring-openapi}</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<profiles>
|
||||
|
|
|
@ -0,0 +1,372 @@
|
|||
package pro.taskana.example.boot;
|
||||
|
||||
import io.swagger.v3.oas.annotations.OpenAPIDefinition;
|
||||
import io.swagger.v3.oas.annotations.enums.SecuritySchemeType;
|
||||
import io.swagger.v3.oas.annotations.info.Info;
|
||||
import io.swagger.v3.oas.annotations.security.SecurityRequirement;
|
||||
import io.swagger.v3.oas.annotations.security.SecurityScheme;
|
||||
import io.swagger.v3.oas.models.media.ArraySchema;
|
||||
import io.swagger.v3.oas.models.media.ObjectSchema;
|
||||
import io.swagger.v3.oas.models.media.StringSchema;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import org.springdoc.core.customizers.OpenApiCustomizer;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
|
||||
@Configuration
|
||||
@OpenAPIDefinition(
|
||||
info =
|
||||
@Info(
|
||||
title = "TASKANA RESTful API Documentation",
|
||||
version = "8.2.0",
|
||||
description =
|
||||
"<h1>Overview</h1>"
|
||||
+ "<p>"
|
||||
+ "This is the REST documentation for [TASKANA](http://taskana.pro) - the "
|
||||
+ "world’s first open source solution for Enterprise Task Management."
|
||||
+ "</p>"
|
||||
+ "<p>"
|
||||
+ "**For all Query Parameters:**<br> Whenever a parameter is an array type,"
|
||||
+ " several values can be passed by declaring that parameter multiple times."
|
||||
+ "</p>"
|
||||
+ "<p>"
|
||||
+ "Whenever a parameter is a complex type, the attributes of the value-object"
|
||||
+ " can be passed as a json. For example, a complex parameter with the name "
|
||||
+ "\"complex-query-param\" and attributes \"attribute1\" and \"attribute2\" "
|
||||
+ "would be specified in the following way:complex-query-param={\"attribute1\""
|
||||
+ ":\"value1\",\"attribute2\":\"value2\"}"
|
||||
+ "</p>"
|
||||
+ "<p>"
|
||||
+ "Whenever a parameter is a value-less type (e.g owner-is-null and "
|
||||
+ "current-user) it is expected to be defined without a value, i.e., it should"
|
||||
+ " be specified as ?parameter and not ?parameter= or ?parameter=someValue"
|
||||
+ "</p>"
|
||||
+ "<h1>Hypermedia Support</h1>"
|
||||
+ "<p>"
|
||||
+ "NOTE: HATEOAS support is still in development.Please have a look at "
|
||||
+ "example responses for each resource to determine the available links."
|
||||
+ "</p>"
|
||||
+ "<p>"
|
||||
+ "TASKANA uses the [HATEOAS](https://restfulapi.net/hateoas/) (Hypermedia"
|
||||
+ " as the Engine of Application State) REST constraint. Most of our resources"
|
||||
+ " contain a _links section which contains navigation links. Besides, helping"
|
||||
+ " to navigate through our REST API, the navigation links also encapsulate the"
|
||||
+ " API. Using HATEOAS allows us to change some endpoints without modifying "
|
||||
+ "your frontend."
|
||||
+ "</p>"
|
||||
+ "<h1>Errors</h1>"
|
||||
+ "<p>"
|
||||
+ "In order to support multilingual websites, TASKANA uses error codes to "
|
||||
+ "define which error occurred. Additionally, an optional set of message "
|
||||
+ "variables, containing some technical information, is added, so that the "
|
||||
+ "website can describe the error with all details."
|
||||
+ "</p>"
|
||||
+ "<table>"
|
||||
+ "<thead>"
|
||||
+ "<tr>"
|
||||
+ "<th>Status Code</th>"
|
||||
+ "<th>Key</th>"
|
||||
+ "<th>Message Variables</th>"
|
||||
+ "</tr>"
|
||||
+ "</thead>"
|
||||
+ "<tbody>"
|
||||
+ "<tr>"
|
||||
+ "<td>**400 BAD_REQUEST**</td>"
|
||||
+ "<td>CLASSIFICATION_SERVICE_LEVEL_MALFORMED</td>"
|
||||
+ "<td>serviceLevel, classificationKey, domain</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**400 BAD_REQUEST**</td>"
|
||||
+ "<td>CUSTOM_HOLIDAY_WRONG_FORMAT</td>"
|
||||
+ "<td>customHoliday</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**400 BAD_REQUEST**</td>"
|
||||
+ "<td>DOMAIN_NOT_FOUND</td>"
|
||||
+ "<td>domain</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**400 BAD_REQUEST**</td>"
|
||||
+ "<td>INVALID_ARGUMENT</td>"
|
||||
+ "<td></td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**400 BAD_REQUEST**</td>"
|
||||
+ "<td>QUERY_PARAMETER_MALFORMED</td>"
|
||||
+ "<td>malformedQueryParameters</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**400 BAD_REQUEST**</td>"
|
||||
+ "<td>TASK_INVALID_CALLBACK_STATE</td>"
|
||||
+ "<td>taskId, taskCallbackState, requiredCallbackStates</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**400 BAD_REQUEST**</td>"
|
||||
+ "<td>TASK_INVALID_OWNER</td>"
|
||||
+ "<td>taskId, currentUserId</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**400 BAD_REQUEST**</td>"
|
||||
+ "<td>TASK_INVALID_STATE</td>"
|
||||
+ "<td>taskId, taskState, requiredTaskStates</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**403 FORBIDDEN**</td>"
|
||||
+ "<td>NOT_AUTHORIZED</td>"
|
||||
+ "<td>roles, currentUserId</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**403 FORBIDDEN**</td>"
|
||||
+ "<td>NOT_AUTHORIZED_ON_TASK_COMMENT</td>"
|
||||
+ "<td>currentUserId, taskCommentId</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**403 FORBIDDEN**</td>"
|
||||
+ "<td>NOT_AUTHORIZED_ON_WORKBASKET_WITH_ID</td>"
|
||||
+ "<td>currentUserId, workbasketId, requiredPermissions</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**403 FORBIDDEN**</td>"
|
||||
+ "<td>NOT_AUTHORIZED_ON_WORKBASKET_WITH_KEY_AND_DOMAIN</td>"
|
||||
+ "<td>currentUserId, workbasketKey, domain, requiredPermissions</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**404 NOT_FOUND**</td>"
|
||||
+ "<td>CLASSIFICATION_WITH_ID_NOT_FOUND</td>"
|
||||
+ "<td>classificationId</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**404 NOT_FOUND**</td>"
|
||||
+ "<td>CLASSIFICATION_WITH_KEY_NOT_FOUND</td>"
|
||||
+ "<td>classificationKey, domain</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**404 NOT_FOUND**</td>"
|
||||
+ "<td>TASK_COMMENT_NOT_FOUND</td>"
|
||||
+ "<td>taskCommentId</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**404 NOT_FOUND**</td>"
|
||||
+ "<td>TASK_NOT_FOUND</td>"
|
||||
+ "<td>taskId</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**404 NOT_FOUND**</td>"
|
||||
+ "<td>USER_NOT_FOUND</td>"
|
||||
+ "<td>userId</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**404 NOT_FOUND**</td>"
|
||||
+ "<td>WORKBASKET_WITH_ID_NOT_FOUND</td>"
|
||||
+ "<td>workbasketId</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**404 NOT_FOUND**</td>"
|
||||
+ "<td>WORKBASKET_WITH_KEY_NOT_FOUND</td>"
|
||||
+ "<td>workbasketKey, domain</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**409 CONFLICT**</td>"
|
||||
+ "<td>ATTACHMENT_ALREADY_EXISTS</td>"
|
||||
+ "<td>attachmentId, taskId</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**409 CONFLICT**</td>"
|
||||
+ "<td>CLASSIFICATION_ALREADY_EXISTS</td>"
|
||||
+ "<td>classificationKey, domain</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**409 CONFLICT**</td>"
|
||||
+ "<td>ENTITY_NOT_UP_TO_DATE</td>"
|
||||
+ "<td>entityId</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**409 CONFLICT**</td>"
|
||||
+ "<td>TASK_ALREADY_EXISTS</td>"
|
||||
+ "<td>externalTaskId</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**409 CONFLICT**</td>"
|
||||
+ "<td>USER_ALREADY_EXISTS</td>"
|
||||
+ "<td>userID</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**409 CONFLICT**</td>"
|
||||
+ "<td>WORKBASKET_ACCESS_ITEM_ALREADY_EXISTS</td>"
|
||||
+ "<td>accessId, workbasketId</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**409 CONFLICT**</td>"
|
||||
+ "<td>WORKBASKET_ALREADY_EXISTS</td>"
|
||||
+ "<td>workbasketKey, domain</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**409 CONFLICT**</td>"
|
||||
+ "<td>WORKBASKET_MARKED_FOR_DELETION</td>"
|
||||
+ "<td>workbasketId</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**413 PAYLOAD_TOO_LARGE**</td>"
|
||||
+ "<td>PAYLOAD_TOO_LARGE</td>"
|
||||
+ "<td></td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**423 LOCKED**</td>"
|
||||
+ "<td>CLASSIFICATION_IN_USE</td>"
|
||||
+ "<td>classificationKey, domain</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**423 LOCKED**</td>"
|
||||
+ "<td>WORKBASKET_IN_USE</td>"
|
||||
+ "<td>workbasketId</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**500 INTERNAL_SERVER_ERROR**</td>"
|
||||
+ "<td>CONNECTION_AUTOCOMMIT_FAILED</td>"
|
||||
+ "<td></td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**500 INTERNAL_SERVER_ERROR**</td>"
|
||||
+ "<td>CONNECTION_NOT_SET</td>"
|
||||
+ "<td></td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**500 INTERNAL_SERVER_ERROR**</td>"
|
||||
+ "<td>CRITICAL_SYSTEM_ERROR</td>"
|
||||
+ "<td></td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**500 INTERNAL_SERVER_ERROR**</td>"
|
||||
+ "<td>DATABASE_UNSUPPORTED</td>"
|
||||
+ "<td>databaseProductName</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>**500 INTERNAL_SERVER_ERROR**</td>"
|
||||
+ "<td>UNKNOWN_ERROR</td>"
|
||||
+ "<td></td>"
|
||||
+ "</tr>"
|
||||
+ "</tbody>"
|
||||
+ "</table>"
|
||||
+ "<h2>Errors</h2>"
|
||||
+ "<table>"
|
||||
+ "<thead>"
|
||||
+ "<tr>"
|
||||
+ "<th>Key</th>"
|
||||
+ "<th>Type</th>"
|
||||
+ "</tr>"
|
||||
+ "</thead>"
|
||||
+ "<tbody>"
|
||||
+ "<tr>"
|
||||
+ "<td>accessId</td>"
|
||||
+ "<td>String</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>attachmentId</td>"
|
||||
+ "<td>String</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>classificationId</td>"
|
||||
+ "<td>String</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>classificationKey</td>"
|
||||
+ "<td>String</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>currentUserId</td>"
|
||||
+ "<td>String</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>customHoliday</td>"
|
||||
+ "<td>String</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>databaseProductName</td>"
|
||||
+ "<td>String</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>domain</td>"
|
||||
+ "<td>String</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>externalTaskId</td>"
|
||||
+ "<td>String</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>historyEventId</td>"
|
||||
+ "<td>String</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>malformedQueryParameters</td>"
|
||||
+ "<td>MalformedQueryParameter[]</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>requiredCallbackStates</td>"
|
||||
+ "<td>CallbackState[]</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>requiredPermissions</td>"
|
||||
+ "<td>WorkbasketPermission[]</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>requiredTaskStates</td>"
|
||||
+ "<td>TaskState[]</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>roles</td>"
|
||||
+ "<td>TaskanaRole[]</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>taskCallbackState</td>"
|
||||
+ "<td>CallbackState</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>taskCommentId</td>"
|
||||
+ "<td>String</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>taskId</td>"
|
||||
+ "<td>String</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>taskState</td>"
|
||||
+ "<td>TaskState</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>workbasketId</td>"
|
||||
+ "<td>String</td>"
|
||||
+ "</tr>"
|
||||
+ "<tr>"
|
||||
+ "<td>workbasketKey</td>"
|
||||
+ "<td>String</td>"
|
||||
+ "</tr>"
|
||||
+ "</tbody>"
|
||||
+ "</table>"),
|
||||
security = {@SecurityRequirement(name = "basicAuth")})
|
||||
@SecurityScheme(name = "basicAuth", type = SecuritySchemeType.HTTP, scheme = "basic")
|
||||
public class OpenApiConfiguration {
|
||||
@Bean
|
||||
public OpenApiCustomizer openApiCustomizer() {
|
||||
return openApi -> {
|
||||
ArraySchema arraySchema = new ArraySchema().items(new StringSchema());
|
||||
|
||||
// Define the ObjectSchema for the map with String keys and Array of Strings as values
|
||||
ObjectSchema mapSchema =
|
||||
(ObjectSchema)
|
||||
new ObjectSchema()
|
||||
.additionalProperties(arraySchema)
|
||||
.name("TypeMapSchema")
|
||||
.example(
|
||||
Map.of(
|
||||
"key1",
|
||||
List.of("value1", "value2"),
|
||||
"key2",
|
||||
List.of("value3", "value4")));
|
||||
|
||||
// Add the schema to the components
|
||||
var schemas = openApi.getComponents().getSchemas();
|
||||
schemas.put(mapSchema.getName(), mapSchema);
|
||||
};
|
||||
}
|
||||
}
|
|
@ -67,6 +67,13 @@ public class BootWebSecurityConfigurer {
|
|||
.requestMatchers("/css/**", "/img/**")
|
||||
.permitAll()
|
||||
.requestMatchers(HttpMethod.GET, "/docs/**")
|
||||
.permitAll()
|
||||
.requestMatchers(
|
||||
HttpMethod.GET,
|
||||
"/api-docs",
|
||||
"/api-docs/**",
|
||||
"/swagger-ui",
|
||||
"/swagger-ui/**")
|
||||
.permitAll())
|
||||
.cors(Customizer.withDefaults())
|
||||
.addFilter(jaasApiIntegrationFilter())
|
||||
|
|
|
@ -7,6 +7,7 @@ taskana.routing.dmn.upload.path=/tmp/routing.dmn
|
|||
spring.datasource.url=jdbc:h2:mem:taskana;NON_KEYWORDS=KEY,VALUE;IGNORECASE=TRUE;DB_CLOSE_ON_EXIT=FALSE;LOCK_MODE=0
|
||||
spring.datasource.driverClassName=org.h2.Driver
|
||||
spring.datasource.username=sa
|
||||
springdoc.api-docs.path=/api-docs
|
||||
spring.datasource.password=sa
|
||||
taskana.schemaName=TASKANA
|
||||
######## h2 console configuration ########
|
||||
|
@ -32,7 +33,7 @@ taskana.schemaName=TASKANA
|
|||
####### property that control rest api security deploy use true for no security.
|
||||
devMode=false
|
||||
# This property enables the support of XSRF tokens. This will not work together with devMode.
|
||||
enableCsrf=true
|
||||
enableCsrf=false
|
||||
####### property that control if the database is cleaned and sample data is generated
|
||||
generateSampleData=true
|
||||
####### cache static resources properties
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-rest-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-rest-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@ -59,6 +59,7 @@
|
|||
<artifactId>taskana-rest-spring-example-common</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springframework.plugin</groupId>
|
||||
<artifactId>spring-plugin-core</artifactId>
|
||||
|
@ -238,25 +239,6 @@
|
|||
</resources>
|
||||
</configuration>
|
||||
</execution>
|
||||
<execution>
|
||||
<id>copy-documentation-to-static-folder</id>
|
||||
<phase>prepare-package</phase>
|
||||
<goals>
|
||||
<goal>copy-resources</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<outputDirectory>
|
||||
${project.build.outputDirectory}/static/docs/rest
|
||||
</outputDirectory>
|
||||
<resources>
|
||||
<resource>
|
||||
<directory>
|
||||
../taskana-rest-spring/target/generated-docs
|
||||
</directory>
|
||||
</resource>
|
||||
</resources>
|
||||
</configuration>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
|
|
|
@ -22,7 +22,7 @@ import pro.taskana.workbasket.rest.models.WorkbasketSummaryRepresentationModel;
|
|||
@TaskanaSpringBootTest
|
||||
public class AbstractAccTest {
|
||||
|
||||
protected static final String DEPENDENCY_VERSION = "8.0.2-SNAPSHOT";
|
||||
protected static final String DEPENDENCY_VERSION = "8.1.1-SNAPSHOT";
|
||||
|
||||
private static final Logger LOGGER = LoggerFactory.getLogger(AbstractAccTest.class);
|
||||
|
||||
|
@ -77,7 +77,7 @@ public class AbstractAccTest {
|
|||
protected String parseServerLog() throws Exception {
|
||||
|
||||
// TO-DO: make log4j log into rollingFile from log4j.xml
|
||||
File file = new File("target/wildfly-27.0.1.Final/standalone/log/server.log");
|
||||
File file = new File("target/wildfly-31.0.1.Final/standalone/log/server.log");
|
||||
|
||||
BufferedReader br = new BufferedReader(new FileReader(file));
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<defaultProtocol type="Servlet 6.0"/>
|
||||
<container qualifier="wildfly" default="true">
|
||||
<configuration>
|
||||
<property name="jbossHome">target/wildfly-27.0.1.Final</property>
|
||||
<property name="jbossHome">target/wildfly-31.0.1.Final</property>
|
||||
<property name="serverConfig">int-test-standalone.xml</property>
|
||||
<!-- <property name="javaVmArguments">-->
|
||||
<!-- --add-exports=java.naming/com.sun.jndi.ldap=ALL-UNNAMED-->
|
||||
|
|
|
@ -36,7 +36,6 @@
|
|||
<extension module="org.wildfly.extension.metrics"/>
|
||||
<extension module="org.wildfly.extension.microprofile.config-smallrye"/>
|
||||
<extension module="org.wildfly.extension.microprofile.jwt-smallrye"/>
|
||||
<extension module="org.wildfly.extension.microprofile.opentracing-smallrye"/>
|
||||
<extension module="org.wildfly.extension.request-controller"/>
|
||||
<extension module="org.wildfly.extension.security.manager"/>
|
||||
<extension module="org.wildfly.extension.undertow"/>
|
||||
|
@ -92,6 +91,9 @@
|
|||
<logger category="com.arjuna">
|
||||
<level name="WARN"/>
|
||||
</logger>
|
||||
<logger category="com.networknt.schema">
|
||||
<level name="WARN"/>
|
||||
</logger>
|
||||
<logger category="io.jaegertracing.Configuration">
|
||||
<level name="WARN"/>
|
||||
</logger>
|
||||
|
@ -171,6 +173,7 @@
|
|||
<subsystem xmlns="urn:jboss:domain:batch-jberet:3.0">
|
||||
<default-job-repository name="in-memory"/>
|
||||
<default-thread-pool name="batch"/>
|
||||
<security-domain name="ApplicationDomain"/>
|
||||
<job-repository name="in-memory">
|
||||
<in-memory/>
|
||||
</job-repository>
|
||||
|
@ -181,20 +184,17 @@
|
|||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:bean-validation:1.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:core-management:1.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:datasources:7.0">
|
||||
<subsystem xmlns="urn:jboss:domain:datasources:7.1">
|
||||
<datasources>
|
||||
<datasource
|
||||
jndi-name="java:jboss/datasources/ExampleDS"
|
||||
pool-name="ExampleDS" enabled="true"
|
||||
use-java-context="true">
|
||||
<connection-url>
|
||||
jdbc:h2:mem:test;DB_CLOSE_DELAY=-1;DB_CLOSE_ON_EXIT=FALSE;
|
||||
jdbc:h2:mem:test;DB_CLOSE_DELAY=-1;DB_CLOSE_ON_EXIT=FALSE;MODE=${wildfly.h2.compatibility.mode:REGULAR}
|
||||
</connection-url>
|
||||
<driver>h2</driver>
|
||||
<security>
|
||||
<user-name>sa</user-name>
|
||||
<password>sa</password>
|
||||
</security>
|
||||
<security user-name="sa" password="sa"/>
|
||||
</datasource>
|
||||
<datasource jta="true"
|
||||
jndi-name="java:jboss/datasources/TaskanaDS"
|
||||
|
@ -206,10 +206,7 @@
|
|||
</connection-url>
|
||||
<driver-class>org.postgresql.Driver</driver-class>
|
||||
<driver>postgresql</driver>
|
||||
<security>
|
||||
<user-name>postgres</user-name>
|
||||
<password>postgres</password>
|
||||
</security>
|
||||
<security user-name="postgres" password="postgres"/>
|
||||
<validation>
|
||||
<background-validation>false
|
||||
</background-validation>
|
||||
|
@ -241,7 +238,7 @@
|
|||
<infinispan-timer-management name="transient" cache-container="ejb" cache="transient"
|
||||
max-active-timers="10000"/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:distributable-web:3.0" default-session-management="default"
|
||||
<subsystem xmlns="urn:jboss:domain:distributable-web:4.0" default-session-management="default"
|
||||
default-single-sign-on-management="default">
|
||||
<infinispan-session-management name="default" cache-container="web" granularity="SESSION">
|
||||
<local-affinity/>
|
||||
|
@ -253,8 +250,7 @@
|
|||
<spec-descriptor-property-replacement>false</spec-descriptor-property-replacement>
|
||||
<concurrent>
|
||||
<context-services>
|
||||
<context-service name="default" jndi-name="java:jboss/ee/concurrency/context/default"
|
||||
use-transaction-setup-provider="true"/>
|
||||
<context-service name="default" jndi-name="java:jboss/ee/concurrency/context/default" />
|
||||
</context-services>
|
||||
<managed-thread-factories>
|
||||
<managed-thread-factory name="default"
|
||||
|
@ -337,7 +333,7 @@
|
|||
<statistics enabled="${wildfly.ejb3.statistics-enabled:${wildfly.statistics-enabled:false}}"/>
|
||||
<log-system-exceptions value="true"/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:wildfly:elytron:16.0" final-providers="combined-providers"
|
||||
<subsystem xmlns="urn:wildfly:elytron:18.0" final-providers="combined-providers"
|
||||
disallowed-providers="OracleUcrypto">
|
||||
<providers>
|
||||
<aggregate-providers name="combined-providers">
|
||||
|
@ -352,16 +348,16 @@
|
|||
format="JSON"/>
|
||||
</audit-logging>
|
||||
<security-domains>
|
||||
<security-domain name="ManagementDomain" default-realm="ManagementRealm"
|
||||
permission-mapper="default-permission-mapper">
|
||||
<realm name="ManagementRealm" role-decoder="groups-to-roles"/>
|
||||
<realm name="local" role-mapper="super-user-mapper"/>
|
||||
</security-domain>
|
||||
<security-domain name="ApplicationDomain" default-realm="ApplicationRealm"
|
||||
permission-mapper="default-permission-mapper">
|
||||
<realm name="ApplicationRealm" role-decoder="groups-to-roles"/>
|
||||
<realm name="local"/>
|
||||
</security-domain>
|
||||
<security-domain name="ManagementDomain" default-realm="ManagementRealm"
|
||||
permission-mapper="default-permission-mapper">
|
||||
<realm name="ManagementRealm" role-decoder="groups-to-roles"/>
|
||||
<realm name="local" role-mapper="super-user-mapper"/>
|
||||
</security-domain>
|
||||
<security-domain name="taskanaLdapSD"
|
||||
default-realm="taskanaLR"
|
||||
permission-mapper="default-permission-mapper">
|
||||
|
@ -422,15 +418,24 @@
|
|||
<permission class-name="org.wildfly.security.auth.permission.LoginPermission"/>
|
||||
</permission-set>
|
||||
<permission-set name="default-permissions">
|
||||
<permission class-name="org.wildfly.extension.batch.jberet.deployment.BatchPermission"
|
||||
module="org.wildfly.extension.batch.jberet" target-name="*"/>
|
||||
<permission class-name="org.wildfly.transaction.client.RemoteTransactionPermission"
|
||||
module="org.wildfly.transaction.client"/>
|
||||
<permission class-name="org.jboss.ejb.client.RemoteEJBPermission"
|
||||
module="org.jboss.ejb-client"/>
|
||||
<permission class-name="org.wildfly.extension.batch.jberet.deployment.BatchPermission"
|
||||
module="org.wildfly.extension.batch.jberet" target-name="*"/>
|
||||
</permission-set>
|
||||
</permission-sets>
|
||||
<http>
|
||||
<http-authentication-factory name="application-http-authentication"
|
||||
security-domain="ApplicationDomain"
|
||||
http-server-mechanism-factory="global">
|
||||
<mechanism-configuration>
|
||||
<mechanism mechanism-name="BASIC">
|
||||
<mechanism-realm realm-name="ApplicationRealm"/>
|
||||
</mechanism>
|
||||
</mechanism-configuration>
|
||||
</http-authentication-factory>
|
||||
<http-authentication-factory name="management-http-authentication"
|
||||
security-domain="ManagementDomain"
|
||||
http-server-mechanism-factory="global">
|
||||
|
@ -440,6 +445,7 @@
|
|||
</mechanism>
|
||||
</mechanism-configuration>
|
||||
</http-authentication-factory>
|
||||
<provider-http-server-mechanism-factory name="global"/>
|
||||
<http-authentication-factory
|
||||
name="taskana-ldap-http-auth"
|
||||
security-domain="taskanaLdapSD"
|
||||
|
@ -451,19 +457,8 @@
|
|||
</mechanism>
|
||||
</mechanism-configuration>
|
||||
</http-authentication-factory>
|
||||
<provider-http-server-mechanism-factory name="global"/>
|
||||
</http>
|
||||
<sasl>
|
||||
<sasl-authentication-factory name="management-sasl-authentication"
|
||||
sasl-server-factory="configured"
|
||||
security-domain="ManagementDomain">
|
||||
<mechanism-configuration>
|
||||
<mechanism mechanism-name="JBOSS-LOCAL-USER" realm-mapper="local"/>
|
||||
<mechanism mechanism-name="DIGEST-MD5">
|
||||
<mechanism-realm realm-name="ManagementRealm"/>
|
||||
</mechanism>
|
||||
</mechanism-configuration>
|
||||
</sasl-authentication-factory>
|
||||
<sasl-authentication-factory name="application-sasl-authentication"
|
||||
sasl-server-factory="configured"
|
||||
security-domain="ApplicationDomain">
|
||||
|
@ -474,6 +469,16 @@
|
|||
</mechanism>
|
||||
</mechanism-configuration>
|
||||
</sasl-authentication-factory>
|
||||
<sasl-authentication-factory name="management-sasl-authentication"
|
||||
sasl-server-factory="configured"
|
||||
security-domain="ManagementDomain">
|
||||
<mechanism-configuration>
|
||||
<mechanism mechanism-name="JBOSS-LOCAL-USER" realm-mapper="local"/>
|
||||
<mechanism mechanism-name="DIGEST-MD5">
|
||||
<mechanism-realm realm-name="ManagementRealm"/>
|
||||
</mechanism>
|
||||
</mechanism-configuration>
|
||||
</sasl-authentication-factory>
|
||||
<configurable-sasl-server-factory name="configured" sasl-server-factory="elytron">
|
||||
<properties>
|
||||
<property name="wildfly.sasl.local-user.default-user" value="$local"/>
|
||||
|
@ -514,8 +519,11 @@
|
|||
<server-ssl-context name="applicationSSC" key-manager="applicationKM"/>
|
||||
</server-ssl-contexts>
|
||||
</tls>
|
||||
<policy name="jacc">
|
||||
<jacc-policy/>
|
||||
</policy>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:wildfly:elytron-oidc-client:1.0"/>
|
||||
<subsystem xmlns="urn:wildfly:elytron-oidc-client:2.0"/>
|
||||
<subsystem xmlns="urn:wildfly:health:1.0" security-enabled="false"/>
|
||||
<subsystem xmlns="urn:jboss:domain:iiop-openjdk:3.0">
|
||||
<orb socket-binding="iiop"/>
|
||||
|
@ -523,6 +531,22 @@
|
|||
<security server-requires-ssl="false" client-requires-ssl="false"/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:infinispan:14.0">
|
||||
<cache-container name="hibernate" marshaller="JBOSS" modules="org.infinispan.hibernate-cache">
|
||||
<local-cache name="entity">
|
||||
<heap-memory size="10000"/>
|
||||
<expiration max-idle="100000"/>
|
||||
</local-cache>
|
||||
<local-cache name="local-query">
|
||||
<heap-memory size="10000"/>
|
||||
<expiration max-idle="100000"/>
|
||||
</local-cache>
|
||||
<local-cache name="timestamps">
|
||||
<expiration interval="0"/>
|
||||
</local-cache>
|
||||
<local-cache name="pending-puts">
|
||||
<expiration max-idle="60000"/>
|
||||
</local-cache>
|
||||
</cache-container>
|
||||
<cache-container name="ejb" default-cache="passivation" marshaller="PROTOSTREAM"
|
||||
aliases="sfsb" modules="org.wildfly.clustering.ejb.infinispan">
|
||||
<local-cache name="passivation">
|
||||
|
@ -552,33 +576,11 @@
|
|||
<expiration interval="0"/>
|
||||
</local-cache>
|
||||
</cache-container>
|
||||
<cache-container name="server" default-cache="default" marshaller="PROTOSTREAM"
|
||||
modules="org.wildfly.clustering.singleton.server">
|
||||
<local-cache name="default">
|
||||
<expiration interval="0"/>
|
||||
</local-cache>
|
||||
</cache-container>
|
||||
<cache-container name="hibernate" marshaller="JBOSS" modules="org.infinispan.hibernate-cache">
|
||||
<local-cache name="entity">
|
||||
<heap-memory size="10000"/>
|
||||
<expiration max-idle="100000"/>
|
||||
</local-cache>
|
||||
<local-cache name="local-query">
|
||||
<heap-memory size="10000"/>
|
||||
<expiration max-idle="100000"/>
|
||||
</local-cache>
|
||||
<local-cache name="timestamps">
|
||||
<expiration interval="0"/>
|
||||
</local-cache>
|
||||
<local-cache name="pending-puts">
|
||||
<expiration max-idle="60000"/>
|
||||
</local-cache>
|
||||
</cache-container>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:io:3.0">
|
||||
<worker name="default"/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:jaxrs:2.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:jaxrs:3.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:jca:6.0">
|
||||
<archive-validation enabled="true" fail-on-error="true" fail-on-warn="false"/>
|
||||
<bean-validation enabled="true"/>
|
||||
|
@ -613,7 +615,7 @@
|
|||
<smtp-server outbound-socket-binding-ref="mail-smtp"/>
|
||||
</mail-session>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:messaging-activemq:14.0">
|
||||
<subsystem xmlns="urn:jboss:domain:messaging-activemq:16.0">
|
||||
<server name="default">
|
||||
<security elytron-domain="ApplicationDomain"/>
|
||||
<statistics
|
||||
|
@ -657,21 +659,17 @@
|
|||
prefix="${wildfly.metrics.prefix:wildfly}"/>
|
||||
<subsystem xmlns="urn:wildfly:microprofile-config-smallrye:2.0"/>
|
||||
<subsystem xmlns="urn:wildfly:microprofile-jwt-smallrye:1.0"/>
|
||||
<subsystem xmlns="urn:wildfly:microprofile-opentracing-smallrye:3.0" default-tracer="jaeger">
|
||||
<jaeger-tracer name="jaeger">
|
||||
<sampler-configuration sampler-type="const" sampler-param="1.0"/>
|
||||
</jaeger-tracer>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:naming:2.0">
|
||||
<remote-naming/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:pojo:1.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:remoting:5.0">
|
||||
<subsystem xmlns="urn:jboss:domain:remoting:6.0">
|
||||
<endpoint worker="default"/>
|
||||
<http-connector name="http-remoting-connector" connector-ref="default"
|
||||
sasl-authentication-factory="application-sasl-authentication"/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:request-controller:1.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:resource-adapters:6.1"/>
|
||||
<subsystem xmlns="urn:jboss:domain:resource-adapters:7.1"/>
|
||||
<subsystem xmlns="urn:jboss:domain:sar:1.0"/>
|
||||
<subsystem xmlns="urn:jboss:domain:security-manager:1.0">
|
||||
<deployment-permissions>
|
||||
|
@ -692,10 +690,10 @@
|
|||
statistics-enabled="${wildfly.transactions.statistics-enabled:${wildfly.statistics-enabled:false}}"/>
|
||||
<object-store path="tx-object-store" relative-to="jboss.server.data.dir"/>
|
||||
</subsystem>
|
||||
<subsystem xmlns="urn:jboss:domain:undertow:13.0" default-server="default-server"
|
||||
default-virtual-host="default-host" default-servlet-container="default"
|
||||
default-security-domain="other"
|
||||
statistics-enabled="${wildfly.undertow.statistics-enabled:${wildfly.statistics-enabled:false}}">
|
||||
<subsystem xmlns="urn:jboss:domain:undertow:14.0" default-virtual-host="default-host"
|
||||
default-servlet-container="default" default-server="default-server"
|
||||
statistics-enabled="${wildfly.undertow.statistics-enabled:${wildfly.statistics-enabled:false}}"
|
||||
default-security-domain="other">
|
||||
<byte-buffer-pool name="default"/>
|
||||
<buffer-cache name="default"/>
|
||||
<server name="default-server">
|
||||
|
@ -705,6 +703,7 @@
|
|||
enable-http2="true"/>
|
||||
<host name="default-host" alias="localhost">
|
||||
<location name="/" handler="welcome-content"/>
|
||||
<http-invoker http-authentication-factory="application-http-authentication"/>
|
||||
</host>
|
||||
</server>
|
||||
<servlet-container name="default">
|
||||
|
@ -714,13 +713,6 @@
|
|||
<handlers>
|
||||
<file name="welcome-content" path="${jboss.home.dir}/welcome-content"/>
|
||||
</handlers>
|
||||
<filters>
|
||||
<response-header name="server-header"
|
||||
header-name="Server" header-value="WildFly/27"/>
|
||||
<response-header
|
||||
name="x-powered-by-header"
|
||||
header-name="X-Powered-By" header-value="Undertow/12"/>
|
||||
</filters>
|
||||
<application-security-domains>
|
||||
<application-security-domain
|
||||
name="taskanaApplicationDomain"
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<module name="org.postgresql.postgresql" xmlns="urn:jboss:module:1.9">
|
||||
|
||||
<resources>
|
||||
<resource-root path="postgresql-42.6.0.jar"/>
|
||||
<resource-root path="postgresql-42.6.2.jar"/>
|
||||
</resources>
|
||||
|
||||
<!-- don't know why it is still javax, but this is the only way how the postgresql module is loaded -->
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-rest-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -7,10 +7,10 @@ import java.util.Map;
|
|||
import java.util.function.Function;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.boot.web.servlet.FilterRegistrationBean;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
import org.springframework.context.annotation.Primary;
|
||||
import org.springframework.core.annotation.Order;
|
||||
import org.springframework.ldap.core.support.BaseLdapPathContextSource;
|
||||
import org.springframework.security.authentication.AuthenticationManager;
|
||||
import org.springframework.security.config.annotation.web.builders.HttpSecurity;
|
||||
|
@ -62,7 +62,8 @@ public class TestWebSecurityConfig {
|
|||
}
|
||||
|
||||
@Bean
|
||||
public FilterRegistrationBean<CorsFilter> corsFilter() {
|
||||
@Order(0)
|
||||
public CorsFilter corsFilter() {
|
||||
final UrlBasedCorsConfigurationSource source = new UrlBasedCorsConfigurationSource();
|
||||
CorsConfiguration config = new CorsConfiguration();
|
||||
config.setAllowCredentials(true);
|
||||
|
@ -70,9 +71,7 @@ public class TestWebSecurityConfig {
|
|||
config.addAllowedHeader("*");
|
||||
config.addAllowedMethod("*");
|
||||
source.registerCorsConfiguration("/**", config);
|
||||
FilterRegistrationBean<CorsFilter> bean = new FilterRegistrationBean<>(new CorsFilter(source));
|
||||
bean.setOrder(0);
|
||||
return bean;
|
||||
return new CorsFilter(source);
|
||||
}
|
||||
|
||||
@Bean
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
<parent>
|
||||
<groupId>pro.taskana</groupId>
|
||||
<artifactId>taskana-rest-parent</artifactId>
|
||||
<version>8.0.2-SNAPSHOT</version>
|
||||
<version>8.1.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@ -78,7 +78,11 @@
|
|||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-autoconfigure</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springdoc</groupId>
|
||||
<artifactId>springdoc-openapi-starter-webmvc-ui</artifactId>
|
||||
<version>${version.spring-openapi}</version>
|
||||
</dependency>
|
||||
<!-- test dependencies -->
|
||||
<dependency>
|
||||
<groupId>pro.taskana</groupId>
|
||||
|
@ -134,11 +138,6 @@
|
|||
<artifactId>spring-security-test</artifactId>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework.restdocs</groupId>
|
||||
<artifactId>spring-restdocs-mockmvc</artifactId>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.bytebuddy</groupId>
|
||||
<artifactId>byte-buddy</artifactId>
|
||||
|
@ -154,12 +153,6 @@
|
|||
<artifactId>h2</artifactId>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>capital.scalable</groupId>
|
||||
<artifactId>spring-auto-restdocs-core</artifactId>
|
||||
<version>${version.auto-restdocs}</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-validation</artifactId>
|
||||
|
@ -194,65 +187,6 @@
|
|||
</tag>
|
||||
</tags>
|
||||
</configuration>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>generate-javadoc-json</id>
|
||||
<phase>validate</phase>
|
||||
<goals>
|
||||
<goal>javadoc-no-fork</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<doclet>capital.scalable.restdocs.jsondoclet.ExtractDocumentationAsJsonDoclet</doclet>
|
||||
<docletArtifact>
|
||||
<groupId>capital.scalable</groupId>
|
||||
<!--
|
||||
currently the jdk9+ version of this doclet has a very bad bug.
|
||||
see: https://github.com/ScaCap/spring-auto-restdocs/issues/412
|
||||
-->
|
||||
<artifactId>spring-auto-restdocs-json-doclet-jdk9</artifactId>
|
||||
<version>${version.auto-restdocs}</version>
|
||||
</docletArtifact>
|
||||
<destDir>generated-javadoc-json</destDir>
|
||||
<reportOutputDirectory>${project.build.directory}</reportOutputDirectory>
|
||||
<useStandardDocletOptions>false</useStandardDocletOptions>
|
||||
<show>package</show>
|
||||
</configuration>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.asciidoctor</groupId>
|
||||
<artifactId>asciidoctor-maven-plugin</artifactId>
|
||||
<version>${version.maven.asciidoctor}</version>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>generate-docs</id>
|
||||
<phase>prepare-package</phase>
|
||||
<goals>
|
||||
<goal>process-asciidoc</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
<configuration>
|
||||
<backend>html5</backend>
|
||||
<doctype>book</doctype>
|
||||
<attributes>
|
||||
<snippets>${project.build.directory}/generated-snippets</snippets>
|
||||
<doctype>book</doctype>
|
||||
<icons>font</icons>
|
||||
<source-highlighter>highlightjs</source-highlighter>
|
||||
<toc>left</toc>
|
||||
<docinfo>shared</docinfo>
|
||||
<toclevels>4</toclevels>
|
||||
<sectlinks/>
|
||||
</attributes>
|
||||
<logHandler>
|
||||
<outputToConsole>false</outputToConsole>
|
||||
<failIf>
|
||||
<severity>ERROR</severity>
|
||||
</failIf>
|
||||
</logHandler>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
|
|
@ -1,9 +1,16 @@
|
|||
package pro.taskana.classification.rest;
|
||||
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.media.Content;
|
||||
import io.swagger.v3.oas.annotations.media.ExampleObject;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||
import jakarta.servlet.http.HttpServletRequest;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.List;
|
||||
import java.util.function.BiConsumer;
|
||||
import org.springdoc.core.annotations.ParameterObject;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.hateoas.MediaTypes;
|
||||
import org.springframework.hateoas.config.EnableHypermediaSupport;
|
||||
|
@ -71,13 +78,29 @@ public class ClassificationController {
|
|||
* @param pagingParameter the paging parameters
|
||||
* @return the classifications with the given filter, sort and paging options.
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Get a list of all Classifications",
|
||||
description =
|
||||
"This endpoint retrieves a list of existing Classifications. Filters can be applied.",
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the classifications with the given filter, sort and paging options.",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema =
|
||||
@Schema(implementation = ClassificationSummaryPagedRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_CLASSIFICATIONS)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<ClassificationSummaryPagedRepresentationModel> getClassifications(
|
||||
HttpServletRequest request,
|
||||
final ClassificationQueryFilterParameter filterParameter,
|
||||
final ClassificationQuerySortParameter sortParameter,
|
||||
final QueryPagingParameter<ClassificationSummary, ClassificationQuery> pagingParameter) {
|
||||
@ParameterObject final ClassificationQueryFilterParameter filterParameter,
|
||||
@ParameterObject final ClassificationQuerySortParameter sortParameter,
|
||||
@ParameterObject
|
||||
final QueryPagingParameter<ClassificationSummary, ClassificationQuery> pagingParameter) {
|
||||
|
||||
QueryParamsValidator.validateParams(
|
||||
request,
|
||||
|
@ -103,10 +126,31 @@ public class ClassificationController {
|
|||
* @throws ClassificationNotFoundException if the requested classification is not found.
|
||||
* @title Get a single Classification
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Get a single Classification",
|
||||
description = "This endpoint retrieves a single Classification.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "classificationId",
|
||||
description = "the Id of the requested Classification.",
|
||||
example = "CLI:100000000000000000000000000000000009",
|
||||
required = true)
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the requested classification",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = ClassificationRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_CLASSIFICATIONS_ID, produces = MediaTypes.HAL_JSON_VALUE)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<ClassificationRepresentationModel> getClassification(
|
||||
@PathVariable String classificationId) throws ClassificationNotFoundException {
|
||||
@PathVariable("classificationId") String classificationId)
|
||||
throws ClassificationNotFoundException {
|
||||
Classification classification = classificationService.getClassification(classificationId);
|
||||
return ResponseEntity.ok(modelAssembler.toModel(classification));
|
||||
}
|
||||
|
@ -126,6 +170,35 @@ public class ClassificationController {
|
|||
* @throws MalformedServiceLevelException if the {@code serviceLevel} property does not comply *
|
||||
* with the ISO 8601 specification
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Create a new Classification",
|
||||
description = "This endpoint creates a new Classification.",
|
||||
requestBody =
|
||||
@io.swagger.v3.oas.annotations.parameters.RequestBody(
|
||||
description = "the Classification which should be created.",
|
||||
content =
|
||||
@Content(
|
||||
schema = @Schema(implementation = ClassificationRepresentationModel.class),
|
||||
examples =
|
||||
@ExampleObject(
|
||||
value =
|
||||
"{\n"
|
||||
+ " \"key\" : \"Key0815casdgdgh\",\n"
|
||||
+ " \"domain\" : \"DOMAIN_B\",\n"
|
||||
+ " \"priority\" : 0,\n"
|
||||
+ " \"serviceLevel\" : \"P1D\",\n"
|
||||
+ " \"type\" : \"TASK\"\n"
|
||||
+ "}"))),
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "201",
|
||||
description = "The inserted Classification",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = ClassificationRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@PostMapping(path = RestEndpoints.URL_CLASSIFICATIONS)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<ClassificationRepresentationModel> createClassification(
|
||||
|
@ -156,10 +229,65 @@ public class ClassificationController {
|
|||
* @throws MalformedServiceLevelException if the {@code serviceLevel} property does not comply *
|
||||
* with the ISO 8601 specification
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Update a Classification",
|
||||
description = "This endpoint updates a Classification.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "classificationId",
|
||||
description = "the Id of the Classification which should be updated.",
|
||||
example = "CLI:100000000000000000000000000000000009",
|
||||
required = true)
|
||||
},
|
||||
requestBody =
|
||||
@io.swagger.v3.oas.annotations.parameters.RequestBody(
|
||||
description = "the new Classification for the requested id.",
|
||||
content =
|
||||
@Content(
|
||||
schema = @Schema(implementation = ClassificationRepresentationModel.class),
|
||||
examples =
|
||||
@ExampleObject(
|
||||
value =
|
||||
"{\n"
|
||||
+ " \"classificationId\" : "
|
||||
+ "\"CLI:100000000000000000000000000000000009\",\n"
|
||||
+ " \"key\" : \"L140101\",\n"
|
||||
+ " \"applicationEntryPoint\" : \"\",\n"
|
||||
+ " \"category\" : \"EXTERNAL\",\n"
|
||||
+ " \"domain\" : \"DOMAIN_A\",\n"
|
||||
+ " \"name\" : \"new name\",\n"
|
||||
+ " \"parentId\" : \"\",\n"
|
||||
+ " \"parentKey\" : \"\",\n"
|
||||
+ " \"priority\" : 2,\n"
|
||||
+ " \"serviceLevel\" : \"P2D\",\n"
|
||||
+ " \"type\" : \"TASK\",\n"
|
||||
+ " \"custom1\" : \"VNR\",\n"
|
||||
+ " \"custom2\" : \"\",\n"
|
||||
+ " \"custom3\" : \"\",\n"
|
||||
+ " \"custom4\" : \"\",\n"
|
||||
+ " \"custom5\" : \"\",\n"
|
||||
+ " \"custom6\" : \"\",\n"
|
||||
+ " \"custom7\" : \"\",\n"
|
||||
+ " \"custom8\" : \"\",\n"
|
||||
+ " \"isValidInDomain\" : true,\n"
|
||||
+ " \"created\" : \"2018-02-01T12:00:00.000Z\",\n"
|
||||
+ " \"modified\" : \"2018-02-01T12:00:00.000Z\",\n"
|
||||
+ " \"description\" : \"Zustimmungserklärung\"\n"
|
||||
+ "}"))),
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the updated Classification",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = ClassificationRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@PutMapping(path = RestEndpoints.URL_CLASSIFICATIONS_ID)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<ClassificationRepresentationModel> updateClassification(
|
||||
@PathVariable(value = "classificationId") String classificationId,
|
||||
@PathVariable("classificationId") String classificationId,
|
||||
@RequestBody ClassificationRepresentationModel resource)
|
||||
throws ClassificationNotFoundException,
|
||||
ConcurrencyException,
|
||||
|
@ -190,10 +318,25 @@ public class ClassificationController {
|
|||
* Classification
|
||||
* @throws NotAuthorizedException if the user is not authorized to delete a Classification
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Delete a Classification",
|
||||
description = "This endpoint deletes a requested Classification if possible.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "classificationId",
|
||||
description = "the requested Classification Id which should be deleted",
|
||||
example = "CLI:100000000000000000000000000000000010",
|
||||
required = true)
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "204",
|
||||
content = {@Content(schema = @Schema())})
|
||||
})
|
||||
@DeleteMapping(path = RestEndpoints.URL_CLASSIFICATIONS_ID)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<ClassificationRepresentationModel> deleteClassification(
|
||||
@PathVariable String classificationId)
|
||||
@PathVariable("classificationId") String classificationId)
|
||||
throws ClassificationNotFoundException, ClassificationInUseException, NotAuthorizedException {
|
||||
classificationService.deleteClassification(classificationId);
|
||||
return ResponseEntity.noContent().build();
|
||||
|
|
|
@ -3,6 +3,11 @@ package pro.taskana.classification.rest;
|
|||
import static pro.taskana.common.internal.util.CheckedFunction.wrap;
|
||||
|
||||
import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.media.Content;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||
import java.io.IOException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
|
@ -13,7 +18,9 @@ import java.util.Map;
|
|||
import java.util.Set;
|
||||
import java.util.stream.Collectors;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.hateoas.MediaTypes;
|
||||
import org.springframework.hateoas.config.EnableHypermediaSupport;
|
||||
import org.springframework.http.MediaType;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
|
@ -65,10 +72,26 @@ public class ClassificationDefinitionController {
|
|||
* @param domain Filter the export by domain
|
||||
* @return the configured Classifications.
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Export Classifications",
|
||||
description = "This endpoint exports all configured Classifications.",
|
||||
parameters = {@Parameter(name = "domain", description = "Filter the export by domain")},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the configured Classifications.",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema =
|
||||
@Schema(
|
||||
implementation =
|
||||
ClassificationDefinitionCollectionRepresentationModel.class)))
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_CLASSIFICATION_DEFINITIONS)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<ClassificationDefinitionCollectionRepresentationModel>
|
||||
exportClassifications(@RequestParam(required = false) String[] domain) {
|
||||
exportClassifications(@RequestParam(value = "domain", required = false) String[] domain) {
|
||||
ClassificationQuery query = classificationService.createClassificationQuery();
|
||||
|
||||
List<ClassificationSummary> summaries =
|
||||
|
@ -102,7 +125,28 @@ public class ClassificationDefinitionController {
|
|||
* @throws MalformedServiceLevelException if the {@code serviceLevel} property does not comply *
|
||||
* with the ISO 8601 specification
|
||||
*/
|
||||
@PostMapping(path = RestEndpoints.URL_CLASSIFICATION_DEFINITIONS)
|
||||
@Operation(
|
||||
summary = "Import Classifications",
|
||||
description =
|
||||
"This endpoint imports all Classifications. Existing Classifications will not be removed."
|
||||
+ " Existing Classifications with the same key/domain will be overridden.",
|
||||
requestBody =
|
||||
@io.swagger.v3.oas.annotations.parameters.RequestBody(
|
||||
description =
|
||||
"the file containing the Classifications which should be imported. To get an "
|
||||
+ "example file containing the Classificatioins, go to the "
|
||||
+ "[TASKANA UI](http://localhost:8080/taskana/index.html) and export the "
|
||||
+ "Classifications",
|
||||
required = true,
|
||||
content = @Content(mediaType = MediaType.MULTIPART_FORM_DATA_VALUE)),
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "204",
|
||||
content = {@Content(schema = @Schema())})
|
||||
})
|
||||
@PostMapping(
|
||||
path = RestEndpoints.URL_CLASSIFICATION_DEFINITIONS,
|
||||
consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<Void> importClassifications(@RequestParam("file") MultipartFile file)
|
||||
throws InvalidArgumentException,
|
||||
|
|
|
@ -4,6 +4,7 @@ import static pro.taskana.common.api.SharedConstants.MASTER_DOMAIN;
|
|||
import static pro.taskana.common.internal.util.CheckedConsumer.wrap;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.Optional;
|
||||
import java.util.stream.Stream;
|
||||
|
@ -15,7 +16,66 @@ import pro.taskana.common.rest.QueryParameter;
|
|||
public class ClassificationQueryFilterParameter
|
||||
implements QueryParameter<ClassificationQuery, Void> {
|
||||
|
||||
public String[] getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public String[] getNameLike() {
|
||||
return nameLike;
|
||||
}
|
||||
|
||||
public String[] getKey() {
|
||||
return key;
|
||||
}
|
||||
|
||||
public String[] getCategory() {
|
||||
return category;
|
||||
}
|
||||
|
||||
public String[] getDomain() {
|
||||
return domain;
|
||||
}
|
||||
|
||||
public String[] getType() {
|
||||
return type;
|
||||
}
|
||||
|
||||
public String[] getCustom1Like() {
|
||||
return custom1Like;
|
||||
}
|
||||
|
||||
public String[] getCustom2Like() {
|
||||
return custom2Like;
|
||||
}
|
||||
|
||||
public String[] getCustom3Like() {
|
||||
return custom3Like;
|
||||
}
|
||||
|
||||
public String[] getCustom4Like() {
|
||||
return custom4Like;
|
||||
}
|
||||
|
||||
public String[] getCustom5Like() {
|
||||
return custom5Like;
|
||||
}
|
||||
|
||||
public String[] getCustom6Like() {
|
||||
return custom6Like;
|
||||
}
|
||||
|
||||
public String[] getCustom7Like() {
|
||||
return custom7Like;
|
||||
}
|
||||
|
||||
public String[] getCustom8Like() {
|
||||
return custom8Like;
|
||||
}
|
||||
|
||||
/** Filter by the name of the Classification. This is an exact match. */
|
||||
@Schema(
|
||||
name = "name",
|
||||
description = "Filter by the name of the Classification. This is an exact match.")
|
||||
@JsonProperty("name")
|
||||
private final String[] name;
|
||||
|
||||
|
@ -24,22 +84,40 @@ public class ClassificationQueryFilterParameter
|
|||
* the beginning and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "name-like",
|
||||
description =
|
||||
"Filter by the name of the Classification. This results in a substring search. (% is "
|
||||
+ "appended to the beginning and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("name-like")
|
||||
private final String[] nameLike;
|
||||
|
||||
/** Filter by the key of the Classification. This is an exact match. */
|
||||
@Schema(
|
||||
name = "key",
|
||||
description = "Filter by the key of the Classification. This is an exact match.")
|
||||
@JsonProperty("key")
|
||||
private final String[] key;
|
||||
|
||||
/** Filter by the category of the Classification. This is an exact match. */
|
||||
@Schema(
|
||||
name = "category",
|
||||
description = "Filter by the category of the Classification. This is an exact match.")
|
||||
@JsonProperty("category")
|
||||
private final String[] category;
|
||||
|
||||
/** Filter by the domain of the Classification. This is an exact match. */
|
||||
@Schema(
|
||||
name = "domain",
|
||||
description = "Filter by the domain of the Classification. This is an exact match.")
|
||||
@JsonProperty("domain")
|
||||
private final String[] domain;
|
||||
|
||||
/** Filter by the type of the Classification. This is an exact match. */
|
||||
@Schema(
|
||||
name = "type",
|
||||
description = "Filter by the type of the Classification. This is an exact match.")
|
||||
@JsonProperty("type")
|
||||
private final String[] type;
|
||||
|
||||
|
@ -48,6 +126,12 @@ public class ClassificationQueryFilterParameter
|
|||
* to the beginning and end of the requested value). Further SQL "LIKE" wildcard characters will
|
||||
* be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-1-like",
|
||||
description =
|
||||
"Filter by the value of the field custom1. This results in a substring search.. (% is "
|
||||
+ "appended to the beginning and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-1-like")
|
||||
private final String[] custom1Like;
|
||||
|
||||
|
@ -56,6 +140,12 @@ public class ClassificationQueryFilterParameter
|
|||
* to the beginning and end of the requested value). Further SQL "LIKE" wildcard characters will
|
||||
* be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-2-like",
|
||||
description =
|
||||
"Filter by the value of the field custom2. This results in a substring search.. (% is "
|
||||
+ "appended to the beginning and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-2-like")
|
||||
private final String[] custom2Like;
|
||||
|
||||
|
@ -64,6 +154,12 @@ public class ClassificationQueryFilterParameter
|
|||
* to the beginning and end of the requested value). Further SQL "LIKE" wildcard characters will
|
||||
* be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-3-like",
|
||||
description =
|
||||
"Filter by the value of the field custom3. This results in a substring search.. (% is "
|
||||
+ "appended to the beginning and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-3-like")
|
||||
private final String[] custom3Like;
|
||||
|
||||
|
@ -72,6 +168,12 @@ public class ClassificationQueryFilterParameter
|
|||
* to the beginning and end of the requested value). Further SQL "LIKE" wildcard characters will
|
||||
* be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-4-like",
|
||||
description =
|
||||
"Filter by the value of the field custom4. This results in a substring search.. (% is "
|
||||
+ "appended to the beginning and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-4-like")
|
||||
private final String[] custom4Like;
|
||||
|
||||
|
@ -80,6 +182,12 @@ public class ClassificationQueryFilterParameter
|
|||
* to the beginning and end of the requested value). Further SQL "LIKE" wildcard characters will
|
||||
* be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-5-like",
|
||||
description =
|
||||
"Filter by the value of the field custom5. This results in a substring search.. (% is "
|
||||
+ "appended to the beginning and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-5-like")
|
||||
private final String[] custom5Like;
|
||||
|
||||
|
@ -88,6 +196,12 @@ public class ClassificationQueryFilterParameter
|
|||
* to the beginning and end of the requested value). Further SQL "LIKE" wildcard characters will
|
||||
* be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-6-like",
|
||||
description =
|
||||
"Filter by the value of the field custom6. This results in a substring search.. (% is "
|
||||
+ "appended to the beginning and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-6-like")
|
||||
private final String[] custom6Like;
|
||||
/**
|
||||
|
@ -95,6 +209,12 @@ public class ClassificationQueryFilterParameter
|
|||
* to the beginning and end of the requested value). Further SQL "LIKE" wildcard characters will
|
||||
* be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-7-like",
|
||||
description =
|
||||
"Filter by the value of the field custom7. This results in a substring search.. (% is "
|
||||
+ "appended to the beginning and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-7-like")
|
||||
private final String[] custom7Like;
|
||||
|
||||
|
@ -103,6 +223,12 @@ public class ClassificationQueryFilterParameter
|
|||
* to the beginning and end of the requested value). Further SQL "LIKE" wildcard characters will
|
||||
* be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-8-like",
|
||||
description =
|
||||
"Filter by the value of the field custom8. This results in a substring search.. (% is "
|
||||
+ "appended to the beginning and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-8-like")
|
||||
private final String[] custom8Like;
|
||||
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
package pro.taskana.classification.rest.models;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.time.Instant;
|
||||
import pro.taskana.classification.api.models.Classification;
|
||||
|
||||
|
@ -7,20 +8,32 @@ import pro.taskana.classification.api.models.Classification;
|
|||
public class ClassificationRepresentationModel extends ClassificationSummaryRepresentationModel {
|
||||
|
||||
/** True, if this classification to objects in this domain. */
|
||||
@Schema(
|
||||
name = "isValidInDomain",
|
||||
description = "True, if this classification to objects in this domain.")
|
||||
private Boolean isValidInDomain;
|
||||
/**
|
||||
* The creation timestamp of the classification in the system.
|
||||
*
|
||||
* <p>The format is ISO-8601.
|
||||
*/
|
||||
@Schema(
|
||||
name = "created",
|
||||
description =
|
||||
"The creation timestamp of the classification in the system.<p>The format is ISO-8601.")
|
||||
private Instant created;
|
||||
/**
|
||||
* The timestamp of the last modification.
|
||||
*
|
||||
* <p>The format is ISO-8601.
|
||||
*/
|
||||
@Schema(
|
||||
name = "modified",
|
||||
description = "The timestamp of the last modification.<p>The format is ISO-8601."
|
||||
)
|
||||
private Instant modified;
|
||||
/** The description of the classification. */
|
||||
@Schema(name = "description", description = "The description of the classification.")
|
||||
private String description;
|
||||
|
||||
public Boolean getIsValidInDomain() {
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.classification.rest.models;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.Collection;
|
||||
|
@ -17,6 +18,7 @@ public class ClassificationSummaryPagedRepresentationModel
|
|||
}
|
||||
|
||||
/** the embedded classifications. */
|
||||
@Schema(name = "classifications", description = "the embedded classifications.")
|
||||
@Override
|
||||
@JsonProperty("classifications")
|
||||
public @NotNull Collection<ClassificationSummaryRepresentationModel> getContent() {
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
package pro.taskana.classification.rest.models;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import org.springframework.hateoas.RepresentationModel;
|
||||
import pro.taskana.classification.api.models.ClassificationSummary;
|
||||
|
@ -9,55 +10,106 @@ public class ClassificationSummaryRepresentationModel
|
|||
extends RepresentationModel<ClassificationSummaryRepresentationModel> {
|
||||
|
||||
/** Unique Id. */
|
||||
@NotNull protected String classificationId;
|
||||
@Schema(name = "classificationId", description = "Unique Id.")
|
||||
@NotNull
|
||||
protected String classificationId;
|
||||
/**
|
||||
* The key of the Classification. This is typically an externally known code or abbreviation of
|
||||
* the Classification.
|
||||
*/
|
||||
@NotNull protected String key;
|
||||
@Schema(
|
||||
name = "key",
|
||||
description =
|
||||
"The key of the Classification. This is typically an externally known code or "
|
||||
+ "abbreviation of the Classification.")
|
||||
@NotNull
|
||||
protected String key;
|
||||
/**
|
||||
* The logical name of the entry point. This is needed by the task list application to determine
|
||||
* the redirect to work on a task of this Classification.
|
||||
*/
|
||||
@Schema(
|
||||
name = "applicationEntryPoint",
|
||||
description =
|
||||
"The logical name of the entry point. This is needed by the task list application to "
|
||||
+ "determine the redirect to work on a task of this Classification.")
|
||||
protected String applicationEntryPoint;
|
||||
/**
|
||||
* The category of the classification. Categories can be configured in the file
|
||||
* 'taskana.properties'.
|
||||
*/
|
||||
@NotNull protected String category;
|
||||
@Schema(
|
||||
name = "category",
|
||||
description =
|
||||
"The category of the classification. Categories can be configured in the file "
|
||||
+ "'taskana.properties'.")
|
||||
@NotNull
|
||||
protected String category;
|
||||
/** The domain for which this classification is specified. */
|
||||
@Schema(name = "domain", description = "The domain for which this classification is specified.")
|
||||
protected String domain;
|
||||
/** The name of the classification. */
|
||||
@NotNull protected String name;
|
||||
@Schema(name = "name", description = "The name of the classification.")
|
||||
@NotNull
|
||||
protected String name;
|
||||
/** The Id of the parent classification. Empty string ("") if this is a root classification. */
|
||||
@Schema(
|
||||
name = "parentId",
|
||||
description =
|
||||
"The Id of the parent classification. Empty string (\"\") if this is a root "
|
||||
+ "classification.")
|
||||
protected String parentId;
|
||||
/** The key of the parent classification. Empty string ("") if this is a root classification. */
|
||||
@Schema(
|
||||
name = "parentKey",
|
||||
description =
|
||||
"The key of the parent classification. Empty string (\"\") if this is a root "
|
||||
+ "classification.")
|
||||
protected String parentKey;
|
||||
/** The priority of the classification. */
|
||||
@NotNull protected int priority;
|
||||
@Schema(name = "priority", description = "The priority of the classification.")
|
||||
@NotNull
|
||||
protected int priority;
|
||||
/**
|
||||
* The service level of the classification.
|
||||
*
|
||||
* <p>This is stated according to ISO 8601.
|
||||
*/
|
||||
@NotNull protected String serviceLevel;
|
||||
@Schema(
|
||||
name = "serviceLevel",
|
||||
description =
|
||||
"The service level of the classification.<p>This is stated according to ISO 8601.")
|
||||
@NotNull
|
||||
protected String serviceLevel;
|
||||
/** The type of classification. Types can be configured in the file 'taskana.properties'. */
|
||||
@Schema(
|
||||
name = "type",
|
||||
description =
|
||||
"The type of classification. Types can be configured in the file 'taskana.properties'.")
|
||||
protected String type;
|
||||
/** A custom property with name "1". */
|
||||
@Schema(name = "custom1", description = "A custom property with name \"1\".")
|
||||
protected String custom1;
|
||||
/** A custom property with name "2". */
|
||||
@Schema(name = "custom2", description = "A custom property with name \"2\".")
|
||||
protected String custom2;
|
||||
/** A custom property with name "3". */
|
||||
@Schema(name = "custom3", description = "A custom property with name \"3\".")
|
||||
protected String custom3;
|
||||
/** A custom property with name "4". */
|
||||
@Schema(name = "custom4", description = "A custom property with name \"4\".")
|
||||
protected String custom4;
|
||||
/** A custom property with name "5". */
|
||||
@Schema(name = "custom5", description = "A custom property with name \"5\".")
|
||||
protected String custom5;
|
||||
/** A custom property with name "6". */
|
||||
@Schema(name = "custom6", description = "A custom property with name \"6\".")
|
||||
protected String custom6;
|
||||
/** A custom property with name "7". */
|
||||
@Schema(name = "custom7", description = "A custom property with name \"7\".")
|
||||
protected String custom7;
|
||||
/** A custom property with name "8". */
|
||||
@Schema(name = "custom8", description = "A custom property with name \"8\".")
|
||||
protected String custom8;
|
||||
|
||||
public String getClassificationId() {
|
||||
|
|
|
@ -1,7 +1,13 @@
|
|||
package pro.taskana.common.rest;
|
||||
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.media.Content;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||
import java.util.List;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.hateoas.MediaTypes;
|
||||
import org.springframework.hateoas.config.EnableHypermediaSupport;
|
||||
import org.springframework.hateoas.config.EnableHypermediaSupport.HypermediaType;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
|
@ -39,6 +45,25 @@ public class AccessIdController {
|
|||
* @throws NotAuthorizedException if the current user is not ADMIN or BUSINESS_ADMIN.
|
||||
* @title Search for Access Id (users and groups)
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Search for Access Id (users and groups)",
|
||||
description = "This endpoint searches a provided access Id in the configured ldap.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "search-for",
|
||||
description = "the Access Id which should be searched for.",
|
||||
example = "max",
|
||||
required = true)
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "a list of all found Access Ids",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = AccessIdRepresentationModel[].class)))
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_ACCESS_ID)
|
||||
public ResponseEntity<List<AccessIdRepresentationModel>> searchUsersAndGroups(
|
||||
@RequestParam("search-for") String searchFor)
|
||||
|
@ -64,6 +89,34 @@ public class AccessIdController {
|
|||
* or ADMIN
|
||||
* @title Search for Access Id (users) in TASKANA user role
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Search for Access Id (users) in TASKANA user role",
|
||||
description =
|
||||
"This endpoint searches AccessIds for a provided name or Access Id. It will only search "
|
||||
+ "and return users and members of groups which are configured with the requested "
|
||||
+ "TASKANA role. This search will only work if the users in the configured LDAP have"
|
||||
+ " an attribute that shows their group memberships, e.g. \"memberOf\"",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "search-for",
|
||||
description = "the name or Access Id which should be searched for.",
|
||||
example = "user-1",
|
||||
required = true),
|
||||
@Parameter(
|
||||
name = "role",
|
||||
description = "the role for which all users should be searched for",
|
||||
example = "user",
|
||||
required = true)
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "a list of all found Access Ids (users)",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = AccessIdRepresentationModel[].class)))
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_ACCESS_ID_WITH_NAME)
|
||||
public ResponseEntity<List<AccessIdRepresentationModel>> searchUsersByNameOrAccessIdForRole(
|
||||
@RequestParam("search-for") String nameOrAccessId, @RequestParam("role") String role)
|
||||
|
@ -90,6 +143,25 @@ public class AccessIdController {
|
|||
* @throws NotAuthorizedException if the current user is not ADMIN or BUSINESS_ADMIN.
|
||||
* @title Get groups for Access Id
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Get groups for Access Id",
|
||||
description = "This endpoint retrieves all groups a given Access Id belongs to.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "access-id",
|
||||
description = "the Access Id whose groups should be determined.",
|
||||
example = "teamlead-1",
|
||||
required = true)
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "a list of the group Access Ids the requested Access Id belongs to",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = AccessIdRepresentationModel[].class)))
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_ACCESS_ID_GROUPS)
|
||||
public ResponseEntity<List<AccessIdRepresentationModel>> getGroupsByAccessId(
|
||||
@RequestParam("access-id") String accessId)
|
||||
|
|
|
@ -2,6 +2,7 @@ package pro.taskana.common.rest;
|
|||
|
||||
import com.fasterxml.jackson.annotation.JsonIgnore;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import jakarta.validation.constraints.Min;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.List;
|
||||
|
@ -11,12 +12,26 @@ import pro.taskana.common.rest.models.PageMetadata;
|
|||
public class QueryPagingParameter<T, Q extends BaseQuery<T, ?>>
|
||||
implements QueryParameter<Q, List<T>> {
|
||||
|
||||
public Integer getPage() {
|
||||
return page;
|
||||
}
|
||||
|
||||
public Integer getPageSize() {
|
||||
return pageSize;
|
||||
}
|
||||
|
||||
/** Request a specific page. Requires the definition of the 'page-size'. */
|
||||
@Schema(
|
||||
name = "page",
|
||||
description = "Request a specific page. Requires the definition of the 'page-size'.")
|
||||
@JsonProperty("page")
|
||||
@Min(1)
|
||||
private final Integer page;
|
||||
|
||||
/** Defines the size for each page. This requires a specific requested 'page'. */
|
||||
@Schema(
|
||||
name = "page-size",
|
||||
description = "Defines the size for each page. This requires a specific requested 'page'.")
|
||||
@JsonProperty("page-size")
|
||||
@Min(1)
|
||||
private final Integer pageSize;
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.common.rest;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.util.List;
|
||||
import pro.taskana.common.api.BaseQuery;
|
||||
import pro.taskana.common.api.BaseQuery.SortDirection;
|
||||
|
@ -12,6 +13,11 @@ public class QuerySortParameter<Q extends BaseQuery<?, ?>, S extends QuerySortBy
|
|||
// the javadoc comment for this field is above its getter. This is done to define the type
|
||||
// parameter S by overriding that getter and allowing spring-auto-rest-docs to properly detect
|
||||
// the type parameter S.
|
||||
@Schema(
|
||||
name = "sort-by",
|
||||
description =
|
||||
"Sort the result by a given field. Multiple sort values can be declared. When the "
|
||||
+ "primary sort value is the same, the second one will be used.")
|
||||
@JsonProperty("sort-by")
|
||||
private final List<S> sortBy;
|
||||
|
||||
|
@ -20,6 +26,13 @@ public class QuerySortParameter<Q extends BaseQuery<?, ?>, S extends QuerySortBy
|
|||
* of sort-by and order declarations have to match. Alternatively the value can be omitted. If
|
||||
* done so the default sort order (ASCENDING) will be applied to every sort-by value.
|
||||
*/
|
||||
@Schema(
|
||||
name = "order",
|
||||
description =
|
||||
"The order direction for each sort value. This value requires the use of 'sort-by'. The"
|
||||
+ " amount of sort-by and order declarations have to match. Alternatively the value"
|
||||
+ " can be omitted. If done so the default sort order (ASCENDING) will be applied to"
|
||||
+ " every sort-by value.")
|
||||
@JsonProperty("order")
|
||||
private final List<SortDirection> order;
|
||||
|
||||
|
|
|
@ -1,8 +1,15 @@
|
|||
package pro.taskana.common.rest;
|
||||
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.media.Content;
|
||||
import io.swagger.v3.oas.annotations.media.ExampleObject;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.hateoas.MediaTypes;
|
||||
import org.springframework.hateoas.config.EnableHypermediaSupport;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
@ -46,6 +53,16 @@ public class TaskanaEngineController {
|
|||
*
|
||||
* @return An array with the domain-names as strings
|
||||
*/
|
||||
@Operation(
|
||||
summary = "This endpoint retrieves all configured Domains.",
|
||||
responses =
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "An array with the domain-names as strings",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = String[].class))))
|
||||
@GetMapping(path = RestEndpoints.URL_DOMAIN)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<List<String>> getDomains() {
|
||||
|
@ -60,10 +77,28 @@ public class TaskanaEngineController {
|
|||
* classification categories will be returned.
|
||||
* @return the classification categories for the requested type.
|
||||
*/
|
||||
@Operation(
|
||||
summary =
|
||||
"This endpoint retrieves the configured classification categories for a specific "
|
||||
+ "classification type.",
|
||||
parameters =
|
||||
@Parameter(
|
||||
name = "type",
|
||||
description =
|
||||
"The classification type whose categories should be determined. If not specified "
|
||||
+ "all classification categories will be returned."),
|
||||
responses =
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "The classification categories for the requested type.",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = String[].class))))
|
||||
@GetMapping(path = RestEndpoints.URL_CLASSIFICATION_CATEGORIES)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<List<String>> getClassificationCategories(
|
||||
@RequestParam(required = false) String type) {
|
||||
@RequestParam(value = "type", required = false) String type) {
|
||||
if (type != null) {
|
||||
return ResponseEntity.ok(taskanaConfiguration.getClassificationCategoriesByType(type));
|
||||
}
|
||||
|
@ -75,6 +110,16 @@ public class TaskanaEngineController {
|
|||
*
|
||||
* @return the configured classification types.
|
||||
*/
|
||||
@Operation(
|
||||
summary = "This endpoint retrieves the configured classification types.",
|
||||
responses =
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "The configured classification types.",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = String[].class))))
|
||||
@GetMapping(path = RestEndpoints.URL_CLASSIFICATION_TYPES)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<List<String>> getClassificationTypes() {
|
||||
|
@ -87,6 +132,18 @@ public class TaskanaEngineController {
|
|||
*
|
||||
* @return the configured classification categories
|
||||
*/
|
||||
@Operation(
|
||||
summary =
|
||||
"This endpoint retrieves all configured classification categories grouped by each "
|
||||
+ "classification type.",
|
||||
responses =
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "The configured classification categories.",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(ref = "#/components/schemas/TypeMapSchema"))))
|
||||
@GetMapping(path = RestEndpoints.URL_CLASSIFICATION_CATEGORIES_BY_TYPES)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<Map<String, List<String>>> getClassificationCategoriesByTypeMap() {
|
||||
|
@ -98,6 +155,16 @@ public class TaskanaEngineController {
|
|||
*
|
||||
* @return the information of the current user.
|
||||
*/
|
||||
@Operation(
|
||||
summary = "This endpoint computes all information of the current user.",
|
||||
responses =
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "The information of the current user.",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskanaUserInfoRepresentationModel.class))))
|
||||
@GetMapping(path = RestEndpoints.URL_CURRENT_USER)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskanaUserInfoRepresentationModel> getCurrentUserInfo() {
|
||||
|
@ -115,6 +182,16 @@ public class TaskanaEngineController {
|
|||
*
|
||||
* @return true, when the history is enabled, otherwise false
|
||||
*/
|
||||
@Operation(
|
||||
summary = "This endpoint checks if the history module is in use.",
|
||||
responses =
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "True, when the history is enabled, otherwise false",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = Boolean.class))))
|
||||
@GetMapping(path = RestEndpoints.URL_HISTORY_ENABLED)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<Boolean> getIsHistoryProviderEnabled() {
|
||||
|
@ -127,6 +204,18 @@ public class TaskanaEngineController {
|
|||
* @title Get custom configuration
|
||||
* @return custom configuration
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Get custom configuration",
|
||||
description = "This endpoint retrieves the saved custom configuration.",
|
||||
responses =
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "The custom configuration.",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema =
|
||||
@Schema(implementation = CustomAttributesRepresentationModel.class))))
|
||||
@GetMapping(path = RestEndpoints.URL_CUSTOM_ATTRIBUTES)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<CustomAttributesRepresentationModel> getCustomAttributes() {
|
||||
|
@ -141,6 +230,48 @@ public class TaskanaEngineController {
|
|||
* @title Set all custom configuration
|
||||
* @return the new custom configuration
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Set all custom configuration",
|
||||
description = "This endpoint overrides the custom configuration.",
|
||||
requestBody =
|
||||
@io.swagger.v3.oas.annotations.parameters.RequestBody(
|
||||
description = "The new custom configuration",
|
||||
required = true,
|
||||
content =
|
||||
@Content(
|
||||
schema = @Schema(implementation = CustomAttributesRepresentationModel.class),
|
||||
examples =
|
||||
@ExampleObject(
|
||||
value =
|
||||
"{\n"
|
||||
+ " \"customAttributes\": {\n"
|
||||
+ " \"schema\": {\n"
|
||||
+ " \"Filter\": {\n"
|
||||
+ " \"displayName\": "
|
||||
+ "\"Filter for Task-Priority-Report\",\n"
|
||||
+ " \"members\": {\n"
|
||||
+ " \"filter\": {\n"
|
||||
+ " \"displayName\": \"Filter values\",\n"
|
||||
+ " \"type\": \"json\",\n"
|
||||
+ " \"min\": \"1\"\n"
|
||||
+ " }\n"
|
||||
+ " }\n"
|
||||
+ " },\n"
|
||||
+ " \"filter\": \"{ \\\"Tasks with state READY\\\": "
|
||||
+ "{ \\\"state\\\": [\\\"READY\\\"]}, \\\"Tasks with state "
|
||||
+ "CLAIMED\\\": {\\\"state\\\": [\\\"CLAIMED\\\"] }}\"\n"
|
||||
+ " }\n"
|
||||
+ " }\n"
|
||||
+ "}"))),
|
||||
responses =
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "The new custom configuration.",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema =
|
||||
@Schema(implementation = CustomAttributesRepresentationModel.class))))
|
||||
@PutMapping(path = RestEndpoints.URL_CUSTOM_ATTRIBUTES)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<CustomAttributesRepresentationModel> setCustomAttributes(
|
||||
|
@ -154,6 +285,16 @@ public class TaskanaEngineController {
|
|||
*
|
||||
* @return The current version.
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Get the current application version",
|
||||
responses =
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "The current version.",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = VersionRepresentationModel.class))))
|
||||
@GetMapping(path = RestEndpoints.URL_VERSION)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<VersionRepresentationModel> currentVersion() {
|
||||
|
|
|
@ -117,13 +117,22 @@ public class TaskanaRestExceptionHandler extends ResponseEntityExceptionHandler
|
|||
Map.entry(UnsupportedDatabaseException.ERROR_KEY, HttpStatus.INTERNAL_SERVER_ERROR),
|
||||
Map.entry(ERROR_KEY_UNKNOWN_ERROR, HttpStatus.INTERNAL_SERVER_ERROR));
|
||||
|
||||
@ExceptionHandler(MaxUploadSizeExceededException.class)
|
||||
@Override
|
||||
protected ResponseEntity<Object> handleMaxUploadSizeExceededException(
|
||||
MaxUploadSizeExceededException ex, WebRequest req) {
|
||||
HttpStatus status =
|
||||
MaxUploadSizeExceededException ex,
|
||||
HttpHeaders headers,
|
||||
HttpStatusCode status,
|
||||
WebRequest request
|
||||
) {
|
||||
|
||||
return buildResponse(
|
||||
ErrorCode.of(ERROR_KEY_PAYLOAD),
|
||||
ex,
|
||||
request,
|
||||
HTTP_STATUS_BY_ERROR_CODE_KEY.getOrDefault(
|
||||
ERROR_KEY_PAYLOAD, HttpStatus.INTERNAL_SERVER_ERROR);
|
||||
return buildResponse(ErrorCode.of(ERROR_KEY_PAYLOAD), ex, req, status);
|
||||
ERROR_KEY_PAYLOAD, HttpStatus.INTERNAL_SERVER_ERROR
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
@ExceptionHandler(BeanInstantiationException.class)
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
package pro.taskana.common.rest.models;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.Map;
|
||||
import org.springframework.hateoas.RepresentationModel;
|
||||
|
@ -8,6 +9,10 @@ public class CustomAttributesRepresentationModel
|
|||
extends RepresentationModel<CustomAttributesRepresentationModel> {
|
||||
|
||||
/** The custom configuration attributes. */
|
||||
@Schema(
|
||||
name = "customAttributes",
|
||||
description = "The custom configuration attributes."
|
||||
)
|
||||
private final Map<String, Object> customAttributes;
|
||||
|
||||
@ConstructorProperties({"customAttributes"})
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
package pro.taskana.common.rest.models;
|
||||
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.Objects;
|
||||
|
||||
|
@ -11,12 +13,23 @@ import java.util.Objects;
|
|||
public class PageMetadata {
|
||||
|
||||
/** The element size of the page. */
|
||||
@Parameter(hidden = true)
|
||||
@Schema(name = "size", description = "The element size of the page.")
|
||||
private final long size;
|
||||
|
||||
/** The total number of elements available. */
|
||||
@Parameter(hidden = true)
|
||||
@Schema(name = "totalElements", description = "The total number of elements available.")
|
||||
private final long totalElements;
|
||||
|
||||
/** Amount of pages that are available in total. */
|
||||
@Parameter(hidden = true)
|
||||
@Schema(name = "totalPages", description = "Amount of pages that are available in total.")
|
||||
private final long totalPages;
|
||||
|
||||
/** The current page number. */
|
||||
@Parameter(hidden = true)
|
||||
@Schema(name = "number", description = "The current page number.")
|
||||
private final long number;
|
||||
|
||||
@ConstructorProperties({"size", "totalElements", "totalPages", "number"})
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.common.rest.models;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.util.Collection;
|
||||
import org.springframework.hateoas.RepresentationModel;
|
||||
|
||||
|
@ -8,6 +9,7 @@ public abstract class PagedRepresentationModel<T extends RepresentationModel<? s
|
|||
extends CollectionRepresentationModel<T> {
|
||||
|
||||
/** the page meta data for a paged request. */
|
||||
@Schema(name = "page", description = "the page meta data for a paged request.")
|
||||
@JsonProperty("page")
|
||||
private final PageMetadata pageMetadata;
|
||||
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
package pro.taskana.common.rest.models;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import org.springframework.hateoas.RepresentationModel;
|
||||
|
@ -11,10 +12,22 @@ public class TaskanaUserInfoRepresentationModel
|
|||
extends RepresentationModel<TaskanaUserInfoRepresentationModel> {
|
||||
|
||||
/** The user Id of the current user. */
|
||||
@Schema(
|
||||
name = "userId",
|
||||
description = "The user Id of the current user."
|
||||
)
|
||||
private String userId;
|
||||
/** All groups the current user is a member of. */
|
||||
@Schema(
|
||||
name = "groupIds",
|
||||
description = "All groups the current user is a member of."
|
||||
)
|
||||
private List<String> groupIds = new ArrayList<>();
|
||||
/** All taskana roles the current user fulfills. */
|
||||
@Schema(
|
||||
name = "roles",
|
||||
description = "All taskana roles the current user fulfills."
|
||||
)
|
||||
private List<TaskanaRole> roles = new ArrayList<>();
|
||||
|
||||
public String getUserId() {
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
package pro.taskana.common.rest.models;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import org.springframework.hateoas.RepresentationModel;
|
||||
import org.springframework.lang.NonNull;
|
||||
|
@ -8,7 +9,9 @@ import org.springframework.lang.NonNull;
|
|||
public class VersionRepresentationModel extends RepresentationModel<VersionRepresentationModel> {
|
||||
|
||||
/** The current TASKANA version of the REST Service. */
|
||||
@NotNull private String version;
|
||||
@Schema(name = "version", description = "The current TASKANA version of the REST Service.")
|
||||
@NotNull
|
||||
private String version;
|
||||
|
||||
public String getVersion() {
|
||||
return version;
|
||||
|
|
|
@ -1,9 +1,17 @@
|
|||
package pro.taskana.monitor.rest;
|
||||
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.media.Content;
|
||||
import io.swagger.v3.oas.annotations.media.ExampleObject;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Optional;
|
||||
import org.springdoc.core.annotations.ParameterObject;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.hateoas.MediaTypes;
|
||||
import org.springframework.hateoas.config.EnableHypermediaSupport;
|
||||
import org.springframework.http.HttpStatus;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
|
@ -69,10 +77,36 @@ public class MonitorController {
|
|||
* @throws NotAuthorizedException if the current user is not authorized to compute the Report
|
||||
* @throws InvalidArgumentException TODO: this is never thrown ...
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Compute a Workbasket Report",
|
||||
description =
|
||||
"This endpoint generates a Workbasket Report.<p>Each Row represents a Workbasket.<p>Each "
|
||||
+ "Column Header represents a Time Interval.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "task-timestamp",
|
||||
description = "Determine which Task Timestamp should be used for comparison"),
|
||||
@Parameter(
|
||||
name = "state",
|
||||
examples = {
|
||||
@ExampleObject(value = "READY"),
|
||||
@ExampleObject(value = "CLAIMED"),
|
||||
@ExampleObject(value = "COMPLETED")
|
||||
})
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "The computed Report",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = ReportRepresentationModel.class))),
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_MONITOR_WORKBASKET_REPORT)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<ReportRepresentationModel> computeWorkbasketReport(
|
||||
TimeIntervalReportFilterParameter filterParameter,
|
||||
@ParameterObject TimeIntervalReportFilterParameter filterParameter,
|
||||
@RequestParam(name = "task-timestamp", required = false) TaskTimestamp taskTimestamp)
|
||||
throws NotAuthorizedException, InvalidArgumentException {
|
||||
if (taskTimestamp == null) {
|
||||
|
@ -104,10 +138,31 @@ public class MonitorController {
|
|||
* @throws NotAuthorizedException if the current user is not authorized to compute the Report
|
||||
* @throws InvalidArgumentException if topicWorkbaskets or useDefaultValues are false
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Compute a Workbasket Priority Report",
|
||||
description =
|
||||
"This endpoint generates a Workbasket Priority Report.<p>Each Row represents a "
|
||||
+ "Workbasket.<p>Each Column Header represents a priority range.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "workbasket-type",
|
||||
description = "Determine the WorkbasketTypes to include in the report",
|
||||
example = "GROUP"),
|
||||
@Parameter(name = "columnHeader", description = "The column headers for the report")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "The computed Report",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = ReportRepresentationModel.class)))
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_MONITOR_WORKBASKET_PRIORITY_REPORT)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<ReportRepresentationModel> computePriorityWorkbasketReport(
|
||||
PriorityReportFilterParameter filterParameter,
|
||||
@ParameterObject PriorityReportFilterParameter filterParameter,
|
||||
@RequestParam(name = "workbasket-type", required = false) WorkbasketType[] workbasketTypes,
|
||||
@RequestParam(name = "columnHeader", required = false)
|
||||
PriorityColumnHeaderRepresentationModel[] columnHeaders)
|
||||
|
@ -146,10 +201,29 @@ public class MonitorController {
|
|||
* @throws NotAuthorizedException if the current user is not authorized to compute the Report
|
||||
* @throws InvalidArgumentException TODO: this is never thrown ...
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Compute a Classification Category Report",
|
||||
description =
|
||||
"This endpoint generates a Classification Category Report.<p>Each Row represents a "
|
||||
+ "Classification category.<p>Each Column Header represents a Time Interval.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "task-timestamp",
|
||||
description = "Determine which Task Timestamp should be used for comparison")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "The computed Report",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = ReportRepresentationModel.class)))
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_MONITOR_CLASSIFICATION_CATEGORY_REPORT)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<ReportRepresentationModel> computeClassificationCategoryReport(
|
||||
TimeIntervalReportFilterParameter filterParameter,
|
||||
@ParameterObject TimeIntervalReportFilterParameter filterParameter,
|
||||
@RequestParam(name = "task-timestamp", required = false) TaskTimestamp taskTimestamp)
|
||||
throws InvalidArgumentException, NotAuthorizedException {
|
||||
if (taskTimestamp == null) {
|
||||
|
@ -181,10 +255,29 @@ public class MonitorController {
|
|||
* @throws NotAuthorizedException if the current user is not authorized to compute the Report
|
||||
* @throws InvalidArgumentException TODO: this is never thrown
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Compute a Classification Report",
|
||||
description =
|
||||
"This endpoint generates a Classification Report.<p>Each Row represents a Classification."
|
||||
+ "<p>Each Column Header represents a Time Interval.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "task-timestamp",
|
||||
description = "Determine which Task Timestamp should be used for comparison")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "The computed Report",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = ReportRepresentationModel.class)))
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_MONITOR_CLASSIFICATION_REPORT)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<ReportRepresentationModel> computeClassificationReport(
|
||||
TimeIntervalReportFilterParameter filterParameter,
|
||||
@ParameterObject TimeIntervalReportFilterParameter filterParameter,
|
||||
@RequestParam(name = "task-timestamp", required = false) TaskTimestamp taskTimestamp)
|
||||
throws NotAuthorizedException, InvalidArgumentException {
|
||||
if (taskTimestamp == null) {
|
||||
|
@ -216,10 +309,30 @@ public class MonitorController {
|
|||
* @throws NotAuthorizedException if the current user is not authorized to compute the Report
|
||||
* @throws InvalidArgumentException TODO: this is never thrown
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Compute a Detailed Classification Report",
|
||||
description =
|
||||
"This endpoint generates a Detailed Classification Report.<p>Each Foldable Row represents"
|
||||
+ " a Classification and can be expanded to show the Classification of Attachments."
|
||||
+ "<p>Each Column Header represents a Time Interval.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "task-timestamp",
|
||||
description = "Determine which Task Timestamp should be used for comparison")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "The computed Report",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = ReportRepresentationModel.class)))
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_MONITOR_DETAILED_CLASSIFICATION_REPORT)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<ReportRepresentationModel> computeDetailedClassificationReport(
|
||||
TimeIntervalReportFilterParameter filterParameter,
|
||||
@ParameterObject TimeIntervalReportFilterParameter filterParameter,
|
||||
@RequestParam(name = "task-timestamp", required = false) TaskTimestamp taskTimestamp)
|
||||
throws NotAuthorizedException, InvalidArgumentException {
|
||||
if (taskTimestamp == null) {
|
||||
|
@ -251,11 +364,36 @@ public class MonitorController {
|
|||
* @throws NotAuthorizedException if the current user is not authorized to compute the Report
|
||||
* @throws InvalidArgumentException TODO: this is never thrown
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Compute a Detailed Classification Report",
|
||||
description =
|
||||
"This endpoint generates a Task Custom Field Value Report.<p>Each Row represents a value "
|
||||
+ "of the requested Task Custom Field.<p>Each Column Header represents a Time "
|
||||
+ "Interval.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "custom-field",
|
||||
description = "The Task Custom Field whose values are of interest",
|
||||
example = "CUSTOM_14",
|
||||
required = true),
|
||||
@Parameter(
|
||||
name = "task-timestamp",
|
||||
description = "Determine which Task Timestamp should be used for comparison")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "The computed Report",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = ReportRepresentationModel.class)))
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_MONITOR_TASK_CUSTOM_FIELD_VALUE_REPORT)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<ReportRepresentationModel> computeTaskCustomFieldValueReport(
|
||||
@RequestParam(name = "custom-field") TaskCustomField customField,
|
||||
TimeIntervalReportFilterParameter filterParameter,
|
||||
@ParameterObject TimeIntervalReportFilterParameter filterParameter,
|
||||
@RequestParam(name = "task-timestamp", required = false) TaskTimestamp taskTimestamp)
|
||||
throws NotAuthorizedException, InvalidArgumentException {
|
||||
if (taskTimestamp == null) {
|
||||
|
@ -288,6 +426,38 @@ public class MonitorController {
|
|||
* @return the computed Report
|
||||
* @throws NotAuthorizedException if the current user is not authorized to compute the Report
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Compute a Task Status Report",
|
||||
description =
|
||||
"This endpoint generates a Task Status Report.<p>Each Row represents a Workbasket.<p>"
|
||||
+ "Each Column Header represents a Task State.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "domain",
|
||||
description = "Filter the report values by domains",
|
||||
required = false),
|
||||
@Parameter(
|
||||
name = "state",
|
||||
description = "Filter the report values by Task states",
|
||||
required = false),
|
||||
@Parameter(
|
||||
name = "workbasket-id",
|
||||
description = "Filter the report values by Workbasket Ids",
|
||||
required = false),
|
||||
@Parameter(
|
||||
name = "priority-minimum",
|
||||
description = "Filter the report values by a minimum priority",
|
||||
required = false)
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "The computed Report",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = ReportRepresentationModel.class)))
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_MONITOR_TASK_STATUS_REPORT)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<ReportRepresentationModel> computeTaskStatusReport(
|
||||
|
@ -331,10 +501,30 @@ public class MonitorController {
|
|||
* @throws NotAuthorizedException if the current user is not authorized to compute the report
|
||||
* @throws InvalidArgumentException TODO: this is never thrown
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Compute a Timestamp Report",
|
||||
description =
|
||||
"This endpoint generates a Timestamp Report.<p>Each Foldable Row represents a "
|
||||
+ "TaskTimestamp and can be expanded to display the four organization levels of the "
|
||||
+ "corresponding Workbasket.<p>Each Column Header represents a TimeInterval.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "task-timestamp",
|
||||
description = "Filter by the Task Timestamp of the task")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "The computed Report",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = ReportRepresentationModel.class)))
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_MONITOR_TIMESTAMP_REPORT)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<ReportRepresentationModel> computeTimestampReport(
|
||||
TimeIntervalReportFilterParameter filterParameter,
|
||||
@ParameterObject TimeIntervalReportFilterParameter filterParameter,
|
||||
@RequestParam(name = "task-timestamp", required = false) TaskTimestamp[] timestamps)
|
||||
throws NotAuthorizedException, InvalidArgumentException {
|
||||
|
||||
|
|
|
@ -1,40 +1,281 @@
|
|||
package pro.taskana.monitor.rest;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import pro.taskana.task.api.TaskState;
|
||||
|
||||
public class ReportFilterParameter {
|
||||
public Boolean getInWorkingDays() {
|
||||
return inWorkingDays;
|
||||
}
|
||||
|
||||
public String[] getWorkbasketId() {
|
||||
return workbasketId;
|
||||
}
|
||||
|
||||
public TaskState[] getState() {
|
||||
return state;
|
||||
}
|
||||
|
||||
public String[] getClassificationCategory() {
|
||||
return classificationCategory;
|
||||
}
|
||||
|
||||
public String[] getDomain() {
|
||||
return domain;
|
||||
}
|
||||
|
||||
public String[] getClassificationId() {
|
||||
return classificationId;
|
||||
}
|
||||
|
||||
public String[] getExcludedClassificationId() {
|
||||
return excludedClassificationId;
|
||||
}
|
||||
|
||||
public String[] getCustom1() {
|
||||
return custom1;
|
||||
}
|
||||
|
||||
public String[] getCustom1Like() {
|
||||
return custom1Like;
|
||||
}
|
||||
|
||||
public String[] getCustom1NotIn() {
|
||||
return custom1NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom2() {
|
||||
return custom2;
|
||||
}
|
||||
|
||||
public String[] getCustom2Like() {
|
||||
return custom2Like;
|
||||
}
|
||||
|
||||
public String[] getCustom2NotIn() {
|
||||
return custom2NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom3() {
|
||||
return custom3;
|
||||
}
|
||||
|
||||
public String[] getCustom3Like() {
|
||||
return custom3Like;
|
||||
}
|
||||
|
||||
public String[] getCustom3NotIn() {
|
||||
return custom3NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom4() {
|
||||
return custom4;
|
||||
}
|
||||
|
||||
public String[] getCustom4Like() {
|
||||
return custom4Like;
|
||||
}
|
||||
|
||||
public String[] getCustom4NotIn() {
|
||||
return custom4NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom5() {
|
||||
return custom5;
|
||||
}
|
||||
|
||||
public String[] getCustom5Like() {
|
||||
return custom5Like;
|
||||
}
|
||||
|
||||
public String[] getCustom5NotIn() {
|
||||
return custom5NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom6() {
|
||||
return custom6;
|
||||
}
|
||||
|
||||
public String[] getCustom6Like() {
|
||||
return custom6Like;
|
||||
}
|
||||
|
||||
public String[] getCustom6NotIn() {
|
||||
return custom6NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom7() {
|
||||
return custom7;
|
||||
}
|
||||
|
||||
public String[] getCustom7Like() {
|
||||
return custom7Like;
|
||||
}
|
||||
|
||||
public String[] getCustom7NotIn() {
|
||||
return custom7NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom8() {
|
||||
return custom8;
|
||||
}
|
||||
|
||||
public String[] getCustom8Like() {
|
||||
return custom8Like;
|
||||
}
|
||||
|
||||
public String[] getCustom8NotIn() {
|
||||
return custom8NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom9() {
|
||||
return custom9;
|
||||
}
|
||||
|
||||
public String[] getCustom9Like() {
|
||||
return custom9Like;
|
||||
}
|
||||
|
||||
public String[] getCustom9NotIn() {
|
||||
return custom9NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom10() {
|
||||
return custom10;
|
||||
}
|
||||
|
||||
public String[] getCustom10Like() {
|
||||
return custom10Like;
|
||||
}
|
||||
|
||||
public String[] getCustom10NotIn() {
|
||||
return custom10NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom11() {
|
||||
return custom11;
|
||||
}
|
||||
|
||||
public String[] getCustom11Like() {
|
||||
return custom11Like;
|
||||
}
|
||||
|
||||
public String[] getCustom11NotIn() {
|
||||
return custom11NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom12() {
|
||||
return custom12;
|
||||
}
|
||||
|
||||
public String[] getCustom12Like() {
|
||||
return custom12Like;
|
||||
}
|
||||
|
||||
public String[] getCustom12NotIn() {
|
||||
return custom12NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom13() {
|
||||
return custom13;
|
||||
}
|
||||
|
||||
public String[] getCustom13Like() {
|
||||
return custom13Like;
|
||||
}
|
||||
|
||||
public String[] getCustom13NotIn() {
|
||||
return custom13NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom14() {
|
||||
return custom14;
|
||||
}
|
||||
|
||||
public String[] getCustom14Like() {
|
||||
return custom14Like;
|
||||
}
|
||||
|
||||
public String[] getCustom14NotIn() {
|
||||
return custom14NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom15() {
|
||||
return custom15;
|
||||
}
|
||||
|
||||
public String[] getCustom15Like() {
|
||||
return custom15Like;
|
||||
}
|
||||
|
||||
public String[] getCustom15NotIn() {
|
||||
return custom15NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom16() {
|
||||
return custom16;
|
||||
}
|
||||
|
||||
public String[] getCustom16Like() {
|
||||
return custom16Like;
|
||||
}
|
||||
|
||||
public String[] getCustom16NotIn() {
|
||||
return custom16NotIn;
|
||||
}
|
||||
|
||||
/** Determine weather the report should convert the age of the Tasks into working days. */
|
||||
@Schema(
|
||||
name = "in-working-days",
|
||||
description =
|
||||
"Determine weather the report should convert the age of the Tasks into working days.")
|
||||
@JsonProperty("in-working-days")
|
||||
protected final Boolean inWorkingDays;
|
||||
|
||||
/** Filter by workbasket id of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "workbasket-id",
|
||||
description = "Filter by workbasket id of the Task. This is an exact match.")
|
||||
@JsonProperty("workbasket-id")
|
||||
protected final String[] workbasketId;
|
||||
|
||||
/** Filter by the task state. This is an exact match. */
|
||||
@Schema(name = "state", description = "Filter by the task state. This is an exact match.")
|
||||
@JsonProperty("state")
|
||||
protected final TaskState[] state;
|
||||
|
||||
/** Filter by the classification category of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "classification-category",
|
||||
description = "Filter by the classification category of the Task. This is an exact match.")
|
||||
@JsonProperty("classification-category")
|
||||
protected final String[] classificationCategory;
|
||||
|
||||
/** Filter by domain of the Task. This is an exact match. */
|
||||
@Schema(name = "domain", description = "Filter by domain of the Task. This is an exact match.")
|
||||
@JsonProperty("domain")
|
||||
protected final String[] domain;
|
||||
|
||||
/** Filter by the classification id of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "classification-id",
|
||||
description = "Filter by the classification id of the Task. This is an exact match.")
|
||||
@JsonProperty("classification-id")
|
||||
protected final String[] classificationId;
|
||||
|
||||
/** Filter by the classification id of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "excluded-classification-id",
|
||||
description = "Filter by the classification id of the Task. This is an exact match.")
|
||||
@JsonProperty("excluded-classification-id")
|
||||
protected final String[] excludedClassificationId;
|
||||
|
||||
/** Filter by the value of the field custom1 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-1",
|
||||
description = "Filter by the value of the field custom1 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-1")
|
||||
protected final String[] custom1;
|
||||
|
||||
|
@ -43,14 +284,27 @@ public class ReportFilterParameter {
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-1-like",
|
||||
description =
|
||||
"Filter by the custom1 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-1-like")
|
||||
protected final String[] custom1Like;
|
||||
|
||||
/** Filter out by values of the field custom1 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-1-not-in",
|
||||
description =
|
||||
"Filter out by values of the field custom1 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-1-not-in")
|
||||
protected final String[] custom1NotIn;
|
||||
|
||||
/** Filter by the value of the field custom2 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-2",
|
||||
description = "Filter by the value of the field custom2 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-2")
|
||||
protected final String[] custom2;
|
||||
|
||||
|
@ -59,14 +313,27 @@ public class ReportFilterParameter {
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-2-like",
|
||||
description =
|
||||
"Filter by the custom2 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-2-like")
|
||||
protected final String[] custom2Like;
|
||||
|
||||
/** Filter out by values of the field custom2 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-2-not-in",
|
||||
description =
|
||||
"Filter out by values of the field custom2 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-2-not-in")
|
||||
protected final String[] custom2NotIn;
|
||||
|
||||
/** Filter by the value of the field custom3 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-3",
|
||||
description = "Filter by the value of the field custom3 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-3")
|
||||
protected final String[] custom3;
|
||||
|
||||
|
@ -75,14 +342,27 @@ public class ReportFilterParameter {
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-3-like",
|
||||
description =
|
||||
"Filter by the custom3 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-3-like")
|
||||
protected final String[] custom3Like;
|
||||
|
||||
/** Filter out by values of the field custom3 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-3-not-in",
|
||||
description =
|
||||
"Filter out by values of the field custom3 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-3-not-in")
|
||||
protected final String[] custom3NotIn;
|
||||
|
||||
/** Filter by the value of the field custom4 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-4",
|
||||
description = "Filter by the value of the field custom4 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-4")
|
||||
protected final String[] custom4;
|
||||
|
||||
|
@ -91,14 +371,27 @@ public class ReportFilterParameter {
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-4-like",
|
||||
description =
|
||||
"Filter by the custom4 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-4-like")
|
||||
protected final String[] custom4Like;
|
||||
|
||||
/** Filter out by values of the field custom4 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-4-not-in",
|
||||
description =
|
||||
"Filter out by values of the field custom4 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-4-not-in")
|
||||
protected final String[] custom4NotIn;
|
||||
|
||||
/** Filter by the value of the field custom5 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-5",
|
||||
description = "Filter by the value of the field custom5 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-5")
|
||||
protected final String[] custom5;
|
||||
|
||||
|
@ -107,14 +400,27 @@ public class ReportFilterParameter {
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-5-like",
|
||||
description =
|
||||
"Filter by the custom5 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-5-like")
|
||||
protected final String[] custom5Like;
|
||||
|
||||
/** Filter out by values of the field custom5 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-5-not-in",
|
||||
description =
|
||||
"Filter out by values of the field custom5 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-5-not-in")
|
||||
protected final String[] custom5NotIn;
|
||||
|
||||
/** Filter by the value of the field custom6 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-6",
|
||||
description = "Filter by the value of the field custom6 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-6")
|
||||
protected final String[] custom6;
|
||||
|
||||
|
@ -123,14 +429,27 @@ public class ReportFilterParameter {
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-6-like",
|
||||
description =
|
||||
"Filter by the custom6 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-6-like")
|
||||
protected final String[] custom6Like;
|
||||
|
||||
/** Filter out by values of the field custom6 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-6-not-in",
|
||||
description =
|
||||
"Filter out by values of the field custom6 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-6-not-in")
|
||||
protected final String[] custom6NotIn;
|
||||
|
||||
/** Filter by the value of the field custom7 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-7",
|
||||
description = "Filter by the value of the field custom7 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-7")
|
||||
protected final String[] custom7;
|
||||
|
||||
|
@ -139,14 +458,27 @@ public class ReportFilterParameter {
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-7-like",
|
||||
description =
|
||||
"Filter by the custom7 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-7-like")
|
||||
protected final String[] custom7Like;
|
||||
|
||||
/** Filter out by values of the field custom7 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-7-not-in",
|
||||
description =
|
||||
"Filter out by values of the field custom7 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-7-not-in")
|
||||
protected final String[] custom7NotIn;
|
||||
|
||||
/** Filter by the value of the field custom8 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-8",
|
||||
description = "Filter by the value of the field custom8 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-8")
|
||||
protected final String[] custom8;
|
||||
|
||||
|
@ -155,14 +487,27 @@ public class ReportFilterParameter {
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-8-like",
|
||||
description =
|
||||
"Filter by the custom8 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-8-like")
|
||||
protected final String[] custom8Like;
|
||||
|
||||
/** Filter out by values of the field custom8 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-8-not-in",
|
||||
description =
|
||||
"Filter out by values of the field custom8 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-8-not-in")
|
||||
protected final String[] custom8NotIn;
|
||||
|
||||
/** Filter by the value of the field custom9 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-9",
|
||||
description = "Filter by the value of the field custom9 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-9")
|
||||
protected final String[] custom9;
|
||||
|
||||
|
@ -171,14 +516,28 @@ public class ReportFilterParameter {
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-9-like",
|
||||
description =
|
||||
"Filter by the custom9 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-9-like")
|
||||
protected final String[] custom9Like;
|
||||
|
||||
/** Filter out by values of the field custom9 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-9-not-in",
|
||||
description =
|
||||
"Filter out by values of the field custom9 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-9-not-in")
|
||||
protected final String[] custom9NotIn;
|
||||
|
||||
/** Filter by the value of the field custom10 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-10",
|
||||
description =
|
||||
"Filter by the value of the field custom10 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-10")
|
||||
protected final String[] custom10;
|
||||
|
||||
|
@ -187,14 +546,28 @@ public class ReportFilterParameter {
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-10-like",
|
||||
description =
|
||||
"Filter by the custom10 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-10-like")
|
||||
protected final String[] custom10Like;
|
||||
|
||||
/** Filter out by values of the field custom10 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-10-not-in",
|
||||
description =
|
||||
"Filter out by values of the field custom10 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-10-not-in")
|
||||
protected final String[] custom10NotIn;
|
||||
|
||||
/** Filter by the value of the field custom11 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-11",
|
||||
description =
|
||||
"Filter by the value of the field custom11 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-11")
|
||||
protected final String[] custom11;
|
||||
|
||||
|
@ -203,14 +576,28 @@ public class ReportFilterParameter {
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-11-like",
|
||||
description =
|
||||
"Filter by the custom11 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-11-like")
|
||||
protected final String[] custom11Like;
|
||||
|
||||
/** Filter out by values of the field custom11 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-11-not-in",
|
||||
description =
|
||||
"Filter out by values of the field custom11 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-11-not-in")
|
||||
protected final String[] custom11NotIn;
|
||||
|
||||
/** Filter by the value of the field custom12 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-12",
|
||||
description =
|
||||
"Filter by the value of the field custom12 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-12")
|
||||
protected final String[] custom12;
|
||||
|
||||
|
@ -219,14 +606,28 @@ public class ReportFilterParameter {
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-12-like",
|
||||
description =
|
||||
"Filter by the custom12 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-12-like")
|
||||
protected final String[] custom12Like;
|
||||
|
||||
/** Filter out by values of the field custom12 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-12-not-in",
|
||||
description =
|
||||
"Filter out by values of the field custom12 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-12-not-in")
|
||||
protected final String[] custom12NotIn;
|
||||
|
||||
/** Filter by the value of the field custom13 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-13",
|
||||
description =
|
||||
"Filter by the value of the field custom13 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-13")
|
||||
protected final String[] custom13;
|
||||
|
||||
|
@ -235,14 +636,28 @@ public class ReportFilterParameter {
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-13-like",
|
||||
description =
|
||||
"Filter by the custom13 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-13-like")
|
||||
protected final String[] custom13Like;
|
||||
|
||||
/** Filter out by values of the field custom13 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-13-not-in",
|
||||
description =
|
||||
"Filter out by values of the field custom13 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-13-not-in")
|
||||
protected final String[] custom13NotIn;
|
||||
|
||||
/** Filter by the value of the field custom14 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-14",
|
||||
description =
|
||||
"Filter by the value of the field custom14 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-14")
|
||||
protected final String[] custom14;
|
||||
|
||||
|
@ -251,14 +666,28 @@ public class ReportFilterParameter {
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-14-like",
|
||||
description =
|
||||
"Filter by the custom14 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-14-like")
|
||||
protected final String[] custom14Like;
|
||||
|
||||
/** Filter out by values of the field custom14 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-14-not-in",
|
||||
description =
|
||||
"Filter out by values of the field custom14 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-14-not-in")
|
||||
protected final String[] custom14NotIn;
|
||||
|
||||
/** Filter by the value of the field custom15 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-15",
|
||||
description =
|
||||
"Filter by the value of the field custom15 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-15")
|
||||
protected final String[] custom15;
|
||||
|
||||
|
@ -267,14 +696,28 @@ public class ReportFilterParameter {
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-15-like",
|
||||
description =
|
||||
"Filter by the custom15 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-15-like")
|
||||
protected final String[] custom15Like;
|
||||
|
||||
/** Filter out by values of the field custom15 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-15-not-in",
|
||||
description =
|
||||
"Filter out by values of the field custom15 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-15-not-in")
|
||||
protected final String[] custom15NotIn;
|
||||
|
||||
/** Filter by the value of the field custom16 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-16",
|
||||
description =
|
||||
"Filter by the value of the field custom16 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-16")
|
||||
protected final String[] custom16;
|
||||
|
||||
|
@ -283,10 +726,20 @@ public class ReportFilterParameter {
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-16-like",
|
||||
description =
|
||||
"Filter by the custom16 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-16-like")
|
||||
protected final String[] custom16Like;
|
||||
|
||||
/** Filter out by values of the field custom16 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-16-not-in",
|
||||
description =
|
||||
"Filter out by values of the field custom16 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-16-not-in")
|
||||
protected final String[] custom16NotIn;
|
||||
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.monitor.rest.models;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import org.springframework.hateoas.RepresentationModel;
|
||||
|
||||
|
@ -9,9 +10,15 @@ public class PriorityColumnHeaderRepresentationModel
|
|||
extends RepresentationModel<PriorityColumnHeaderRepresentationModel> {
|
||||
|
||||
/** Determine the lower priority for this column header. This value is inclusive. */
|
||||
@Schema(
|
||||
name = "lowerBound",
|
||||
description = "Determine the lower priority for this column header. This value is inclusive.")
|
||||
private final int lowerBound;
|
||||
|
||||
/** Determine the upper priority for this column header. This value is inclusive. */
|
||||
@Schema(
|
||||
name = "upperBound",
|
||||
description = "Determine the upper priority for this column header. This value is inclusive.")
|
||||
private final int upperBound;
|
||||
|
||||
@ConstructorProperties({"lowerBound", "upperBound"})
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
package pro.taskana.monitor.rest.models;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.time.Instant;
|
||||
import java.util.Arrays;
|
||||
|
@ -12,10 +13,13 @@ import pro.taskana.monitor.api.reports.row.SingleRow;
|
|||
public class ReportRepresentationModel extends RepresentationModel<ReportRepresentationModel> {
|
||||
|
||||
/** Object holding meta info on the report. */
|
||||
@Schema(name = "meta", description = "Object holding meta info on the report.")
|
||||
private final MetaInformation meta;
|
||||
/** Array holding the rows of the report. */
|
||||
@Schema(name = "rows", description = "Array holding the rows of the report.")
|
||||
private final List<RowRepresentationModel> rows;
|
||||
/** Array holding the sums in the columns over all rows. */
|
||||
@Schema(name = "sumRow", description = "Array holding the sums in the columns over all rows.")
|
||||
private final List<RowRepresentationModel> sumRow;
|
||||
|
||||
@ConstructorProperties({"meta", "rows", "sumRow"})
|
||||
|
@ -44,14 +48,24 @@ public class ReportRepresentationModel extends RepresentationModel<ReportReprese
|
|||
public static class RowRepresentationModel {
|
||||
|
||||
/** Array holding all the cell values of the given row. */
|
||||
@Schema(name = "cells", description = "Array holding all the cell values of the given row.")
|
||||
private final int[] cells;
|
||||
/** Sum of all values of the given row. */
|
||||
@Schema(name = "cells", description = "Sum of all values of the given row.")
|
||||
private final int total;
|
||||
/** Depth of the row. If the depth is > 0, then this row is a sub-row of a prior row */
|
||||
@Schema(
|
||||
name = "depth",
|
||||
description =
|
||||
"Depth of the row. If the depth is > 0, then this row is a sub-row of a prior row")
|
||||
private final int depth;
|
||||
/** Array containing description of the row. */
|
||||
@Schema(name = "desc", description = "Array containing description of the row.")
|
||||
private final String[] desc;
|
||||
/** Boolean identifying if the given row should be initially displayed or not. */
|
||||
@Schema(
|
||||
name = "display",
|
||||
description = "Boolean identifying if the given row should be initially displayed or not.")
|
||||
private final boolean display;
|
||||
|
||||
@ConstructorProperties({"cells", "total", "depth", "desc", "display"})
|
||||
|
@ -104,14 +118,19 @@ public class ReportRepresentationModel extends RepresentationModel<ReportReprese
|
|||
public static class MetaInformation {
|
||||
|
||||
/** Name of the report. */
|
||||
@Schema(name = "name", description = "Name of the report.")
|
||||
private final String name;
|
||||
/** Date of the report creation. */
|
||||
@Schema(name = "date", description = "Date of the report creation.")
|
||||
private final Instant date;
|
||||
/** Column headers of the report. */
|
||||
@Schema(name = "header", description = "Column headers of the report.")
|
||||
private final String[] header;
|
||||
/** Descriptions for the rows of the report. */
|
||||
@Schema(name = "rowDesc", description = "Descriptions for the rows of the report.")
|
||||
private final String[] rowDesc;
|
||||
/** Description for the sum column. */
|
||||
@Schema(name = "sumRowDesc", description = "Description for the sum column.")
|
||||
private final String sumRowDesc;
|
||||
|
||||
@ConstructorProperties({"name", "date", "header", "rowDesc", "sumRowDesc"})
|
||||
|
|
|
@ -1,10 +1,17 @@
|
|||
package pro.taskana.task.rest;
|
||||
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.media.Content;
|
||||
import io.swagger.v3.oas.annotations.media.ExampleObject;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||
import jakarta.servlet.http.HttpServletRequest;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.List;
|
||||
import java.util.function.BiConsumer;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.hateoas.MediaTypes;
|
||||
import org.springframework.hateoas.config.EnableHypermediaSupport;
|
||||
import org.springframework.hateoas.config.EnableHypermediaSupport.HypermediaType;
|
||||
import org.springframework.http.HttpStatus;
|
||||
|
@ -65,10 +72,29 @@ public class TaskCommentController {
|
|||
* @throws TaskCommentNotFoundException if the requested Task Comment is not found
|
||||
* @throws InvalidArgumentException if the requested Id is null or empty
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Get a single Task Comment",
|
||||
description = "This endpoint retrieves a Task Comment.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskCommentId",
|
||||
description = "The Id of the Task Comment",
|
||||
example = "TCI:000000000000000000000000000000000000",
|
||||
required = true)
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the Task Comment",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskCommentRepresentationModel.class)))
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_TASK_COMMENT)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskCommentRepresentationModel> getTaskComment(
|
||||
@PathVariable String taskCommentId)
|
||||
@PathVariable("taskCommentId") String taskCommentId)
|
||||
throws TaskNotFoundException,
|
||||
TaskCommentNotFoundException,
|
||||
InvalidArgumentException,
|
||||
|
@ -92,10 +118,32 @@ public class TaskCommentController {
|
|||
* @param pagingParameter the paging parameters
|
||||
* @return a list of Task Comments
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Get a list of all Task Comments for a specific Task",
|
||||
description =
|
||||
"This endpoint retrieves all Task Comments for a specific Task. Further filters can be "
|
||||
+ "applied.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
description = "The Id of the Task whose comments are requested",
|
||||
example = "TKI:000000000000000000000000000000000000",
|
||||
required = true)
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "a list of Task Comments",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema =
|
||||
@Schema(implementation = TaskCommentCollectionRepresentationModel.class)))
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_TASK_COMMENTS)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskCommentCollectionRepresentationModel> getTaskComments(
|
||||
@PathVariable String taskId,
|
||||
@PathVariable("taskId") String taskId,
|
||||
HttpServletRequest request,
|
||||
TaskCommentQueryFilterParameter filterParameter,
|
||||
TaskCommentQuerySortParameter sortParameter,
|
||||
|
@ -135,10 +183,21 @@ public class TaskCommentController {
|
|||
* @throws NotAuthorizedOnWorkbasketException if the current user has not correct permissions
|
||||
* @throws NotAuthorizedOnTaskCommentException if the current user has not correct permissions
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Delete a Task Comment",
|
||||
description = "This endpoint deletes a given Task Comment.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskCommentId",
|
||||
description = "The Id of the Task Comment which should be deleted",
|
||||
example = "TCI:000000000000000000000000000000000001",
|
||||
required = true)
|
||||
},
|
||||
responses = {@ApiResponse(responseCode = "204", content = @Content(schema = @Schema()))})
|
||||
@DeleteMapping(path = RestEndpoints.URL_TASK_COMMENT)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskCommentRepresentationModel> deleteTaskComment(
|
||||
@PathVariable String taskCommentId)
|
||||
@PathVariable("taskCommentId") String taskCommentId)
|
||||
throws TaskNotFoundException,
|
||||
TaskCommentNotFoundException,
|
||||
InvalidArgumentException,
|
||||
|
@ -166,10 +225,49 @@ public class TaskCommentController {
|
|||
* @throws NotAuthorizedOnTaskCommentException if the current user has not correct permissions
|
||||
* @throws NotAuthorizedOnWorkbasketException if the current user has not correct permissions
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Update a Task Comment",
|
||||
description = "This endpoint updates a given Task Comment.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskCommentId",
|
||||
description = "The Id of the Task Comment which should be updated",
|
||||
example = "TCI:000000000000000000000000000000000000",
|
||||
required = true)
|
||||
},
|
||||
requestBody =
|
||||
@io.swagger.v3.oas.annotations.parameters.RequestBody(
|
||||
description = "The new comment for the requested id",
|
||||
content =
|
||||
@Content(
|
||||
schema = @Schema(implementation = TaskCommentRepresentationModel.class),
|
||||
examples =
|
||||
@ExampleObject(
|
||||
value =
|
||||
"{\n"
|
||||
+ " \"taskCommentId\": "
|
||||
+ "\"TCI:000000000000000000000000000000000000\",\n"
|
||||
+ " \"taskId\": "
|
||||
+ "\"TKI:000000000000000000000000000000000000\",\n"
|
||||
+ " \"textField\": \"updated text in textfield\",\n"
|
||||
+ " \"creator\": \"user-1-1\",\n"
|
||||
+ " \"creatorFullName\": \"Mustermann, Max\",\n"
|
||||
+ " \"created\": \"2017-01-29T15:55:00Z\",\n"
|
||||
+ " \"modified\": \"2018-01-30T15:55:00Z\"\n"
|
||||
+ "}"))),
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the updated Task Comment",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskCommentRepresentationModel.class)))
|
||||
})
|
||||
@PutMapping(path = RestEndpoints.URL_TASK_COMMENT)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskCommentRepresentationModel> updateTaskComment(
|
||||
@PathVariable String taskCommentId,
|
||||
@PathVariable("taskCommentId") String taskCommentId,
|
||||
@RequestBody TaskCommentRepresentationModel taskCommentRepresentationModel)
|
||||
throws TaskNotFoundException,
|
||||
TaskCommentNotFoundException,
|
||||
|
@ -206,10 +304,43 @@ public class TaskCommentController {
|
|||
* @throws InvalidArgumentException if the Task Comment Id is null or empty
|
||||
* @throws TaskNotFoundException if the requested task does not exist
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Create a new Task Comment",
|
||||
description = "This endpoint creates a Task Comment.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
description = "The Id of the Task where a Task Comment should be created",
|
||||
example = "TKI:000000000000000000000000000000000000",
|
||||
required = true)
|
||||
},
|
||||
requestBody =
|
||||
@io.swagger.v3.oas.annotations.parameters.RequestBody(
|
||||
description = "The Task Comment to create",
|
||||
content =
|
||||
@Content(
|
||||
schema = @Schema(implementation = TaskCommentRepresentationModel.class),
|
||||
examples =
|
||||
@ExampleObject(
|
||||
value =
|
||||
"{\n"
|
||||
+ " \"taskId\": "
|
||||
+ "\"TKI:000000000000000000000000000000000000\",\n"
|
||||
+ " \"textField\": \"some text in textfield\"\n"
|
||||
+ "}"))),
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "201",
|
||||
description = "the created Task Comment",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskCommentRepresentationModel.class)))
|
||||
})
|
||||
@PostMapping(path = RestEndpoints.URL_TASK_COMMENTS)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskCommentRepresentationModel> createTaskComment(
|
||||
@PathVariable String taskId,
|
||||
@PathVariable("taskId") String taskId,
|
||||
@RequestBody TaskCommentRepresentationModel taskCommentRepresentationModel)
|
||||
throws InvalidArgumentException, TaskNotFoundException, NotAuthorizedOnWorkbasketException {
|
||||
taskCommentRepresentationModel.setTaskId(taskId);
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.task.rest;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.time.Instant;
|
||||
import java.util.Optional;
|
||||
|
@ -10,10 +11,15 @@ import pro.taskana.task.api.TaskCommentQuery;
|
|||
public class TaskCommentQueryFilterParameter implements QueryParameter<TaskCommentQuery, Void> {
|
||||
|
||||
/** Filter by the id of the TaskComment. This is an exact match. */
|
||||
@Schema(name = "id", description = "Filter by the id of the TaskComment. This is an exact match.")
|
||||
@JsonProperty("id")
|
||||
private final String[] idIn;
|
||||
|
||||
/** Filter by what the id of the TaskComment shouldn't be. This is an exact match. */
|
||||
@Schema(
|
||||
name = "id-not",
|
||||
description =
|
||||
"Filter by what the id of the TaskComment shouldn't be. This is an exact match.")
|
||||
@JsonProperty("id-not")
|
||||
private final String[] idNotIn;
|
||||
|
||||
|
@ -22,6 +28,12 @@ public class TaskCommentQueryFilterParameter implements QueryParameter<TaskComme
|
|||
* front and end of the requested value). Further SQL "LIKE" wildcard characters will be resolved
|
||||
* correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "id-like",
|
||||
description =
|
||||
"Filter by the id of the TaskComment. This results in a substring search (% is appended "
|
||||
+ "to the front and end of the requested value). Further SQL 'LIKE' wildcard "
|
||||
+ "characters will be resolved correctly.")
|
||||
@JsonProperty("id-like")
|
||||
private final String[] idLike;
|
||||
|
||||
|
@ -30,18 +42,34 @@ public class TaskCommentQueryFilterParameter implements QueryParameter<TaskComme
|
|||
* appended to the front and end of the requested value). Further SQL "LIKE" wildcard characters
|
||||
* will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "id-not-like",
|
||||
description =
|
||||
"Filter by what the id of the TaskComment shouldn't be. This results in a substring "
|
||||
+ "search (% is appended to the front and end of the requested value). Further SQL "
|
||||
+ "'LIKE' wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("id-not-like")
|
||||
private final String[] idNotLike;
|
||||
|
||||
/** Filter by the task id of the TaskComment. This is an exact match. */
|
||||
@Schema(
|
||||
name = "task-id",
|
||||
description = "Filter by the task id of the TaskComment. This is an exact match.")
|
||||
@JsonProperty("task-id")
|
||||
private final String[] taskIdIn;
|
||||
|
||||
/** Filter by the creator of the TaskComment. This is an exact match. */
|
||||
@Schema(
|
||||
name = "creator",
|
||||
description = "Filter by the creator of the TaskComment. This is an exact match.")
|
||||
@JsonProperty("creator")
|
||||
private final String[] creatorIn;
|
||||
|
||||
/** Filter by what the creator of the TaskComment shouldn't be. This is an exact match. */
|
||||
@Schema(
|
||||
name = "creator-not",
|
||||
description =
|
||||
"Filter by what the creator of the TaskComment shouldn't be. This is an exact match.")
|
||||
@JsonProperty("creator-not")
|
||||
private final String[] creatorNotIn;
|
||||
|
||||
|
@ -50,6 +78,12 @@ public class TaskCommentQueryFilterParameter implements QueryParameter<TaskComme
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "creator-like",
|
||||
description =
|
||||
"Filter by the creator of the TaskComment. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL 'LIKE' wildcard"
|
||||
+ " characters will be resolved correctly.")
|
||||
@JsonProperty("creator-like")
|
||||
private final String[] creatorLike;
|
||||
|
||||
|
@ -58,6 +92,12 @@ public class TaskCommentQueryFilterParameter implements QueryParameter<TaskComme
|
|||
* (% is appended to the front and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "creator-not-like",
|
||||
description =
|
||||
"Filter by what the creator of the TaskComment shouldn't be. This results in a substring "
|
||||
+ "search (% is appended to the front and end of the requested value). Further SQL "
|
||||
+ "'LIKE' wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("creator-not-like")
|
||||
private final String[] creatorNotLike;
|
||||
|
||||
|
@ -66,6 +106,12 @@ public class TaskCommentQueryFilterParameter implements QueryParameter<TaskComme
|
|||
* to the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "textfield-like",
|
||||
description =
|
||||
"Filter by the textfield of the TaskComment. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL 'LIKE' wildcard"
|
||||
+ " characters will be resolved correctly.")
|
||||
@JsonProperty("textfield-like")
|
||||
private final String[] textfieldLike;
|
||||
|
||||
|
@ -74,6 +120,12 @@ public class TaskCommentQueryFilterParameter implements QueryParameter<TaskComme
|
|||
* search (% is appended to the front and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "textfield-not-like",
|
||||
description =
|
||||
"Filter by what the textfield of the TaskComment shouldn't be. This results in a "
|
||||
+ "substring search (% is appended to the front and end of the requested value). "
|
||||
+ "Further SQL 'LIKE' wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("textfield-not-like")
|
||||
private final String[] textfieldNotLike;
|
||||
|
||||
|
@ -83,6 +135,11 @@ public class TaskCommentQueryFilterParameter implements QueryParameter<TaskComme
|
|||
*
|
||||
* <p>The format is ISO-8601.
|
||||
*/
|
||||
@Schema(
|
||||
name = "modified",
|
||||
description =
|
||||
"Filter by a time interval within which the TaskComment was modified. To create an open "
|
||||
+ "interval you can just leave it blank. The format is ISO-8601.")
|
||||
@JsonProperty("modified")
|
||||
private final Instant[] modifiedWithin;
|
||||
|
||||
|
@ -92,6 +149,11 @@ public class TaskCommentQueryFilterParameter implements QueryParameter<TaskComme
|
|||
*
|
||||
* <p>The format is ISO-8601.
|
||||
*/
|
||||
@Schema(
|
||||
name = "modified-not",
|
||||
description =
|
||||
"Filter by a time interval within which the TaskComment wasn't modified. To create an "
|
||||
+ "open interval you can just leave it blank. The format is ISO-8601.")
|
||||
@JsonProperty("modified-not")
|
||||
private final Instant[] modifiedNotWithin;
|
||||
|
||||
|
@ -101,6 +163,11 @@ public class TaskCommentQueryFilterParameter implements QueryParameter<TaskComme
|
|||
*
|
||||
* <p>The format is ISO-8601.
|
||||
*/
|
||||
@Schema(
|
||||
name = "created",
|
||||
description =
|
||||
"Filter by a time interval within which the TaskComment was created. To create an open "
|
||||
+ "interval you can just leave it blank. The format is ISO-8601.")
|
||||
@JsonProperty("created")
|
||||
private final Instant[] createdWithin;
|
||||
|
||||
|
@ -110,6 +177,11 @@ public class TaskCommentQueryFilterParameter implements QueryParameter<TaskComme
|
|||
*
|
||||
* <p>The format is ISO-8601.
|
||||
*/
|
||||
@Schema(
|
||||
name = "created-not",
|
||||
description =
|
||||
"Filter by a time interval within which the TaskComment wasn't created. To create an "
|
||||
+ "open interval you can just leave it blank. The format is ISO-8601.")
|
||||
@JsonProperty("created-not")
|
||||
private final Instant[] createdNotWithin;
|
||||
|
||||
|
|
|
@ -2,6 +2,12 @@ package pro.taskana.task.rest;
|
|||
|
||||
import static java.util.function.Predicate.not;
|
||||
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.media.Content;
|
||||
import io.swagger.v3.oas.annotations.media.ExampleObject;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||
import jakarta.servlet.http.HttpServletRequest;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.HashSet;
|
||||
|
@ -10,7 +16,9 @@ import java.util.Objects;
|
|||
import java.util.Optional;
|
||||
import java.util.Set;
|
||||
import java.util.function.BiConsumer;
|
||||
import org.springdoc.core.annotations.ParameterObject;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.hateoas.MediaTypes;
|
||||
import org.springframework.hateoas.config.EnableHypermediaSupport;
|
||||
import org.springframework.hateoas.config.EnableHypermediaSupport.HypermediaType;
|
||||
import org.springframework.http.HttpStatus;
|
||||
|
@ -95,6 +103,61 @@ public class TaskController {
|
|||
* multiple times without using the task-methods
|
||||
* @title Create a new Task
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Create a new Task",
|
||||
description = "This endpoint creates a persistent Task.",
|
||||
requestBody =
|
||||
@io.swagger.v3.oas.annotations.parameters.RequestBody(
|
||||
description = "the Task which should be created.",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class),
|
||||
examples =
|
||||
@ExampleObject(
|
||||
value =
|
||||
"{"
|
||||
+ "\"priority\" : 0,"
|
||||
+ "\"manualPriority\" : -1,"
|
||||
+ "\"classificationSummary\" : {"
|
||||
+ "\"key\" : \"L11010\","
|
||||
+ "\"priority\" : 0"
|
||||
+ "},"
|
||||
+ "\"workbasketSummary\" : {"
|
||||
+ "\"workbasketId\" : "
|
||||
+ "\"WBI:100000000000000000000000000000000004\","
|
||||
+ "\"markedForDeletion\" : false"
|
||||
+ "},"
|
||||
+ "\"primaryObjRef\" : {"
|
||||
+ "\"company\" : \"MyCompany1\","
|
||||
+ "\"system\" : \"MySystem1\","
|
||||
+ "\"systemInstance\" : \"MyInstance1\","
|
||||
+ "\"type\" : \"MyType1\","
|
||||
+ "\"value\" : \"00000001\""
|
||||
+ "},"
|
||||
+ "\"secondaryObjectReferences\" : [ {"
|
||||
+ "\"company\" : \"company\","
|
||||
+ "\"system\" : \"system\","
|
||||
+ "\"systemInstance\" : \"systemInstance\","
|
||||
+ "\"type\" : \"type\","
|
||||
+ "\"value\" : \"value\""
|
||||
+ "} ],"
|
||||
+ "\"customAttributes\" : [ ],"
|
||||
+ "\"callbackInfo\" : [ ],"
|
||||
+ "\"attachments\" : [ ],"
|
||||
+ "\"read\" : false,"
|
||||
+ "\"transferred\" : false"
|
||||
+ "}"))),
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "201",
|
||||
description = "the created Task",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@PostMapping(path = RestEndpoints.URL_TASKS)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> createTask(
|
||||
|
@ -140,16 +203,34 @@ public class TaskController {
|
|||
* @param pagingParameter the paging parameters
|
||||
* @return the Tasks with the given filter, sort and paging options.
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Get a list of all Tasks",
|
||||
description = "This endpoint retrieves a list of existing Tasks. Filters can be applied.",
|
||||
parameters = {
|
||||
@Parameter(name = "por-type", example = "VNR"),
|
||||
@Parameter(name = "por-value", example = "22334455"),
|
||||
@Parameter(name = "sort-by", example = "NAME")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the Tasks with the given filter, sort and paging options.",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskSummaryPagedRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_TASKS)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskSummaryPagedRepresentationModel> getTasks(
|
||||
HttpServletRequest request,
|
||||
TaskQueryFilterParameter filterParameter,
|
||||
TaskQueryFilterCustomFields filterCustomFields,
|
||||
TaskQueryFilterCustomIntFields filterCustomIntFields,
|
||||
TaskQueryGroupByParameter groupByParameter,
|
||||
TaskQuerySortParameter sortParameter,
|
||||
QueryPagingParameter<TaskSummary, TaskQuery> pagingParameter) {
|
||||
@ParameterObject TaskQueryFilterParameter filterParameter,
|
||||
@ParameterObject TaskQueryFilterCustomFields filterCustomFields,
|
||||
@ParameterObject TaskQueryFilterCustomIntFields filterCustomIntFields,
|
||||
@ParameterObject TaskQueryGroupByParameter groupByParameter,
|
||||
@ParameterObject TaskQuerySortParameter sortParameter,
|
||||
@ParameterObject QueryPagingParameter<TaskSummary, TaskQuery> pagingParameter) {
|
||||
QueryParamsValidator.validateParams(
|
||||
request,
|
||||
TaskQueryFilterParameter.class,
|
||||
|
@ -184,9 +265,29 @@ public class TaskController {
|
|||
* requested Task.
|
||||
* @title Get a single Task
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Get a single Task",
|
||||
description = "This endpoint retrieves a specific Task.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
required = true,
|
||||
description = "the Id of the requested Task",
|
||||
example = "TKI:100000000000000000000000000000000000")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the requested Task",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_TASKS_ID)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> getTask(@PathVariable String taskId)
|
||||
public ResponseEntity<TaskRepresentationModel> getTask(@PathVariable("taskId") String taskId)
|
||||
throws TaskNotFoundException, NotAuthorizedOnWorkbasketException {
|
||||
Task task = taskService.getTask(taskId);
|
||||
|
||||
|
@ -210,10 +311,30 @@ public class TaskController {
|
|||
* requested Task.
|
||||
* @title Claim a Task
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Claim a Task",
|
||||
description = "This endpoint claims a Task if possible.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
required = true,
|
||||
description = "the Id of the Task which should be claimed",
|
||||
example = "TKI:000000000000000000000000000000000003")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the claimed Task",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@PostMapping(path = RestEndpoints.URL_TASKS_ID_CLAIM)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> claimTask(
|
||||
@PathVariable String taskId, @RequestBody(required = false) String userName)
|
||||
@PathVariable("taskId") String taskId, @RequestBody(required = false) String userName)
|
||||
throws TaskNotFoundException,
|
||||
InvalidOwnerException,
|
||||
NotAuthorizedOnWorkbasketException,
|
||||
|
@ -236,10 +357,32 @@ public class TaskController {
|
|||
* requested Task.
|
||||
* @title Force claim a Task
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Force claim a Task",
|
||||
description =
|
||||
"This endpoint force claims a Task if possible even if it is already claimed by someone "
|
||||
+ "else.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
description = "the Id of the Task which should be force claimed",
|
||||
required = true,
|
||||
example = "TKI:000000000000000000000000000000000003")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the force claimed Task",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@PostMapping(path = RestEndpoints.URL_TASKS_ID_CLAIM_FORCE)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> forceClaimTask(
|
||||
@PathVariable String taskId, @RequestBody(required = false) String userName)
|
||||
@PathVariable("taskId") String taskId, @RequestBody(required = false) String userName)
|
||||
throws TaskNotFoundException,
|
||||
InvalidTaskStateException,
|
||||
InvalidOwnerException,
|
||||
|
@ -262,13 +405,32 @@ public class TaskController {
|
|||
* Workbasket the Task is in
|
||||
* @title Select and claim a Task
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Select and claim a Task",
|
||||
description =
|
||||
"This endpoint selects the first Task returned by the Task Query and claims it.",
|
||||
parameters = {@Parameter(name = "custom14", example = "abc")},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the claimed Task",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class))
|
||||
}),
|
||||
@ApiResponse(
|
||||
responseCode = "404",
|
||||
description = "if no Task is found",
|
||||
content = {@Content(schema = @Schema())})
|
||||
})
|
||||
@PostMapping(path = RestEndpoints.URL_TASKS_ID_SELECT_AND_CLAIM)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> selectAndClaimTask(
|
||||
TaskQueryFilterParameter filterParameter,
|
||||
TaskQueryFilterCustomFields filterCustomFields,
|
||||
TaskQueryFilterCustomIntFields filterCustomIntFields,
|
||||
TaskQuerySortParameter sortParameter)
|
||||
@ParameterObject TaskQueryFilterParameter filterParameter,
|
||||
@ParameterObject TaskQueryFilterCustomFields filterCustomFields,
|
||||
@ParameterObject TaskQueryFilterCustomIntFields filterCustomIntFields,
|
||||
@ParameterObject TaskQuerySortParameter sortParameter)
|
||||
throws InvalidOwnerException, NotAuthorizedOnWorkbasketException {
|
||||
TaskQuery query = taskService.createTaskQuery();
|
||||
|
||||
|
@ -298,10 +460,36 @@ public class TaskController {
|
|||
* Workbasket the Task is in
|
||||
* @title Cancel a claimed Task
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Cancel a claimed Task",
|
||||
description =
|
||||
"This endpoint cancels the claim of an existing Task if it was claimed by the current "
|
||||
+ "user before.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
description = "the Id of the requested Task.",
|
||||
required = true,
|
||||
example = "TKI:000000000000000000000000000000000002"),
|
||||
@Parameter(
|
||||
name = "keepOwner",
|
||||
description = "flag whether or not to keep the owner despite the cancel claim")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the unclaimed Task",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@DeleteMapping(path = RestEndpoints.URL_TASKS_ID_CLAIM)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> cancelClaimTask(
|
||||
@PathVariable String taskId, @RequestParam(defaultValue = "false") boolean keepOwner)
|
||||
@PathVariable("taskId") String taskId,
|
||||
@RequestParam(value = "keepOwner", defaultValue = "false") boolean keepOwner)
|
||||
throws TaskNotFoundException,
|
||||
InvalidTaskStateException,
|
||||
InvalidOwnerException,
|
||||
|
@ -324,10 +512,33 @@ public class TaskController {
|
|||
* Workbasket the Task is in
|
||||
* @title Force cancel a claimed Task
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Force cancel a claimed Task",
|
||||
description = "This endpoint force cancels the claim of an existing Task.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
description = "the Id of the requested Task.",
|
||||
required = true,
|
||||
example = "TKI:000000000000000000000000000000000002"),
|
||||
@Parameter(
|
||||
name = "keepOwner",
|
||||
description = "flag whether or not to keep the owner despite the cancel claim.")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the unclaimed Task.",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class)))
|
||||
})
|
||||
@DeleteMapping(path = RestEndpoints.URL_TASKS_ID_CLAIM_FORCE)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> forceCancelClaimTask(
|
||||
@PathVariable String taskId, @RequestParam(defaultValue = "false") boolean keepOwner)
|
||||
@PathVariable("taskId") String taskId,
|
||||
@RequestParam(value = "keepOwner", defaultValue = "false") boolean keepOwner)
|
||||
throws TaskNotFoundException,
|
||||
InvalidTaskStateException,
|
||||
InvalidOwnerException,
|
||||
|
@ -348,9 +559,29 @@ public class TaskController {
|
|||
* Workbasket the Task is in
|
||||
* @title Request a review on a Task
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Request a review on a Task",
|
||||
description = "This endpoint requests a review on the specified Task.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
description = "the id of the relevant Task",
|
||||
required = true,
|
||||
example = "TKI:000000000000000000000000000000000032")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the Task after a review has been requested",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class))),
|
||||
})
|
||||
@PostMapping(path = RestEndpoints.URL_TASKS_ID_REQUEST_REVIEW)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> requestReview(@PathVariable String taskId)
|
||||
public ResponseEntity<TaskRepresentationModel> requestReview(
|
||||
@PathVariable("taskId") String taskId)
|
||||
throws InvalidTaskStateException,
|
||||
TaskNotFoundException,
|
||||
InvalidOwnerException,
|
||||
|
@ -371,9 +602,29 @@ public class TaskController {
|
|||
* Workbasket the Task is in
|
||||
* @title Force request a review on a Task
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Force request a review on a Task",
|
||||
description = "This endpoint force requests a review on the specified Task.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
description = "the id of the relevant Task",
|
||||
required = true,
|
||||
example = "TKI:000000000000000000000000000000000101")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the Task after a review has been requested",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class)))
|
||||
})
|
||||
@PostMapping(path = RestEndpoints.URL_TASKS_ID_REQUEST_REVIEW_FORCE)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> forceRequestReview(@PathVariable String taskId)
|
||||
public ResponseEntity<TaskRepresentationModel> forceRequestReview(
|
||||
@PathVariable("taskId") String taskId)
|
||||
throws InvalidTaskStateException,
|
||||
TaskNotFoundException,
|
||||
InvalidOwnerException,
|
||||
|
@ -394,9 +645,29 @@ public class TaskController {
|
|||
* Workbasket the Task is in
|
||||
* @title Request changes on a Task
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Request changes on a Task",
|
||||
description = "This endpoint requests changes on the specified Task.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
description = "the id of the relevant Task",
|
||||
required = true,
|
||||
example = "TKI:000000000000000000000000000000000136")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "Changes requested successfully",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class))),
|
||||
})
|
||||
@PostMapping(path = RestEndpoints.URL_TASKS_ID_REQUEST_CHANGES)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> requestChanges(@PathVariable String taskId)
|
||||
public ResponseEntity<TaskRepresentationModel> requestChanges(
|
||||
@PathVariable("taskId") String taskId)
|
||||
throws InvalidTaskStateException,
|
||||
TaskNotFoundException,
|
||||
InvalidOwnerException,
|
||||
|
@ -417,9 +688,29 @@ public class TaskController {
|
|||
* Workbasket the Task is in
|
||||
* @title Force request changes on a Task
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Force request changes on a Task",
|
||||
description = "This endpoint force requests changes on the specified Task.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
description = "the Id of the Task on which a review should be requested",
|
||||
required = true,
|
||||
example = "TKI:000000000000000000000000000000000100")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the change requested Task",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class))),
|
||||
})
|
||||
@PostMapping(path = RestEndpoints.URL_TASKS_ID_REQUEST_CHANGES_FORCE)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> forceRequestChanges(@PathVariable String taskId)
|
||||
public ResponseEntity<TaskRepresentationModel> forceRequestChanges(
|
||||
@PathVariable("taskId") String taskId)
|
||||
throws InvalidTaskStateException,
|
||||
TaskNotFoundException,
|
||||
InvalidOwnerException,
|
||||
|
@ -440,9 +731,28 @@ public class TaskController {
|
|||
* Workbasket the Task is in
|
||||
* @title Complete a Task
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Complete a Task",
|
||||
description = "This endpoint completes a Task.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
description = "Id of the requested Task to complete.",
|
||||
example = "TKI:000000000000000000000000000000000003",
|
||||
required = true)
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the completed Task",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class)))
|
||||
})
|
||||
@PostMapping(path = RestEndpoints.URL_TASKS_ID_COMPLETE)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> completeTask(@PathVariable String taskId)
|
||||
public ResponseEntity<TaskRepresentationModel> completeTask(@PathVariable("taskId") String taskId)
|
||||
throws TaskNotFoundException,
|
||||
InvalidOwnerException,
|
||||
InvalidTaskStateException,
|
||||
|
@ -466,9 +776,29 @@ public class TaskController {
|
|||
* Workbasket the Task is in
|
||||
* @title Force complete a Task
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Force complete a Task",
|
||||
description = "This endpoint force completes a Task.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
description = "Id of the requested Task to force complete.",
|
||||
example = "TKI:000000000000000000000000000000000003",
|
||||
required = true)
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the force completed Task",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class)))
|
||||
})
|
||||
@PostMapping(path = RestEndpoints.URL_TASKS_ID_COMPLETE_FORCE)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> forceCompleteTask(@PathVariable String taskId)
|
||||
public ResponseEntity<TaskRepresentationModel> forceCompleteTask(
|
||||
@PathVariable("taskId") String taskId)
|
||||
throws TaskNotFoundException,
|
||||
InvalidOwnerException,
|
||||
InvalidTaskStateException,
|
||||
|
@ -491,9 +821,30 @@ public class TaskController {
|
|||
* Workbasket the Task is in
|
||||
* @title Cancel a Task
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Cancel a Task",
|
||||
description =
|
||||
"This endpoint cancels a Task. Cancellation marks a Task as obsolete. The actual work "
|
||||
+ "the Task was referring to is no longer required",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
description = "Id of the requested Task to cancel.",
|
||||
example = "TKI:000000000000000000000000000000000026",
|
||||
required = true)
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the cancelled Task",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class)))
|
||||
})
|
||||
@PostMapping(path = RestEndpoints.URL_TASKS_ID_CANCEL)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> cancelTask(@PathVariable String taskId)
|
||||
public ResponseEntity<TaskRepresentationModel> cancelTask(@PathVariable("taskId") String taskId)
|
||||
throws TaskNotFoundException, NotAuthorizedOnWorkbasketException, InvalidTaskStateException {
|
||||
|
||||
Task cancelledTask = taskService.cancelTask(taskId);
|
||||
|
@ -512,9 +863,31 @@ public class TaskController {
|
|||
* @throws NotAuthorizedOnWorkbasketException if the current user has not correct permissions
|
||||
* @title Terminate a Task
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Terminate a Task",
|
||||
description =
|
||||
"This endpoint terminates a Task. Termination is an administrative action to complete a "
|
||||
+ "Task.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
description = "Id of the requested Task to terminate.",
|
||||
required = true,
|
||||
example = "TKI:000000000000000000000000000000000000")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the terminated Task",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class)))
|
||||
})
|
||||
@PostMapping(path = RestEndpoints.URL_TASKS_ID_TERMINATE)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> terminateTask(@PathVariable String taskId)
|
||||
public ResponseEntity<TaskRepresentationModel> terminateTask(
|
||||
@PathVariable("taskId") String taskId)
|
||||
throws TaskNotFoundException,
|
||||
InvalidTaskStateException,
|
||||
NotAuthorizedException,
|
||||
|
@ -539,11 +912,42 @@ public class TaskController {
|
|||
* the Task.
|
||||
* @throws InvalidTaskStateException if the Task is in a state which does not allow transferring.
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Transfer a Task to another Workbasket",
|
||||
description = "This endpoint transfers a Task to a given Workbasket, if possible.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
description = "the Id of the Task which should be transferred",
|
||||
example = "TKI:000000000000000000000000000000000004",
|
||||
required = true),
|
||||
@Parameter(
|
||||
name = "workbasketId",
|
||||
description = "the Id of the destination Workbasket",
|
||||
example = "WBI:100000000000000000000000000000000001",
|
||||
required = true)
|
||||
},
|
||||
requestBody =
|
||||
@io.swagger.v3.oas.annotations.parameters.RequestBody(
|
||||
description = "sets the tansfer flag of the task (default: true)",
|
||||
content =
|
||||
@Content(
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class),
|
||||
examples = @ExampleObject(value = "{\"setTransferFlag\": false}"))),
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the successfully transferred Task.",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class)))
|
||||
})
|
||||
@PostMapping(path = RestEndpoints.URL_TASKS_ID_TRANSFER_WORKBASKET_ID)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> transferTask(
|
||||
@PathVariable String taskId,
|
||||
@PathVariable String workbasketId,
|
||||
@PathVariable("taskId") String taskId,
|
||||
@PathVariable("workbasketId") String workbasketId,
|
||||
@RequestBody(required = false) Boolean setTransferFlag)
|
||||
throws TaskNotFoundException,
|
||||
WorkbasketNotFoundException,
|
||||
|
@ -575,10 +979,126 @@ public class TaskController {
|
|||
* Task is not in state READY.
|
||||
* @title Update a Task
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Update a Task",
|
||||
description = "This endpoint updates a requested Task.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
description = "the Id of the Task which should be updated",
|
||||
example = "TKI:000000000000000000000000000000000003",
|
||||
required = true)
|
||||
},
|
||||
requestBody =
|
||||
@io.swagger.v3.oas.annotations.parameters.RequestBody(
|
||||
description = "the new Task for the requested id.",
|
||||
content =
|
||||
@Content(
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class),
|
||||
examples =
|
||||
@ExampleObject(
|
||||
value =
|
||||
"{\n"
|
||||
+ " \"taskId\": "
|
||||
+ "\"TKI:000000000000000000000000000000000003\",\n"
|
||||
+ " \"externalId\": "
|
||||
+ "\"ETI:000000000000000000000000000000000003\",\n"
|
||||
+ " \"created\": \"2018-02-01T12:00:00.000Z\",\n"
|
||||
+ " \"modified\": \"2018-02-01T12:00:00.000Z\",\n"
|
||||
+ " \"planned\": \"2024-05-27T15:27:56.595Z\",\n"
|
||||
+ " \"received\": \"2024-05-29T15:27:56.595Z\",\n"
|
||||
+ " \"due\": \"2024-05-29T15:27:56.595Z\",\n"
|
||||
+ " \"name\": \"Widerruf\",\n"
|
||||
+ " \"creator\": \"creator_user_id\",\n"
|
||||
+ " \"description\": \"new description\",\n"
|
||||
+ " \"priority\": 2,\n"
|
||||
+ " \"manualPriority\": -1,\n"
|
||||
+ " \"state\": \"READY\",\n"
|
||||
+ " \"classificationSummary\": {\n"
|
||||
+ " \"classificationId\": "
|
||||
+ "\"CLI:100000000000000000000000000000000003\",\n"
|
||||
+ " \"key\": \"L1050\",\n"
|
||||
+ " \"applicationEntryPoint\": \"\",\n"
|
||||
+ " \"category\": \"EXTERNAL\",\n"
|
||||
+ " \"domain\": \"DOMAIN_A\",\n"
|
||||
+ " \"name\": \"Widerruf\",\n"
|
||||
+ " \"parentId\": \"\",\n"
|
||||
+ " \"parentKey\": \"\",\n"
|
||||
+ " \"priority\": 1,\n"
|
||||
+ " \"serviceLevel\": \"P13D\",\n"
|
||||
+ " \"type\": \"TASK\",\n"
|
||||
+ " \"custom1\": \"VNR,RVNR,KOLVNR\",\n"
|
||||
+ " \"custom2\": \"\",\n"
|
||||
+ " \"custom3\": \"\",\n"
|
||||
+ " \"custom4\": \"\",\n"
|
||||
+ " \"custom5\": \"\",\n"
|
||||
+ " \"custom6\": \"\",\n"
|
||||
+ " \"custom7\": \"\",\n"
|
||||
+ " \"custom8\": \"\"\n"
|
||||
+ " },\n"
|
||||
+ " \"workbasketSummary\": {\n"
|
||||
+ " \"workbasketId\": "
|
||||
+ "\"WBI:100000000000000000000000000000000001\",\n"
|
||||
+ " \"key\": \"GPK_KSC\",\n"
|
||||
+ " \"name\": \"Gruppenpostkorb KSC\",\n"
|
||||
+ " \"domain\": \"DOMAIN_A\",\n"
|
||||
+ " \"type\": \"GROUP\",\n"
|
||||
+ " \"description\": \"Gruppenpostkorb KSC\",\n"
|
||||
+ " \"owner\": \"teamlead-1\",\n"
|
||||
+ " \"custom1\": \"ABCQVW\",\n"
|
||||
+ " \"custom2\": \"\",\n"
|
||||
+ " \"custom3\": \"xyz4\",\n"
|
||||
+ " \"custom4\": \"\",\n"
|
||||
+ " \"custom5\": \"\",\n"
|
||||
+ " \"custom6\": \"\",\n"
|
||||
+ " \"custom7\": \"\",\n"
|
||||
+ " \"custom8\": \"\",\n"
|
||||
+ " \"orgLevel1\": \"\",\n"
|
||||
+ " \"orgLevel2\": \"\",\n"
|
||||
+ " \"orgLevel3\": \"\",\n"
|
||||
+ " \"orgLevel4\": \"\",\n"
|
||||
+ " \"markedForDeletion\": false\n"
|
||||
+ " },\n"
|
||||
+ " \"businessProcessId\": \"PI_0000000000003\",\n"
|
||||
+ " \"parentBusinessProcessId\": "
|
||||
+ "\"DOC_0000000000000000003\",\n"
|
||||
+ " \"primaryObjRef\": {\n"
|
||||
+ " \"company\": \"00\",\n"
|
||||
+ " \"system\": \"PASystem\",\n"
|
||||
+ " \"systemInstance\": \"00\",\n"
|
||||
+ " \"type\": \"VNR\",\n"
|
||||
+ " \"value\": \"11223344\"\n"
|
||||
+ " },\n"
|
||||
+ " \"custom1\": \"efg\",\n"
|
||||
+ " \"custom14\": \"abc\",\n"
|
||||
+ " \"customInt1\": 1,\n"
|
||||
+ " \"customInt2\": 2,\n"
|
||||
+ " \"customInt3\": 3,\n"
|
||||
+ " \"customInt4\": 4,\n"
|
||||
+ " \"customInt5\": 5,\n"
|
||||
+ " \"customInt6\": 6,\n"
|
||||
+ " \"customInt7\": 7,\n"
|
||||
+ " \"customInt8\": 8,\n"
|
||||
+ " \"secondaryObjectReferences\": [],\n"
|
||||
+ " \"customAttributes\": [],\n"
|
||||
+ " \"callbackInfo\": [],\n"
|
||||
+ " \"attachments\": [],\n"
|
||||
+ " \"read\": false,\n"
|
||||
+ " \"transferred\": false\n"
|
||||
+ "}"))),
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the updated Task",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class)))
|
||||
})
|
||||
@PutMapping(path = RestEndpoints.URL_TASKS_ID)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> updateTask(
|
||||
@PathVariable(value = "taskId") String taskId,
|
||||
@PathVariable("taskId") String taskId,
|
||||
@RequestBody TaskRepresentationModel taskRepresentationModel)
|
||||
throws TaskNotFoundException,
|
||||
ClassificationNotFoundException,
|
||||
|
@ -621,10 +1141,37 @@ public class TaskController {
|
|||
* Workbasket the Task is in
|
||||
* @title Set a Task read or unread
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Set a Task read or unread",
|
||||
description = "This endpoint sets the 'isRead' property of a Task.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
description = "Id of the requested Task to set read or unread.",
|
||||
example = "TKI:000000000000000000000000000000000025",
|
||||
required = true)
|
||||
},
|
||||
requestBody =
|
||||
@io.swagger.v3.oas.annotations.parameters.RequestBody(
|
||||
description =
|
||||
"if true, the Task property isRead is set to true, else it's set to false",
|
||||
content =
|
||||
@Content(
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class),
|
||||
examples = @ExampleObject(value = "{\"is-read\": true}"))),
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the updated Task",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = TaskRepresentationModel.class)))
|
||||
})
|
||||
@PostMapping(path = RestEndpoints.URL_TASKS_ID_SET_READ)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> setTaskRead(
|
||||
@PathVariable String taskId, @RequestBody IsReadRepresentationModel isRead)
|
||||
@PathVariable("taskId") String taskId, @RequestBody IsReadRepresentationModel isRead)
|
||||
throws TaskNotFoundException, NotAuthorizedOnWorkbasketException {
|
||||
|
||||
Task updatedTask = taskService.setTaskRead(taskId, isRead.getIsRead());
|
||||
|
@ -648,9 +1195,20 @@ public class TaskController {
|
|||
* @throws NotAuthorizedOnWorkbasketException if the current user has not correct permissions
|
||||
* @throws InvalidCallbackStateException some comment
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Delete a Task",
|
||||
description = "This endpoint deletes a Task.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
description = "the Id of the Task which should be deleted.",
|
||||
required = true,
|
||||
example = "TKI:000000000000000000000000000000000039")
|
||||
},
|
||||
responses = {@ApiResponse(responseCode = "204", content = @Content(schema = @Schema()))})
|
||||
@DeleteMapping(path = RestEndpoints.URL_TASKS_ID)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> deleteTask(@PathVariable String taskId)
|
||||
public ResponseEntity<TaskRepresentationModel> deleteTask(@PathVariable("taskId") String taskId)
|
||||
throws TaskNotFoundException,
|
||||
InvalidTaskStateException,
|
||||
NotAuthorizedException,
|
||||
|
@ -674,9 +1232,21 @@ public class TaskController {
|
|||
* @throws NotAuthorizedOnWorkbasketException if the current user has not correct
|
||||
* @throws InvalidCallbackStateException some comment
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Force delete a Task",
|
||||
description = "This endpoint force deletes a Task.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "taskId",
|
||||
description = "the Id of the Task which should be force deleted.",
|
||||
example = "TKI:000000000000000000000000000000000005",
|
||||
required = true)
|
||||
},
|
||||
responses = {@ApiResponse(responseCode = "204", content = @Content(schema = @Schema()))})
|
||||
@DeleteMapping(path = RestEndpoints.URL_TASKS_ID_FORCE)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskRepresentationModel> forceDeleteTask(@PathVariable String taskId)
|
||||
public ResponseEntity<TaskRepresentationModel> forceDeleteTask(
|
||||
@PathVariable("taskId") String taskId)
|
||||
throws TaskNotFoundException,
|
||||
InvalidTaskStateException,
|
||||
NotAuthorizedException,
|
||||
|
@ -700,12 +1270,36 @@ public class TaskController {
|
|||
* @throws NotAuthorizedException if the current user is not authorized to delete the requested
|
||||
* Tasks.
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Delete multiple Tasks",
|
||||
description =
|
||||
"This endpoint deletes an aggregation of Tasks and returns the deleted Tasks. Filters "
|
||||
+ "can be applied.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "task-id",
|
||||
examples = {
|
||||
@ExampleObject(value = "TKI:000000000000000000000000000000000036"),
|
||||
@ExampleObject(value = "TKI:000000000000000000000000000000000037"),
|
||||
@ExampleObject(value = "TKI:000000000000000000000000000000000038")
|
||||
})
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the deleted task summaries",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema =
|
||||
@Schema(implementation = TaskSummaryCollectionRepresentationModel.class)))
|
||||
})
|
||||
@DeleteMapping(path = RestEndpoints.URL_TASKS)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<TaskSummaryCollectionRepresentationModel> deleteTasks(
|
||||
TaskQueryFilterParameter filterParameter,
|
||||
TaskQueryFilterCustomFields filterCustomFields,
|
||||
TaskQueryFilterCustomIntFields filterCustomIntFields)
|
||||
@ParameterObject TaskQueryFilterParameter filterParameter,
|
||||
@ParameterObject TaskQueryFilterCustomFields filterCustomFields,
|
||||
@ParameterObject TaskQueryFilterCustomIntFields filterCustomIntFields)
|
||||
throws InvalidArgumentException, NotAuthorizedException {
|
||||
TaskQuery query = taskService.createTaskQuery();
|
||||
filterParameter.apply(query);
|
||||
|
|
|
@ -20,6 +20,7 @@ import static pro.taskana.task.api.TaskCustomField.CUSTOM_8;
|
|||
import static pro.taskana.task.api.TaskCustomField.CUSTOM_9;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.Optional;
|
||||
import java.util.stream.Stream;
|
||||
|
@ -28,11 +29,271 @@ import pro.taskana.common.rest.QueryParameter;
|
|||
import pro.taskana.task.api.TaskQuery;
|
||||
|
||||
public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Void> {
|
||||
public String[] getCustom1In() {
|
||||
return custom1In;
|
||||
}
|
||||
|
||||
public String[] getCustom1NotIn() {
|
||||
return custom1NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom1Like() {
|
||||
return custom1Like;
|
||||
}
|
||||
|
||||
public String[] getCustom1NotLike() {
|
||||
return custom1NotLike;
|
||||
}
|
||||
|
||||
public String[] getCustom2In() {
|
||||
return custom2In;
|
||||
}
|
||||
|
||||
public String[] getCustom2NotIn() {
|
||||
return custom2NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom2Like() {
|
||||
return custom2Like;
|
||||
}
|
||||
|
||||
public String[] getCustom2NotLike() {
|
||||
return custom2NotLike;
|
||||
}
|
||||
|
||||
public String[] getCustom3In() {
|
||||
return custom3In;
|
||||
}
|
||||
|
||||
public String[] getCustom3NotIn() {
|
||||
return custom3NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom3Like() {
|
||||
return custom3Like;
|
||||
}
|
||||
|
||||
public String[] getCustom3NotLike() {
|
||||
return custom3NotLike;
|
||||
}
|
||||
|
||||
public String[] getCustom4In() {
|
||||
return custom4In;
|
||||
}
|
||||
|
||||
public String[] getCustom4NotIn() {
|
||||
return custom4NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom4Like() {
|
||||
return custom4Like;
|
||||
}
|
||||
|
||||
public String[] getCustom4NotLike() {
|
||||
return custom4NotLike;
|
||||
}
|
||||
|
||||
public String[] getCustom5In() {
|
||||
return custom5In;
|
||||
}
|
||||
|
||||
public String[] getCustom5NotIn() {
|
||||
return custom5NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom5Like() {
|
||||
return custom5Like;
|
||||
}
|
||||
|
||||
public String[] getCustom5NotLike() {
|
||||
return custom5NotLike;
|
||||
}
|
||||
|
||||
public String[] getCustom6In() {
|
||||
return custom6In;
|
||||
}
|
||||
|
||||
public String[] getCustom6NotIn() {
|
||||
return custom6NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom6Like() {
|
||||
return custom6Like;
|
||||
}
|
||||
|
||||
public String[] getCustom6NotLike() {
|
||||
return custom6NotLike;
|
||||
}
|
||||
|
||||
public String[] getCustom7In() {
|
||||
return custom7In;
|
||||
}
|
||||
|
||||
public String[] getCustom7NotIn() {
|
||||
return custom7NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom7Like() {
|
||||
return custom7Like;
|
||||
}
|
||||
|
||||
public String[] getCustom7NotLike() {
|
||||
return custom7NotLike;
|
||||
}
|
||||
|
||||
public String[] getCustom8In() {
|
||||
return custom8In;
|
||||
}
|
||||
|
||||
public String[] getCustom8NotIn() {
|
||||
return custom8NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom8Like() {
|
||||
return custom8Like;
|
||||
}
|
||||
|
||||
public String[] getCustom8NotLike() {
|
||||
return custom8NotLike;
|
||||
}
|
||||
|
||||
public String[] getCustom9In() {
|
||||
return custom9In;
|
||||
}
|
||||
|
||||
public String[] getCustom9NotIn() {
|
||||
return custom9NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom9Like() {
|
||||
return custom9Like;
|
||||
}
|
||||
|
||||
public String[] getCustom9NotLike() {
|
||||
return custom9NotLike;
|
||||
}
|
||||
|
||||
public String[] getCustom10In() {
|
||||
return custom10In;
|
||||
}
|
||||
|
||||
public String[] getCustom10NotIn() {
|
||||
return custom10NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom10Like() {
|
||||
return custom10Like;
|
||||
}
|
||||
|
||||
public String[] getCustom10NotLike() {
|
||||
return custom10NotLike;
|
||||
}
|
||||
|
||||
public String[] getCustom11In() {
|
||||
return custom11In;
|
||||
}
|
||||
|
||||
public String[] getCustom11NotIn() {
|
||||
return custom11NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom11Like() {
|
||||
return custom11Like;
|
||||
}
|
||||
|
||||
public String[] getCustom11NotLike() {
|
||||
return custom11NotLike;
|
||||
}
|
||||
|
||||
public String[] getCustom12In() {
|
||||
return custom12In;
|
||||
}
|
||||
|
||||
public String[] getCustom12NotIn() {
|
||||
return custom12NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom12Like() {
|
||||
return custom12Like;
|
||||
}
|
||||
|
||||
public String[] getCustom12NotLike() {
|
||||
return custom12NotLike;
|
||||
}
|
||||
|
||||
public String[] getCustom13In() {
|
||||
return custom13In;
|
||||
}
|
||||
|
||||
public String[] getCustom13NotIn() {
|
||||
return custom13NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom13Like() {
|
||||
return custom13Like;
|
||||
}
|
||||
|
||||
public String[] getCustom13NotLike() {
|
||||
return custom13NotLike;
|
||||
}
|
||||
|
||||
public String[] getCustom14In() {
|
||||
return custom14In;
|
||||
}
|
||||
|
||||
public String[] getCustom14NotIn() {
|
||||
return custom14NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom14Like() {
|
||||
return custom14Like;
|
||||
}
|
||||
|
||||
public String[] getCustom14NotLike() {
|
||||
return custom14NotLike;
|
||||
}
|
||||
|
||||
public String[] getCustom15In() {
|
||||
return custom15In;
|
||||
}
|
||||
|
||||
public String[] getCustom15NotIn() {
|
||||
return custom15NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom15Like() {
|
||||
return custom15Like;
|
||||
}
|
||||
|
||||
public String[] getCustom15NotLike() {
|
||||
return custom15NotLike;
|
||||
}
|
||||
|
||||
public String[] getCustom16In() {
|
||||
return custom16In;
|
||||
}
|
||||
|
||||
public String[] getCustom16NotIn() {
|
||||
return custom16NotIn;
|
||||
}
|
||||
|
||||
public String[] getCustom16Like() {
|
||||
return custom16Like;
|
||||
}
|
||||
|
||||
public String[] getCustom16NotLike() {
|
||||
return custom16NotLike;
|
||||
}
|
||||
|
||||
/** Filter by the value of the field custom1 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-1",
|
||||
description = "Filter by the value of the field custom1 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-1")
|
||||
private final String[] custom1In;
|
||||
|
||||
/** Exclude values of the field custom1 of the Task. */
|
||||
@Schema(name = "custom-1-not", description = "Exclude values of the field custom1 of the Task.")
|
||||
@JsonProperty("custom-1-not")
|
||||
private final String[] custom1NotIn;
|
||||
|
||||
|
@ -41,6 +302,12 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-1-like",
|
||||
description =
|
||||
"Filter by the custom1 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-1-like")
|
||||
private final String[] custom1Like;
|
||||
|
||||
|
@ -49,14 +316,27 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* (% is appended to the front and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-1-not-like",
|
||||
description =
|
||||
"Filter by what the custom1 field of the Task shouldn't be. This results in a substring"
|
||||
+ " search (% is appended to the front and end of the requested value). Further SQL "
|
||||
+ "\"LIKE\" wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-1-not-like")
|
||||
private final String[] custom1NotLike;
|
||||
|
||||
/** Filter by the value of the field custom2 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-2",
|
||||
description = "Filter by the value of the field custom2 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-2")
|
||||
private final String[] custom2In;
|
||||
|
||||
/** Filter out by values of the field custom2 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-2-not",
|
||||
description =
|
||||
"Filter out by values of the field custom2 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-2-not")
|
||||
private final String[] custom2NotIn;
|
||||
|
||||
|
@ -65,6 +345,12 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-2-like",
|
||||
description =
|
||||
"Filter by the custom2 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-2-like")
|
||||
private final String[] custom2Like;
|
||||
|
||||
|
@ -73,14 +359,27 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* (% is appended to the front and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-2-not-like",
|
||||
description =
|
||||
"Filter by what the custom2 field of the Task shouldn't be. This results in a substring"
|
||||
+ " search (% is appended to the front and end of the requested value). Further SQL "
|
||||
+ "\"LIKE\" wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-2-not-like")
|
||||
private final String[] custom2NotLike;
|
||||
|
||||
/** Filter by the value of the field custom3 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-3",
|
||||
description = "Filter by the value of the field custom3 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-3")
|
||||
private final String[] custom3In;
|
||||
|
||||
/** Filter out by values of the field custom3 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-3-not",
|
||||
description =
|
||||
"Filter out by values of the field custom3 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-3-not")
|
||||
private final String[] custom3NotIn;
|
||||
|
||||
|
@ -89,6 +388,12 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-3-like",
|
||||
description =
|
||||
"Filter by the custom3 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-3-like")
|
||||
private final String[] custom3Like;
|
||||
|
||||
|
@ -97,14 +402,27 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* (% is appended to the front and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-3-not-like",
|
||||
description =
|
||||
"Filter by what the custom3 field of the Task shouldn't be. This results in a substring"
|
||||
+ " search (% is appended to the front and end of the requested value). Further SQL "
|
||||
+ "\"LIKE\" wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-3-not-like")
|
||||
private final String[] custom3NotLike;
|
||||
|
||||
/** Filter by the value of the field custom4 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-4",
|
||||
description = "Filter by the value of the field custom4 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-4")
|
||||
private final String[] custom4In;
|
||||
|
||||
/** Filter out by values of the field custom4 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-4-not",
|
||||
description =
|
||||
"Filter out by values of the field custom4 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-4-not")
|
||||
private final String[] custom4NotIn;
|
||||
|
||||
|
@ -113,6 +431,12 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-4-like",
|
||||
description =
|
||||
"Filter by the custom4 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-4-like")
|
||||
private final String[] custom4Like;
|
||||
|
||||
|
@ -121,14 +445,27 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* (% is appended to the front and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-4-not-like",
|
||||
description =
|
||||
"Filter by what the custom4 field of the Task shouldn't be. This results in a substring"
|
||||
+ " search (% is appended to the front and end of the requested value). Further SQL "
|
||||
+ "\"LIKE\" wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-4-not-like")
|
||||
private final String[] custom4NotLike;
|
||||
|
||||
/** Filter by the value of the field custom5 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-5",
|
||||
description = "Filter by the value of the field custom5 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-5")
|
||||
private final String[] custom5In;
|
||||
|
||||
/** Filter out by values of the field custom5 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-5-not",
|
||||
description =
|
||||
"Filter out by values of the field custom5 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-5-not")
|
||||
private final String[] custom5NotIn;
|
||||
|
||||
|
@ -137,6 +474,12 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-5-like",
|
||||
description =
|
||||
"Filter by the custom5 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-5-like")
|
||||
private final String[] custom5Like;
|
||||
|
||||
|
@ -145,14 +488,27 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* (% is appended to the front and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-5-not-like",
|
||||
description =
|
||||
"Filter by what the custom5 field of the Task shouldn't be. This results in a substring"
|
||||
+ " search (% is appended to the front and end of the requested value). Further SQL "
|
||||
+ "\"LIKE\" wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-5-not-like")
|
||||
private final String[] custom5NotLike;
|
||||
|
||||
/** Filter by the value of the field custom6 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-6",
|
||||
description = "Filter by the value of the field custom6 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-6")
|
||||
private final String[] custom6In;
|
||||
|
||||
/** Filter out by values of the field custom6 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-6-not",
|
||||
description =
|
||||
"Filter out by values of the field custom6 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-6-not")
|
||||
private final String[] custom6NotIn;
|
||||
|
||||
|
@ -161,6 +517,12 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-6-like",
|
||||
description =
|
||||
"Filter by the custom6 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-6-like")
|
||||
private final String[] custom6Like;
|
||||
|
||||
|
@ -169,14 +531,27 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* (% is appended to the front and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-6-not-like",
|
||||
description =
|
||||
"Filter by what the custom6 field of the Task shouldn't be. This results in a substring"
|
||||
+ " search (% is appended to the front and end of the requested value). Further SQL "
|
||||
+ "\"LIKE\" wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-6-not-like")
|
||||
private final String[] custom6NotLike;
|
||||
|
||||
/** Filter by the value of the field custom7 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-7",
|
||||
description = "Filter by the value of the field custom7 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-7")
|
||||
private final String[] custom7In;
|
||||
|
||||
/** Filter out by values of the field custom7 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-7-not",
|
||||
description =
|
||||
"Filter out by values of the field custom7 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-7-not")
|
||||
private final String[] custom7NotIn;
|
||||
|
||||
|
@ -185,6 +560,12 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-7-like",
|
||||
description =
|
||||
"Filter by the custom7 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-7-like")
|
||||
private final String[] custom7Like;
|
||||
|
||||
|
@ -193,14 +574,27 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* (% is appended to the front and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-7-not-like",
|
||||
description =
|
||||
"Filter by what the custom7 field of the Task shouldn't be. This results in a substring"
|
||||
+ " search (% is appended to the front and end of the requested value). Further SQL "
|
||||
+ "\"LIKE\" wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-7-not-like")
|
||||
private final String[] custom7NotLike;
|
||||
|
||||
/** Filter by the value of the field custom8 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-8",
|
||||
description = "Filter by the value of the field custom8 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-8")
|
||||
private final String[] custom8In;
|
||||
|
||||
/** Filter out by values of the field custom8 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-8-not",
|
||||
description =
|
||||
"Filter out by values of the field custom8 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-8-not")
|
||||
private final String[] custom8NotIn;
|
||||
|
||||
|
@ -209,6 +603,12 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-8-like",
|
||||
description =
|
||||
"Filter by the custom8 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-8-like")
|
||||
private final String[] custom8Like;
|
||||
|
||||
|
@ -217,14 +617,27 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* (% is appended to the front and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-8-not-like",
|
||||
description =
|
||||
"Filter by what the custom8 field of the Task shouldn't be. This results in a substring"
|
||||
+ " search (% is appended to the front and end of the requested value). Further SQL "
|
||||
+ "\"LIKE\" wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-8-not-like")
|
||||
private final String[] custom8NotLike;
|
||||
|
||||
/** Filter by the value of the field custom9 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-9",
|
||||
description = "Filter by the value of the field custom9 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-9")
|
||||
private final String[] custom9In;
|
||||
|
||||
/** Filter out by values of the field custom9 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-9-not",
|
||||
description =
|
||||
"Filter out by values of the field custom9 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-9-not")
|
||||
private final String[] custom9NotIn;
|
||||
|
||||
|
@ -233,6 +646,12 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-9-like",
|
||||
description =
|
||||
"Filter by the custom9 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-9-like")
|
||||
private final String[] custom9Like;
|
||||
|
||||
|
@ -241,14 +660,28 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* (% is appended to the front and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-9-not-like",
|
||||
description =
|
||||
"Filter by what the custom9 field of the Task shouldn't be. This results in a substring"
|
||||
+ " search (% is appended to the front and end of the requested value). Further SQL "
|
||||
+ "\"LIKE\" wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-9-not-like")
|
||||
private final String[] custom9NotLike;
|
||||
|
||||
/** Filter by the value of the field custom10 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-10",
|
||||
description =
|
||||
"Filter by the value of the field custom10 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-10")
|
||||
private final String[] custom10In;
|
||||
|
||||
/** Filter out by values of the field custom10 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-10-not",
|
||||
description =
|
||||
"Filter out by values of the field custom10 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-10-not")
|
||||
private final String[] custom10NotIn;
|
||||
|
||||
|
@ -257,6 +690,12 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-10-like",
|
||||
description =
|
||||
"Filter by the custom10 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-10-like")
|
||||
private final String[] custom10Like;
|
||||
|
||||
|
@ -265,14 +704,28 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* (% is appended to the front and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-10-not-like",
|
||||
description =
|
||||
"Filter by what the custom10 field of the Task shouldn't be. This results in a substring"
|
||||
+ " search (% is appended to the front and end of the requested value). Further SQL "
|
||||
+ "\"LIKE\" wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-10-not-like")
|
||||
private final String[] custom10NotLike;
|
||||
|
||||
/** Filter by the value of the field custom11 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-11",
|
||||
description =
|
||||
"Filter by the value of the field custom11 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-11")
|
||||
private final String[] custom11In;
|
||||
|
||||
/** Filter out by values of the field custom11 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-11-not",
|
||||
description =
|
||||
"Filter out by values of the field custom11 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-11-not")
|
||||
private final String[] custom11NotIn;
|
||||
|
||||
|
@ -281,6 +734,12 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-11-like",
|
||||
description =
|
||||
"Filter by the custom11 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-11-like")
|
||||
private final String[] custom11Like;
|
||||
|
||||
|
@ -289,14 +748,28 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* (% is appended to the front and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-11-not-like",
|
||||
description =
|
||||
"Filter by what the custom11 field of the Task shouldn't be. This results in a substring"
|
||||
+ " search (% is appended to the front and end of the requested value). Further SQL "
|
||||
+ "\"LIKE\" wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-11-not-like")
|
||||
private final String[] custom11NotLike;
|
||||
|
||||
/** Filter by the value of the field custom12 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-12",
|
||||
description =
|
||||
"Filter by the value of the field custom12 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-12")
|
||||
private final String[] custom12In;
|
||||
|
||||
/** Filter out by values of the field custom12 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-12-not",
|
||||
description =
|
||||
"Filter out by values of the field custom12 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-12-not")
|
||||
private final String[] custom12NotIn;
|
||||
|
||||
|
@ -305,6 +778,12 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-12-like",
|
||||
description =
|
||||
"Filter by the custom12 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-12-like")
|
||||
private final String[] custom12Like;
|
||||
|
||||
|
@ -313,14 +792,28 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* (% is appended to the front and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-12-not-like",
|
||||
description =
|
||||
"Filter by what the custom12 field of the Task shouldn't be. This results in a substring"
|
||||
+ " search (% is appended to the front and end of the requested value). Further SQL "
|
||||
+ "\"LIKE\" wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-12-not-like")
|
||||
private final String[] custom12NotLike;
|
||||
|
||||
/** Filter by the value of the field custom13 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-13",
|
||||
description =
|
||||
"Filter by the value of the field custom13 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-13")
|
||||
private final String[] custom13In;
|
||||
|
||||
/** Filter out by values of the field custom13 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-13-not",
|
||||
description =
|
||||
"Filter out by values of the field custom13 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-13-not")
|
||||
private final String[] custom13NotIn;
|
||||
|
||||
|
@ -329,6 +822,12 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-13-like",
|
||||
description =
|
||||
"Filter by the custom13 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-13-like")
|
||||
private final String[] custom13Like;
|
||||
|
||||
|
@ -337,14 +836,28 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* (% is appended to the front and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-13-not-like",
|
||||
description =
|
||||
"Filter by what the custom13 field of the Task shouldn't be. This results in a substring"
|
||||
+ " search (% is appended to the front and end of the requested value). Further SQL "
|
||||
+ "\"LIKE\" wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-13-not-like")
|
||||
private final String[] custom13NotLike;
|
||||
|
||||
/** Filter by the value of the field custom14 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-14",
|
||||
description =
|
||||
"Filter by the value of the field custom14 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-14")
|
||||
private final String[] custom14In;
|
||||
|
||||
/** Filter out by values of the field custom14 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-14-not",
|
||||
description =
|
||||
"Filter out by values of the field custom14 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-14-not")
|
||||
private final String[] custom14NotIn;
|
||||
|
||||
|
@ -353,6 +866,12 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-14-like",
|
||||
description =
|
||||
"Filter by the custom14 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-14-like")
|
||||
private final String[] custom14Like;
|
||||
|
||||
|
@ -361,14 +880,28 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* (% is appended to the front and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-14-not-like",
|
||||
description =
|
||||
"Filter by what the custom14 field of the Task shouldn't be. This results in a substring"
|
||||
+ " search (% is appended to the front and end of the requested value). Further SQL "
|
||||
+ "\"LIKE\" wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-14-not-like")
|
||||
private final String[] custom14NotLike;
|
||||
|
||||
/** Filter by the value of the field custom15 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-15",
|
||||
description =
|
||||
"Filter by the value of the field custom15 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-15")
|
||||
private final String[] custom15In;
|
||||
|
||||
/** Filter out by values of the field custom15 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-15-not",
|
||||
description =
|
||||
"Filter out by values of the field custom15 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-15-not")
|
||||
private final String[] custom15NotIn;
|
||||
|
||||
|
@ -377,6 +910,12 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-15-like",
|
||||
description =
|
||||
"Filter by the custom15 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-15-like")
|
||||
private final String[] custom15Like;
|
||||
|
||||
|
@ -385,21 +924,42 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* (% is appended to the front and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-15-not-like",
|
||||
description =
|
||||
"Filter by what the custom15 field of the Task shouldn't be. This results in a substring"
|
||||
+ " search (% is appended to the front and end of the requested value). Further SQL "
|
||||
+ "\"LIKE\" wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-15-not-like")
|
||||
private final String[] custom15NotLike;
|
||||
|
||||
/** Filter by the value of the field custom16 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-16",
|
||||
description =
|
||||
"Filter by the value of the field custom16 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-16")
|
||||
private final String[] custom16In;
|
||||
|
||||
/** Filter out by values of the field custom16 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-16-not",
|
||||
description =
|
||||
"Filter out by values of the field custom16 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-16-not")
|
||||
private final String[] custom16NotIn;
|
||||
|
||||
/**
|
||||
* Filter by the custom16 field of the Task. This results in a substring search (% is appended to
|
||||
* the front and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-16-like",
|
||||
description =
|
||||
"Filter by the custom16 field of the Task. This results in a substring search (% is "
|
||||
+ "appended to the front and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-16-like")
|
||||
private final String[] custom16Like;
|
||||
|
||||
|
@ -408,6 +968,12 @@ public class TaskQueryFilterCustomFields implements QueryParameter<TaskQuery, Vo
|
|||
* (% is appended to the front and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-16-not-like",
|
||||
description =
|
||||
"Filter by what the custom16 field of the Task shouldn't be. This results in a substring"
|
||||
+ " search (% is appended to the front and end of the requested value). Further SQL "
|
||||
+ "\"LIKE\" wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("custom-16-not-like")
|
||||
private final String[] custom16NotLike;
|
||||
|
||||
|
|
|
@ -3,6 +3,7 @@ package pro.taskana.task.rest;
|
|||
import static pro.taskana.common.internal.util.CheckedConsumer.wrap;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
|
@ -17,17 +18,285 @@ import pro.taskana.task.api.TaskCustomIntField;
|
|||
import pro.taskana.task.api.TaskQuery;
|
||||
|
||||
public class TaskQueryFilterCustomIntFields implements QueryParameter<TaskQuery, Void> {
|
||||
public Integer[] getCustomInt1In() {
|
||||
return customInt1In;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt1NotIn() {
|
||||
return customInt1NotIn;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt1Within() {
|
||||
return customInt1Within;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt1NotWithin() {
|
||||
return customInt1NotWithin;
|
||||
}
|
||||
|
||||
public Integer getCustomInt1From() {
|
||||
return customInt1From;
|
||||
}
|
||||
|
||||
public Integer getCustomInt1FromNot() {
|
||||
return customInt1FromNot;
|
||||
}
|
||||
|
||||
public Integer getCustomInt1To() {
|
||||
return customInt1To;
|
||||
}
|
||||
|
||||
public Integer getCustomInt1ToNot() {
|
||||
return customInt1ToNot;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt2In() {
|
||||
return customInt2In;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt2NotIn() {
|
||||
return customInt2NotIn;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt2Within() {
|
||||
return customInt2Within;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt2NotWithin() {
|
||||
return customInt2NotWithin;
|
||||
}
|
||||
|
||||
public Integer getCustomInt2From() {
|
||||
return customInt2From;
|
||||
}
|
||||
|
||||
public Integer getCustomInt2FromNot() {
|
||||
return customInt2FromNot;
|
||||
}
|
||||
|
||||
public Integer getCustomInt2To() {
|
||||
return customInt2To;
|
||||
}
|
||||
|
||||
public Integer getCustomInt2ToNot() {
|
||||
return customInt2ToNot;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt3In() {
|
||||
return customInt3In;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt3NotIn() {
|
||||
return customInt3NotIn;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt3Within() {
|
||||
return customInt3Within;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt3NotWithin() {
|
||||
return customInt3NotWithin;
|
||||
}
|
||||
|
||||
public Integer getCustomInt3From() {
|
||||
return customInt3From;
|
||||
}
|
||||
|
||||
public Integer getCustomInt3FromNot() {
|
||||
return customInt3FromNot;
|
||||
}
|
||||
|
||||
public Integer getCustomInt3To() {
|
||||
return customInt3To;
|
||||
}
|
||||
|
||||
public Integer getCustomInt3ToNot() {
|
||||
return customInt3ToNot;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt4In() {
|
||||
return customInt4In;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt4NotIn() {
|
||||
return customInt4NotIn;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt4Within() {
|
||||
return customInt4Within;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt4NotWithin() {
|
||||
return customInt4NotWithin;
|
||||
}
|
||||
|
||||
public Integer getCustomInt4From() {
|
||||
return customInt4From;
|
||||
}
|
||||
|
||||
public Integer getCustomInt4FromNot() {
|
||||
return customInt4FromNot;
|
||||
}
|
||||
|
||||
public Integer getCustomInt4To() {
|
||||
return customInt4To;
|
||||
}
|
||||
|
||||
public Integer getCustomInt4ToNot() {
|
||||
return customInt4ToNot;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt5In() {
|
||||
return customInt5In;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt5NotIn() {
|
||||
return customInt5NotIn;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt5Within() {
|
||||
return customInt5Within;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt5NotWithin() {
|
||||
return customInt5NotWithin;
|
||||
}
|
||||
|
||||
public Integer getCustomInt5From() {
|
||||
return customInt5From;
|
||||
}
|
||||
|
||||
public Integer getCustomInt5FromNot() {
|
||||
return customInt5FromNot;
|
||||
}
|
||||
|
||||
public Integer getCustomInt5To() {
|
||||
return customInt5To;
|
||||
}
|
||||
|
||||
public Integer getCustomInt5ToNot() {
|
||||
return customInt5ToNot;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt6In() {
|
||||
return customInt6In;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt6NotIn() {
|
||||
return customInt6NotIn;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt6Within() {
|
||||
return customInt6Within;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt6NotWithin() {
|
||||
return customInt6NotWithin;
|
||||
}
|
||||
|
||||
public Integer getCustomInt6From() {
|
||||
return customInt6From;
|
||||
}
|
||||
|
||||
public Integer getCustomInt6FromNot() {
|
||||
return customInt6FromNot;
|
||||
}
|
||||
|
||||
public Integer getCustomInt6To() {
|
||||
return customInt6To;
|
||||
}
|
||||
|
||||
public Integer getCustomInt6ToNot() {
|
||||
return customInt6ToNot;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt7In() {
|
||||
return customInt7In;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt7NotIn() {
|
||||
return customInt7NotIn;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt7Within() {
|
||||
return customInt7Within;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt7NotWithin() {
|
||||
return customInt7NotWithin;
|
||||
}
|
||||
|
||||
public Integer getCustomInt7From() {
|
||||
return customInt7From;
|
||||
}
|
||||
|
||||
public Integer getCustomInt7FromNot() {
|
||||
return customInt7FromNot;
|
||||
}
|
||||
|
||||
public Integer getCustomInt7To() {
|
||||
return customInt7To;
|
||||
}
|
||||
|
||||
public Integer getCustomInt7ToNot() {
|
||||
return customInt7ToNot;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt8In() {
|
||||
return customInt8In;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt8NotIn() {
|
||||
return customInt8NotIn;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt8Within() {
|
||||
return customInt8Within;
|
||||
}
|
||||
|
||||
public Integer[] getCustomInt8NotWithin() {
|
||||
return customInt8NotWithin;
|
||||
}
|
||||
|
||||
public Integer getCustomInt8From() {
|
||||
return customInt8From;
|
||||
}
|
||||
|
||||
public Integer getCustomInt8FromNot() {
|
||||
return customInt8FromNot;
|
||||
}
|
||||
|
||||
public Integer getCustomInt8To() {
|
||||
return customInt8To;
|
||||
}
|
||||
|
||||
public Integer getCustomInt8ToNot() {
|
||||
return customInt8ToNot;
|
||||
}
|
||||
|
||||
/** Filter by the value of the field customInt1 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-int-1",
|
||||
description =
|
||||
"Filter by the value of the field customInt1 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-int-1")
|
||||
private final Integer[] customInt1In;
|
||||
/** Exclude values of the field customInt1 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-1-not",
|
||||
description = "Exclude values of the field customInt1 of the Task.")
|
||||
@JsonProperty("custom-int-1-not")
|
||||
private final Integer[] customInt1NotIn;
|
||||
/** Filter by the range of value of the field customInt1 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-1-within",
|
||||
description = "Filter by the range of value of the field customInt1 of the Task.")
|
||||
@JsonProperty("custom-int-1-within")
|
||||
private final Integer[] customInt1Within;
|
||||
/** Exclude range of values of the field customInt1 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-1-not-within",
|
||||
description = "Exclude range of values of the field customInt1 of the Task.")
|
||||
@JsonProperty("custom-int-1-not-within")
|
||||
private final Integer[] customInt1NotWithin;
|
||||
|
||||
|
@ -36,9 +305,17 @@ public class TaskQueryFilterCustomIntFields implements QueryParameter<TaskQuery,
|
|||
*
|
||||
* <p>This parameter can't be used together with 'custom-int-1-within'.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-int-1-from",
|
||||
description =
|
||||
"Filter by lower bound of customInt1. <p>This parameter can't be used together with "
|
||||
+ "'custom-int-1-within'.")
|
||||
@JsonProperty("custom-int-1-from")
|
||||
private final Integer customInt1From;
|
||||
/** Exclude values from a lower bound of the field customInt1 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-1-from-not",
|
||||
description = "Exclude values from a lower bound of the field customInt1 of the Task.")
|
||||
@JsonProperty("custom-int-1-from-not")
|
||||
private final Integer customInt1FromNot;
|
||||
/**
|
||||
|
@ -46,24 +323,45 @@ public class TaskQueryFilterCustomIntFields implements QueryParameter<TaskQuery,
|
|||
*
|
||||
* <p>This parameter can't be used together with 'custom-int-1-within'.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-int-1-to",
|
||||
description =
|
||||
"Filter by upper bound of customInt1. <p>This parameter can't be used together with "
|
||||
+ "'custom-int-1-within'.")
|
||||
@JsonProperty("custom-int-1-to")
|
||||
private final Integer customInt1To;
|
||||
|
||||
/** Exclude values to an upper bound of the field customInt1 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-1-to-not",
|
||||
description = "Exclude values to an upper bound of the field customInt1 of the Task.")
|
||||
@JsonProperty("custom-int-1-to-not")
|
||||
private final Integer customInt1ToNot;
|
||||
|
||||
/** Filter by the value of the field customInt2 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-int-2",
|
||||
description =
|
||||
"Filter by the value of the field customInt2 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-int-2")
|
||||
private final Integer[] customInt2In;
|
||||
|
||||
/** Exclude values of the field customInt2 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-2-not",
|
||||
description = "Exclude values of the field customInt2 of the Task.")
|
||||
@JsonProperty("custom-int-2-not")
|
||||
private final Integer[] customInt2NotIn;
|
||||
/** Filter by the range of value of the field customInt2 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-2-within",
|
||||
description = "Filter by the range of value of the field customInt2 of the Task.")
|
||||
@JsonProperty("custom-int-2-within")
|
||||
private final Integer[] customInt2Within;
|
||||
/** Exclude range of values of the field customInt2 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-2-not-within",
|
||||
description = "Exclude range of values of the field customInt2 of the Task.")
|
||||
@JsonProperty("custom-int-2-not-within")
|
||||
private final Integer[] customInt2NotWithin;
|
||||
/**
|
||||
|
@ -71,9 +369,17 @@ public class TaskQueryFilterCustomIntFields implements QueryParameter<TaskQuery,
|
|||
*
|
||||
* <p>This parameter can't be used together with 'custom-int-2-within'.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-int-2-from",
|
||||
description =
|
||||
"Filter by lower bound of customInt2. <p>This parameter can't be used together with "
|
||||
+ "'custom-int-2-within'.")
|
||||
@JsonProperty("custom-int-2-from")
|
||||
private final Integer customInt2From;
|
||||
/** Exclude values from a lower bound of the field customInt2 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-2-from-not",
|
||||
description = "Exclude values from a lower bound of the field customInt2 of the Task.")
|
||||
@JsonProperty("custom-int-2-from-not")
|
||||
private final Integer customInt2FromNot;
|
||||
/**
|
||||
|
@ -81,22 +387,43 @@ public class TaskQueryFilterCustomIntFields implements QueryParameter<TaskQuery,
|
|||
*
|
||||
* <p>This parameter can't be used together with 'custom-int-2-within'.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-int-2-to",
|
||||
description =
|
||||
"Filter by upper bound of customInt2. <p>This parameter can't be used together with "
|
||||
+ "'custom-int-2-within'.")
|
||||
@JsonProperty("custom-int-2-to")
|
||||
private final Integer customInt2To;
|
||||
/** Exclude values to an upper bound of the field customInt2 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-2-to-not",
|
||||
description = "Exclude values to an upper bound of the field customInt2 of the Task.")
|
||||
@JsonProperty("custom-int-2-to-not")
|
||||
private final Integer customInt2ToNot;
|
||||
/** Filter by the value of the field customInt3 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-int-3",
|
||||
description =
|
||||
"Filter by the value of the field customInt3 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-int-3")
|
||||
private final Integer[] customInt3In;
|
||||
|
||||
/** Exclude values of the field customInt3 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-3-not",
|
||||
description = "Exclude values of the field customInt3 of the Task.")
|
||||
@JsonProperty("custom-int-3-not")
|
||||
private final Integer[] customInt3NotIn;
|
||||
/** Filter by the range of value of the field customInt3 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-3-within",
|
||||
description = "Filter by the range of value of the field customInt3 of the Task.")
|
||||
@JsonProperty("custom-int-3-within")
|
||||
private final Integer[] customInt3Within;
|
||||
/** Exclude range of values of the field customInt3 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-3-not-within",
|
||||
description = "Exclude range of values of the field customInt3 of the Task.")
|
||||
@JsonProperty("custom-int-3-not-within")
|
||||
private final Integer[] customInt3NotWithin;
|
||||
/**
|
||||
|
@ -104,9 +431,17 @@ public class TaskQueryFilterCustomIntFields implements QueryParameter<TaskQuery,
|
|||
*
|
||||
* <p>This parameter can't be used together with 'custom-int-3-within'.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-int-3-from",
|
||||
description =
|
||||
"Filter by lower bound of customInt3. <p>This parameter can't be used together with "
|
||||
+ "'custom-int-3-within'.")
|
||||
@JsonProperty("custom-int-3-from")
|
||||
private final Integer customInt3From;
|
||||
/** Exclude values from a lower bound of the field customInt3 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-3-from-not",
|
||||
description = "Exclude values from a lower bound of the field customInt3 of the Task.")
|
||||
@JsonProperty("custom-int-3-from-not")
|
||||
private final Integer customInt3FromNot;
|
||||
/**
|
||||
|
@ -114,22 +449,43 @@ public class TaskQueryFilterCustomIntFields implements QueryParameter<TaskQuery,
|
|||
*
|
||||
* <p>This parameter can't be used together with 'custom-int-3-within'.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-int-3-to",
|
||||
description =
|
||||
"Filter by upper bound of customInt3. <p>This parameter can't be used together with "
|
||||
+ "'custom-int-3-within'.")
|
||||
@JsonProperty("custom-int-3-to")
|
||||
private final Integer customInt3To;
|
||||
/** Exclude values to an upper bound of the field customInt3 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-3-to-not",
|
||||
description = "Exclude values to an upper bound of the field customInt3 of the Task.")
|
||||
@JsonProperty("custom-int-3-to-not")
|
||||
private final Integer customInt3ToNot;
|
||||
/** Filter by the value of the field customInt4 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-int-4",
|
||||
description =
|
||||
"Filter by the value of the field customInt4 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-int-4")
|
||||
private final Integer[] customInt4In;
|
||||
|
||||
/** Exclude values of the field customInt4 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-4-not",
|
||||
description = "Exclude values of the field customInt4 of the Task.")
|
||||
@JsonProperty("custom-int-4-not")
|
||||
private final Integer[] customInt4NotIn;
|
||||
/** Filter by the range of value of the field customInt4 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-4-within",
|
||||
description = "Filter by the range of value of the field customInt4 of the Task.")
|
||||
@JsonProperty("custom-int-4-within")
|
||||
private final Integer[] customInt4Within;
|
||||
/** Exclude range of values of the field customInt4 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-4-not-within",
|
||||
description = "Exclude range of values of the field customInt4 of the Task.")
|
||||
@JsonProperty("custom-int-4-not-within")
|
||||
private final Integer[] customInt4NotWithin;
|
||||
/**
|
||||
|
@ -137,9 +493,17 @@ public class TaskQueryFilterCustomIntFields implements QueryParameter<TaskQuery,
|
|||
*
|
||||
* <p>This parameter can't be used together with 'custom-int-4-within'.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-int-4-from",
|
||||
description =
|
||||
"Filter by lower bound of customInt4. <p>This parameter can't be used together with "
|
||||
+ "'custom-int-4-within'.")
|
||||
@JsonProperty("custom-int-4-from")
|
||||
private final Integer customInt4From;
|
||||
/** Exclude values from a lower bound of the field customInt4 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-4-from-not",
|
||||
description = "Exclude values from a lower bound of the field customInt4 of the Task.")
|
||||
@JsonProperty("custom-int-4-from-not")
|
||||
private final Integer customInt4FromNot;
|
||||
/**
|
||||
|
@ -147,22 +511,43 @@ public class TaskQueryFilterCustomIntFields implements QueryParameter<TaskQuery,
|
|||
*
|
||||
* <p>This parameter can't be used together with 'custom-int-4-within'.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-int-4-to",
|
||||
description =
|
||||
"Filter by upper bound of customInt4. <p>This parameter can't be used together with "
|
||||
+ "'custom-int-4-within'.")
|
||||
@JsonProperty("custom-int-4-to")
|
||||
private final Integer customInt4To;
|
||||
/** Exclude values to an upper bound of the field customInt4 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-4-to-not",
|
||||
description = "Exclude values to an upper bound of the field customInt4 of the Task.")
|
||||
@JsonProperty("custom-int-4-to-not")
|
||||
private final Integer customInt4ToNot;
|
||||
/** Filter by the value of the field customInt5 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-int-5",
|
||||
description =
|
||||
"Filter by the value of the field customInt5 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-int-5")
|
||||
private final Integer[] customInt5In;
|
||||
|
||||
/** Exclude values of the field customInt5 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-5-not",
|
||||
description = "Exclude values of the field customInt5 of the Task.")
|
||||
@JsonProperty("custom-int-5-not")
|
||||
private final Integer[] customInt5NotIn;
|
||||
/** Filter by the range of value of the field customInt5 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-5-within",
|
||||
description = "Filter by the range of value of the field customInt5 of the Task.")
|
||||
@JsonProperty("custom-int-5-within")
|
||||
private final Integer[] customInt5Within;
|
||||
/** Exclude range of values of the field customInt5 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-5-not-within",
|
||||
description = "Exclude range of values of the field customInt5 of the Task.")
|
||||
@JsonProperty("custom-int-5-not-within")
|
||||
private final Integer[] customInt5NotWithin;
|
||||
/**
|
||||
|
@ -170,9 +555,17 @@ public class TaskQueryFilterCustomIntFields implements QueryParameter<TaskQuery,
|
|||
*
|
||||
* <p>This parameter can't be used together with 'custom-int-5-within'.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-int-5-from",
|
||||
description =
|
||||
"Filter by lower bound of customInt5. <p>This parameter can't be used together with "
|
||||
+ "'custom-int-5-within'.")
|
||||
@JsonProperty("custom-int-5-from")
|
||||
private final Integer customInt5From;
|
||||
/** Exclude values from a lower bound of the field customInt5 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-5-from-not",
|
||||
description = "Exclude values from a lower bound of the field customInt5 of the Task.")
|
||||
@JsonProperty("custom-int-5-from-not")
|
||||
private final Integer customInt5FromNot;
|
||||
/**
|
||||
|
@ -180,22 +573,43 @@ public class TaskQueryFilterCustomIntFields implements QueryParameter<TaskQuery,
|
|||
*
|
||||
* <p>This parameter can't be used together with 'custom-int-5-within'.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-int-5-to",
|
||||
description =
|
||||
"Filter by upper bound of customInt5. <p>This parameter can't be used together with "
|
||||
+ "'custom-int-5-within'.")
|
||||
@JsonProperty("custom-int-5-to")
|
||||
private final Integer customInt5To;
|
||||
/** Exclude values to an upper bound of the field customInt5 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-5-to-not",
|
||||
description = "Exclude values to an upper bound of the field customInt5 of the Task.")
|
||||
@JsonProperty("custom-int-5-to-not")
|
||||
private final Integer customInt5ToNot;
|
||||
/** Filter by the value of the field customInt6 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-int-6",
|
||||
description =
|
||||
"Filter by the value of the field customInt6 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-int-6")
|
||||
private final Integer[] customInt6In;
|
||||
|
||||
/** Exclude values of the field customInt6 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-6-not",
|
||||
description = "Exclude values of the field customInt6 of the Task.")
|
||||
@JsonProperty("custom-int-6-not")
|
||||
private final Integer[] customInt6NotIn;
|
||||
/** Filter by the range of value of the field customInt6 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-6-within",
|
||||
description = "Filter by the range of value of the field customInt6 of the Task.")
|
||||
@JsonProperty("custom-int-6-within")
|
||||
private final Integer[] customInt6Within;
|
||||
/** Exclude range of values of the field customInt6 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-6-not-within",
|
||||
description = "Exclude range of values of the field customInt6 of the Task.")
|
||||
@JsonProperty("custom-int-6-not-within")
|
||||
private final Integer[] customInt6NotWithin;
|
||||
/**
|
||||
|
@ -203,9 +617,17 @@ public class TaskQueryFilterCustomIntFields implements QueryParameter<TaskQuery,
|
|||
*
|
||||
* <p>This parameter can't be used together with 'custom-int-6-within'.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-int-6-from",
|
||||
description =
|
||||
"Filter by lower bound of customInt6. <p>This parameter can't be used together with "
|
||||
+ "'custom-int-6-within'.")
|
||||
@JsonProperty("custom-int-6-from")
|
||||
private final Integer customInt6From;
|
||||
/** Exclude values from a lower bound of the field customInt6 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-6-from-not",
|
||||
description = "Exclude values from a lower bound of the field customInt6 of the Task.")
|
||||
@JsonProperty("custom-int-6-from-not")
|
||||
private final Integer customInt6FromNot;
|
||||
/**
|
||||
|
@ -213,22 +635,43 @@ public class TaskQueryFilterCustomIntFields implements QueryParameter<TaskQuery,
|
|||
*
|
||||
* <p>This parameter can't be used together with 'custom-int-6-within'.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-int-6-to",
|
||||
description =
|
||||
"Filter by upper bound of customInt6. <p>This parameter can't be used together with "
|
||||
+ "'custom-int-6-within'.")
|
||||
@JsonProperty("custom-int-6-to")
|
||||
private final Integer customInt6To;
|
||||
/** Exclude values to an upper bound of the field customInt6 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-6-to-not",
|
||||
description = "Exclude values to an upper bound of the field customInt6 of the Task.")
|
||||
@JsonProperty("custom-int-6-to-not")
|
||||
private final Integer customInt6ToNot;
|
||||
/** Filter by the value of the field customInt7 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-int-7",
|
||||
description =
|
||||
"Filter by the value of the field customInt7 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-int-7")
|
||||
private final Integer[] customInt7In;
|
||||
|
||||
/** Exclude values of the field customInt7 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-7-not",
|
||||
description = "Exclude values of the field customInt7 of the Task.")
|
||||
@JsonProperty("custom-int-7-not")
|
||||
private final Integer[] customInt7NotIn;
|
||||
/** Filter by the range of value of the field customInt7 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-7-within",
|
||||
description = "Filter by the range of value of the field customInt7 of the Task.")
|
||||
@JsonProperty("custom-int-7-within")
|
||||
private final Integer[] customInt7Within;
|
||||
/** Exclude range of values of the field customInt7 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-7-not-within",
|
||||
description = "Exclude range of values of the field customInt7 of the Task.")
|
||||
@JsonProperty("custom-int-7-not-within")
|
||||
private final Integer[] customInt7NotWithin;
|
||||
/**
|
||||
|
@ -236,9 +679,17 @@ public class TaskQueryFilterCustomIntFields implements QueryParameter<TaskQuery,
|
|||
*
|
||||
* <p>This parameter can't be used together with 'custom-int-7-within'.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-int-7-from",
|
||||
description =
|
||||
"Filter by lower bound of customInt7. <p>This parameter can't be used together with "
|
||||
+ "'custom-int-7-within'.")
|
||||
@JsonProperty("custom-int-7-from")
|
||||
private final Integer customInt7From;
|
||||
/** Exclude values from a lower bound of the field customInt7 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-7-from-not",
|
||||
description = "Exclude values from a lower bound of the field customInt7 of the Task.")
|
||||
@JsonProperty("custom-int-7-from-not")
|
||||
private final Integer customInt7FromNot;
|
||||
/**
|
||||
|
@ -246,22 +697,43 @@ public class TaskQueryFilterCustomIntFields implements QueryParameter<TaskQuery,
|
|||
*
|
||||
* <p>This parameter can't be used together with 'custom-int-7-within'.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-int-7-to",
|
||||
description =
|
||||
"Filter by upper bound of customInt7. <p>This parameter can't be used together with "
|
||||
+ "'custom-int-7-within'.")
|
||||
@JsonProperty("custom-int-7-to")
|
||||
private final Integer customInt7To;
|
||||
/** Exclude values to an upper bound of the field customInt7 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-7-to-not",
|
||||
description = "Exclude values to an upper bound of the field customInt7 of the Task.")
|
||||
@JsonProperty("custom-int-7-to-not")
|
||||
private final Integer customInt7ToNot;
|
||||
/** Filter by the value of the field customInt8 of the Task. This is an exact match. */
|
||||
@Schema(
|
||||
name = "custom-int-8",
|
||||
description =
|
||||
"Filter by the value of the field customInt8 of the Task. This is an exact match.")
|
||||
@JsonProperty("custom-int-8")
|
||||
private final Integer[] customInt8In;
|
||||
|
||||
/** Exclude values of the field customInt8 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-8-not",
|
||||
description = "Exclude values of the field customInt8 of the Task.")
|
||||
@JsonProperty("custom-int-8-not")
|
||||
private final Integer[] customInt8NotIn;
|
||||
/** Filter by the range of value of the field customInt8 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-8-within",
|
||||
description = "Filter by the range of value of the field customInt8 of the Task.")
|
||||
@JsonProperty("custom-int-8-within")
|
||||
private final Integer[] customInt8Within;
|
||||
/** Exclude range of values of the field customInt8 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-8-not-within",
|
||||
description = "Exclude range of values of the field customInt8 of the Task.")
|
||||
@JsonProperty("custom-int-8-not-within")
|
||||
private final Integer[] customInt8NotWithin;
|
||||
/**
|
||||
|
@ -269,9 +741,17 @@ public class TaskQueryFilterCustomIntFields implements QueryParameter<TaskQuery,
|
|||
*
|
||||
* <p>This parameter can't be used together with 'custom-int-8-within'.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-int-8-from",
|
||||
description =
|
||||
"Filter by lower bound of customInt8. <p>This parameter can't be used together with "
|
||||
+ "'custom-int-8-within'.")
|
||||
@JsonProperty("custom-int-8-from")
|
||||
private final Integer customInt8From;
|
||||
/** Exclude values from a lower bound of the field customInt8 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-8-from-not",
|
||||
description = "Exclude values from a lower bound of the field customInt8 of the Task.")
|
||||
@JsonProperty("custom-int-8-from-not")
|
||||
private final Integer customInt8FromNot;
|
||||
/**
|
||||
|
@ -279,9 +759,17 @@ public class TaskQueryFilterCustomIntFields implements QueryParameter<TaskQuery,
|
|||
*
|
||||
* <p>This parameter can't be used together with 'custom-int-8-within'.
|
||||
*/
|
||||
@Schema(
|
||||
name = "custom-int-8-to",
|
||||
description =
|
||||
"Filter by upper bound of customInt8. <p>This parameter can't be used together with "
|
||||
+ "'custom-int-8-within'.")
|
||||
@JsonProperty("custom-int-8-to")
|
||||
private final Integer customInt8To;
|
||||
/** Exclude values to an upper bound of the field customInt8 of the Task. */
|
||||
@Schema(
|
||||
name = "custom-int-8-to-not",
|
||||
description = "Exclude values to an upper bound of the field customInt8 of the Task.")
|
||||
@JsonProperty("custom-int-8-to-not")
|
||||
private final Integer customInt8ToNot;
|
||||
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.task.rest;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.Optional;
|
||||
import java.util.function.Consumer;
|
||||
|
@ -22,11 +23,25 @@ public class TaskQueryGroupByParameter implements QueryParameter<TaskQuery, Void
|
|||
}
|
||||
}
|
||||
|
||||
public String getGroupBySor() {
|
||||
return groupBySor;
|
||||
}
|
||||
|
||||
public TaskQueryGroupBy getGroupByPor() {
|
||||
return groupByPor;
|
||||
}
|
||||
|
||||
// region groupBy
|
||||
@JsonProperty("group-by")
|
||||
@Schema(
|
||||
name = "group-by"
|
||||
)
|
||||
private final TaskQueryGroupBy groupByPor;
|
||||
|
||||
@JsonProperty("group-by-sor")
|
||||
@Schema(
|
||||
name = "group-by-sor"
|
||||
)
|
||||
private final String groupBySor;
|
||||
// endregion
|
||||
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
package pro.taskana.task.rest.models;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.time.Instant;
|
||||
import org.springframework.hateoas.RepresentationModel;
|
||||
import pro.taskana.classification.rest.models.ClassificationSummaryRepresentationModel;
|
||||
|
@ -10,20 +11,30 @@ public class AttachmentSummaryRepresentationModel
|
|||
extends RepresentationModel<AttachmentSummaryRepresentationModel> {
|
||||
|
||||
/** Unique Id. */
|
||||
@Schema(name = "attachmentId", description = "Unique Id.")
|
||||
protected String attachmentId;
|
||||
/** the referenced task id. */
|
||||
@Schema(name = "taskId", description = "The referenced task id.")
|
||||
protected String taskId;
|
||||
/** The creation timestamp in the system. */
|
||||
@Schema(name = "created", description = "The creation timestamp in the system.")
|
||||
protected Instant created;
|
||||
/** The timestamp of the last modification. */
|
||||
@Schema(name = "modified", description = "The timestamp of the last modification.")
|
||||
protected Instant modified;
|
||||
/** The timestamp of the entry date. */
|
||||
@Schema(name = "received", description = "The timestamp of the entry date.")
|
||||
protected Instant received;
|
||||
/** The classification of this attachment. */
|
||||
@Schema(name = "classificationSummary", description = "The classification of this attachment.")
|
||||
protected ClassificationSummaryRepresentationModel classificationSummary;
|
||||
/** The Objects primary ObjectReference. */
|
||||
@Schema(name = "objectReference", description = "The Objects primary ObjectReference.")
|
||||
protected ObjectReferenceRepresentationModel objectReference;
|
||||
/** Determines on which channel this attachment was received. */
|
||||
@Schema(
|
||||
name = "channel",
|
||||
description = "Determines on which channel this attachment was received.")
|
||||
protected String channel;
|
||||
|
||||
public String getAttachmentId() {
|
||||
|
|
|
@ -1,24 +1,38 @@
|
|||
package pro.taskana.task.rest.models;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import org.springframework.hateoas.RepresentationModel;
|
||||
|
||||
public class ObjectReferenceRepresentationModel
|
||||
extends RepresentationModel<ObjectReferenceRepresentationModel> {
|
||||
|
||||
/** Unique ID. */
|
||||
@Schema(description = "Unique ID.")
|
||||
private String id;
|
||||
|
||||
/** Task Id. */
|
||||
@Schema(description = "Task Id.")
|
||||
private String taskId;
|
||||
/** The company the referenced primary object belongs to. */
|
||||
@Schema(description = "The company the referenced primary object belongs to.")
|
||||
private String company;
|
||||
/** The (kind of) system, the referenced primary object resides in (e.g. SAP, MySystem A, ...). */
|
||||
@Schema(
|
||||
description =
|
||||
"The (kind of) system, the referenced primary object resides in (e.g. SAP, MySystem A, "
|
||||
+ "...).")
|
||||
private String system;
|
||||
/** The instance of the system where the referenced primary object is located. */
|
||||
@Schema(
|
||||
description = "The instance of the system where the referenced primary object is located.")
|
||||
private String systemInstance;
|
||||
/** The type of the referenced primary object (contract, claim, policy, customer, ...). */
|
||||
@Schema(
|
||||
description =
|
||||
"The type of the referenced primary object (contract, claim, policy, customer, ...).")
|
||||
private String type;
|
||||
/** The value of the primary object reference. */
|
||||
@Schema(description = "The value of the primary object reference.")
|
||||
private String value;
|
||||
|
||||
public String getId() {
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.task.rest.models;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.Collection;
|
||||
import pro.taskana.common.rest.models.CollectionRepresentationModel;
|
||||
|
@ -15,6 +16,7 @@ public class TaskCommentCollectionRepresentationModel
|
|||
}
|
||||
|
||||
/** The embedded task comments. */
|
||||
@Schema(name = "taskComments", description = "The embedded task comments.")
|
||||
@JsonProperty("taskComments")
|
||||
@Override
|
||||
public Collection<TaskCommentRepresentationModel> getContent() {
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
package pro.taskana.task.rest.models;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.time.Instant;
|
||||
import org.springframework.hateoas.RepresentationModel;
|
||||
import pro.taskana.task.api.models.TaskComment;
|
||||
|
@ -9,18 +10,25 @@ public class TaskCommentRepresentationModel
|
|||
extends RepresentationModel<TaskCommentRepresentationModel> {
|
||||
|
||||
/** Unique Id. */
|
||||
@Schema(name = "taskCommentId", description = "Unique Id.")
|
||||
private String taskCommentId;
|
||||
/** Task Id. Can identify the task the comment belongs to. */
|
||||
@Schema(name = "taskId", description = "Task Id. Can identify the task the comment belongs to.")
|
||||
private String taskId;
|
||||
/** The content of the comment. */
|
||||
@Schema(name = "textField", description = "The content of the comment.")
|
||||
private String textField;
|
||||
/** The creator of the task comment. */
|
||||
@Schema(name = "creator", description = "The creator of the task comment.")
|
||||
private String creator;
|
||||
/** The long name of the task comment creator. */
|
||||
@Schema(name = "creatorFullName", description = "The long name of the task comment creator.")
|
||||
private String creatorFullName;
|
||||
/** The creation timestamp in the system. */
|
||||
@Schema(name = "created", description = "The creation timestamp in the system.")
|
||||
private Instant created;
|
||||
/** Timestamp of the last task comment modification. */
|
||||
@Schema(name = "modified", description = "Timestamp of the last task comment modification.")
|
||||
private Instant modified;
|
||||
|
||||
public String getTaskCommentId() {
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.task.rest.models;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
@ -13,12 +14,15 @@ public class TaskRepresentationModel extends TaskSummaryRepresentationModel {
|
|||
|
||||
// All objects have to be serializable
|
||||
/** Additional information of the task. */
|
||||
@Schema(name = "customAttributes", description = "Additional information of the task.")
|
||||
private List<CustomAttribute> customAttributes = Collections.emptyList();
|
||||
|
||||
/** Callback Information of the task. */
|
||||
@Schema(name = "callbackInfo", description = "Callback Information of the task.")
|
||||
private List<CustomAttribute> callbackInfo = Collections.emptyList();
|
||||
|
||||
/** Attachments of the task. */
|
||||
@Schema(name = "attachments", description = "Attachments of the task.")
|
||||
private List<AttachmentRepresentationModel> attachments = new ArrayList<>();
|
||||
|
||||
public List<CustomAttribute> getCustomAttributes() {
|
||||
|
@ -52,8 +56,10 @@ public class TaskRepresentationModel extends TaskSummaryRepresentationModel {
|
|||
public static class CustomAttribute {
|
||||
|
||||
/** the key of the custom attribute. */
|
||||
@Schema(name = "key", description = "the key of the custom attribute.")
|
||||
private String key;
|
||||
/** the value of the custom attribute. */
|
||||
@Schema(name = "value", description = "the value of the custom attribute.")
|
||||
private String value;
|
||||
|
||||
public static CustomAttribute of(Entry<String, String> entry) {
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.task.rest.models;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.Collection;
|
||||
import pro.taskana.common.rest.models.CollectionRepresentationModel;
|
||||
|
@ -15,6 +16,7 @@ public class TaskSummaryCollectionRepresentationModel
|
|||
}
|
||||
|
||||
/** The embedded tasks. */
|
||||
@Schema(name = "tasks", description = "The embedded tasks.")
|
||||
@JsonProperty("tasks")
|
||||
@Override
|
||||
public Collection<TaskSummaryRepresentationModel> getContent() {
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.task.rest.models;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.Collection;
|
||||
import pro.taskana.common.rest.models.PageMetadata;
|
||||
|
@ -16,6 +17,7 @@ public class TaskSummaryPagedRepresentationModel
|
|||
}
|
||||
|
||||
/** The embedded tasks. */
|
||||
@Schema(name = "tasks", description = "The embedded tasks.")
|
||||
@JsonProperty("tasks")
|
||||
@Override
|
||||
public Collection<TaskSummaryRepresentationModel> getContent() {
|
||||
|
|
|
@ -2,6 +2,7 @@ package pro.taskana.task.rest.models;
|
|||
|
||||
import static pro.taskana.task.api.models.TaskSummary.DEFAULT_MANUAL_PRIORITY;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import java.time.Instant;
|
||||
import java.util.ArrayList;
|
||||
|
@ -15,123 +16,210 @@ public class TaskSummaryRepresentationModel
|
|||
extends RepresentationModel<TaskSummaryRepresentationModel> {
|
||||
|
||||
/** Unique Id. */
|
||||
@Schema(name = "taskId", description = "Unique Id.")
|
||||
protected String taskId;
|
||||
/**
|
||||
* External Id. Can be used to enforce idempotence at task creation. Can identify an external
|
||||
* task.
|
||||
*/
|
||||
@Schema(
|
||||
name = "externalId",
|
||||
description =
|
||||
"External Id. Can be used to enforce idempotence at task creation. Can identify an "
|
||||
+ "external task.")
|
||||
protected String externalId;
|
||||
/** The creation timestamp in the system. */
|
||||
@Schema(name = "created", description = "The creation timestamp in the system.")
|
||||
protected Instant created;
|
||||
/** The timestamp of the last claim-operation. */
|
||||
@Schema(name = "claimed", description = "The timestamp of the last claim-operation.")
|
||||
protected Instant claimed;
|
||||
/** The timestamp of the completion. */
|
||||
@Schema(name = "completed", description = "The timestamp of the completion.")
|
||||
protected Instant completed;
|
||||
/** The timestamp of the last modification. */
|
||||
@Schema(name = "modified", description = "The timestamp of the last modification.")
|
||||
protected Instant modified;
|
||||
/**
|
||||
* Planned start of the task. The actual completion of the task should be between PLANNED and DUE.
|
||||
*/
|
||||
@Schema(
|
||||
name = "planned",
|
||||
description =
|
||||
"Planned start of the task. The actual completion of the task should be between PLANNED"
|
||||
+ " and DUE.")
|
||||
protected Instant planned;
|
||||
/**
|
||||
* Timestamp when the task has been received. It notes when the surrounding process started and
|
||||
* not just when the actual task was created.
|
||||
*/
|
||||
@Schema(
|
||||
name = "received",
|
||||
description =
|
||||
"Timestamp when the task has been received. It notes when the surrounding process started"
|
||||
+ " and not just when the actual task was created.")
|
||||
protected Instant received;
|
||||
/**
|
||||
* Timestamp when the task is due. The actual completion of the task should be between PLANNED and
|
||||
* DUE.
|
||||
*/
|
||||
@Schema(
|
||||
name = "due",
|
||||
description =
|
||||
"Timestamp when the task is due. The actual completion of the task should be between "
|
||||
+ "PLANNED and DUE.")
|
||||
protected Instant due;
|
||||
/** The name of the task. */
|
||||
@Schema(name = "name", description = "The name of the task.")
|
||||
protected String name;
|
||||
/** the creator of the task. */
|
||||
@Schema(name = "creator", description = "the creator of the task.")
|
||||
protected String creator;
|
||||
/** note. */
|
||||
@Schema(name = "note", description = "note.")
|
||||
protected String note;
|
||||
/** The description of the task. */
|
||||
@Schema(name = "description", description = "The description of the task.")
|
||||
protected String description;
|
||||
/** The priority of the task. */
|
||||
@Schema(name = "priority", description = "The priority of the task.")
|
||||
protected int priority;
|
||||
/**
|
||||
* The manual priority of the task. If the value of manualPriority is zero or greater, the
|
||||
* priority is automatically set to manualPriority. In this case, all computations of priority are
|
||||
* disabled. If the value of manualPriority is negative, Tasks are not prioritized manually.
|
||||
*/
|
||||
@Schema(
|
||||
name = "manualPriority",
|
||||
description =
|
||||
"The manual priority of the task. If the value of manualPriority is zero or greater, the "
|
||||
+ "priority is automatically set to manualPriority. In this case, all computations of"
|
||||
+ " priority are disabled. If the value of manualPriority is negative, Tasks are not"
|
||||
+ " prioritized manually.")
|
||||
protected int manualPriority = DEFAULT_MANUAL_PRIORITY;
|
||||
/** The current task state. */
|
||||
@Schema(
|
||||
name = "state",
|
||||
description =
|
||||
"The manual priority of the task. If the value of manualPriority is zero or greater, the "
|
||||
+ "priority is automatically set to manualPriority. In this case, all computations of"
|
||||
+ " priority are disabled. If the value of manualPriority is negative, Tasks are not "
|
||||
+ "prioritized manually.")
|
||||
protected TaskState state;
|
||||
/** The classification of this task. */
|
||||
@NotNull protected ClassificationSummaryRepresentationModel classificationSummary;
|
||||
@Schema(name = "classificationSummary", description = "The classification of this task.")
|
||||
@NotNull
|
||||
protected ClassificationSummaryRepresentationModel classificationSummary;
|
||||
/** The workbasket this task resides in. */
|
||||
@NotNull protected WorkbasketSummaryRepresentationModel workbasketSummary;
|
||||
@Schema(name = "workbasketSummary", description = "The workbasket this task resides in.")
|
||||
@NotNull
|
||||
protected WorkbasketSummaryRepresentationModel workbasketSummary;
|
||||
/** The business process id. */
|
||||
@Schema(name = "businessProcessId", description = "The classification of this task.")
|
||||
protected String businessProcessId;
|
||||
/** the parent business process id. */
|
||||
@Schema(name = "parentBusinessProcessId", description = "the parent business process id.")
|
||||
protected String parentBusinessProcessId;
|
||||
/** The owner of the task. The owner is set upon claiming of the task. */
|
||||
@Schema(
|
||||
name = "owner",
|
||||
description = "The owner of the task. The owner is set upon claiming of the task.")
|
||||
protected String owner;
|
||||
/** The long name of the task owner. */
|
||||
@Schema(name = "ownerLongName", description = "The long name of the task owner.")
|
||||
protected String ownerLongName;
|
||||
/** The Objects primary ObjectReference. */
|
||||
@NotNull protected ObjectReferenceRepresentationModel primaryObjRef;
|
||||
/** Indicator if the task has been read. */
|
||||
@Schema(name = "isRead", description = "The Objects primary ObjectReference.")
|
||||
protected boolean isRead;
|
||||
/** Indicator if the task has been transferred. */
|
||||
@Schema(name = "isTransferred", description = "Indicator if the task has been transferred.")
|
||||
protected boolean isTransferred;
|
||||
/** Number of Tasks that are grouped together with this Task during a groupBy. */
|
||||
@Schema(
|
||||
name = "groupByCount",
|
||||
description = "Number of Tasks that are grouped together with this Task during a groupBy.")
|
||||
protected Integer groupByCount;
|
||||
/** A custom property with name "1". */
|
||||
@Schema(name = "custom1", description = "A custom property with name \"1\".")
|
||||
protected String custom1;
|
||||
/** A custom property with name "2". */
|
||||
@Schema(name = "custom2", description = "A custom property with name \"2\".")
|
||||
protected String custom2;
|
||||
/** A custom property with name "3". */
|
||||
@Schema(name = "custom3", description = "A custom property with name \"3\".")
|
||||
protected String custom3;
|
||||
/** A custom property with name "4". */
|
||||
@Schema(name = "custom4", description = "A custom property with name \"4\".")
|
||||
protected String custom4;
|
||||
/** A custom property with name "5". */
|
||||
@Schema(name = "custom5", description = "A custom property with name \"5\".")
|
||||
protected String custom5;
|
||||
/** A custom property with name "6". */
|
||||
@Schema(name = "custom6", description = "A custom property with name \"6\".")
|
||||
protected String custom6;
|
||||
/** A custom property with name "7". */
|
||||
@Schema(name = "custom7", description = "A custom property with name \"7\".")
|
||||
protected String custom7;
|
||||
/** A custom property with name "8". */
|
||||
@Schema(name = "custom8", description = "A custom property with name \"8\".")
|
||||
protected String custom8;
|
||||
/** A custom property with name "9". */
|
||||
@Schema(name = "custom9", description = "A custom property with name \"9\".")
|
||||
protected String custom9;
|
||||
/** A custom property with name "10". */
|
||||
@Schema(name = "custom10", description = "A custom property with name \"10\".")
|
||||
protected String custom10;
|
||||
/** A custom property with name "11". */
|
||||
@Schema(name = "custom11", description = "A custom property with name \"11\".")
|
||||
protected String custom11;
|
||||
/** A custom property with name "12". */
|
||||
@Schema(name = "custom12", description = "A custom property with name \"12\".")
|
||||
protected String custom12;
|
||||
/** A custom property with name "13". */
|
||||
@Schema(name = "custom13", description = "A custom property with name \"13\".")
|
||||
protected String custom13;
|
||||
/** A custom property with name "14". */
|
||||
@Schema(name = "custom14", description = "A custom property with name \"14\".")
|
||||
protected String custom14;
|
||||
/** A custom property with name "15". */
|
||||
@Schema(name = "custom15", description = "A custom property with name \"15\".")
|
||||
protected String custom15;
|
||||
/** A custom property with name "16". */
|
||||
@Schema(name = "custom16", description = "A custom property with name \"16\".")
|
||||
protected String custom16;
|
||||
/** A custom int property with name "1". */
|
||||
@Schema(name = "customInt1", description = "A custom int property with name \"1\".")
|
||||
protected Integer customInt1;
|
||||
/** A custom int property with name "2". */
|
||||
@Schema(name = "customInt2", description = "A custom int property with name \"2\".")
|
||||
protected Integer customInt2;
|
||||
/** A custom int property with name "3". */
|
||||
@Schema(name = "customInt3", description = "A custom int property with name \"3\".")
|
||||
protected Integer customInt3;
|
||||
/** A custom int property with name "4". */
|
||||
@Schema(name = "customInt4", description = "A custom int property with name \"4\".")
|
||||
protected Integer customInt4;
|
||||
/** A custom int property with name "5". */
|
||||
@Schema(name = "customInt5", description = "A custom int property with name \"5\".")
|
||||
protected Integer customInt5;
|
||||
/** A custom int property with name "6". */
|
||||
@Schema(name = "customInt6", description = "A custom int property with name \"6\".")
|
||||
protected Integer customInt6;
|
||||
/** A custom int property with name "7". */
|
||||
@Schema(name = "customInt7", description = "A custom int property with name \"7\".")
|
||||
protected Integer customInt7;
|
||||
/** A custom int property with name "8". */
|
||||
@Schema(name = "customInt8", description = "A custom int property with name \"8\".")
|
||||
protected Integer customInt8;
|
||||
/** Secondary object references of the task. */
|
||||
@Schema(
|
||||
name = "secondaryObjectReferences",
|
||||
description = "Secondary object references of the task.")
|
||||
protected List<ObjectReferenceRepresentationModel> secondaryObjectReferences = new ArrayList<>();
|
||||
/** The attachment summaries of this task. */
|
||||
@Schema(name = "attachmentSummaries", description = "The attachment summaries of this task.")
|
||||
private List<AttachmentSummaryRepresentationModel> attachmentSummaries = new ArrayList<>();
|
||||
|
||||
public String getTaskId() {
|
||||
|
|
|
@ -1,10 +1,17 @@
|
|||
package pro.taskana.user.rest;
|
||||
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.media.Content;
|
||||
import io.swagger.v3.oas.annotations.media.ExampleObject;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||
import jakarta.servlet.http.HttpServletRequest;
|
||||
import java.util.HashSet;
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.hateoas.MediaTypes;
|
||||
import org.springframework.hateoas.config.EnableHypermediaSupport;
|
||||
import org.springframework.hateoas.config.EnableHypermediaSupport.HypermediaType;
|
||||
import org.springframework.http.HttpStatus;
|
||||
|
@ -59,9 +66,27 @@ public class UserController {
|
|||
* @throws UserNotFoundException if the id has not been found
|
||||
* @throws InvalidArgumentException if the id is null or empty
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Get a User",
|
||||
description = "This endpoint retrieves a User.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "userId",
|
||||
description = "The ID of the requested user",
|
||||
example = "teamlead-1")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "The requested User",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = UserRepresentationModel.class)))
|
||||
})
|
||||
@GetMapping(RestEndpoints.URL_USERS_ID)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<UserRepresentationModel> getUser(@PathVariable String userId)
|
||||
public ResponseEntity<UserRepresentationModel> getUser(@PathVariable("userId") String userId)
|
||||
throws UserNotFoundException, InvalidArgumentException {
|
||||
User user = userService.getUser(userId);
|
||||
return ResponseEntity.ok(userAssembler.toModel(user));
|
||||
|
@ -80,6 +105,32 @@ public class UserController {
|
|||
* @throws InvalidArgumentException if the userIds are null or empty
|
||||
* @throws UserNotFoundException if the current User was not found
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Get multiple Users",
|
||||
description =
|
||||
"This endpoint retrieves multiple Users. If a userId can't be found in the database it "
|
||||
+ "will be ignored. If none of the given userIds is valid, the returned list will be"
|
||||
+ " empty. If currentUser is set, the current User from the context will be retrieved"
|
||||
+ " as well.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "user-id",
|
||||
description = "The IDs of the users to be retrieved",
|
||||
example = "teamlead-1"),
|
||||
@Parameter(
|
||||
name = "current-user",
|
||||
description = "Whether to fetch the current user as well",
|
||||
example = "user-1-1")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "The requested Users",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = UserCollectionRepresentationModel.class)))
|
||||
})
|
||||
@GetMapping(RestEndpoints.URL_USERS)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<UserCollectionRepresentationModel> getUsers(
|
||||
|
@ -111,6 +162,36 @@ public class UserController {
|
|||
* @throws UserAlreadyExistException if a User with id } is already existing
|
||||
* @throws NotAuthorizedException if the current user is no admin or business-admin
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Create a User",
|
||||
description = "This endpoint creates a new User.",
|
||||
requestBody =
|
||||
@io.swagger.v3.oas.annotations.parameters.RequestBody(
|
||||
description = "the User which should be created",
|
||||
required = true,
|
||||
content =
|
||||
@Content(
|
||||
schema = @Schema(implementation = UserRepresentationModel.class),
|
||||
examples =
|
||||
@ExampleObject(
|
||||
value =
|
||||
"{\n"
|
||||
+ " \"userId\": \"user-10-2\",\n"
|
||||
+ " \"groups\": [],\n"
|
||||
+ " \"permissions\": [],\n"
|
||||
+ " \"domains\": [],\n"
|
||||
+ " \"firstName\": \"Hans\",\n"
|
||||
+ " \"lastName\": \"Georg\"\n"
|
||||
+ "}"))),
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "201",
|
||||
description = "The inserted User",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = UserRepresentationModel.class)))
|
||||
})
|
||||
@PostMapping(RestEndpoints.URL_USERS)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<UserRepresentationModel> createUser(
|
||||
|
@ -133,10 +214,57 @@ public class UserController {
|
|||
* @throws UserNotFoundException if a User with id is not existing in the database
|
||||
* @throws NotAuthorizedException if the current user is no admin or business-admin
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Update a User",
|
||||
description = "This endpoint updates a User.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "userId",
|
||||
description = "The ID of the User to update",
|
||||
example = "teamlead-1")
|
||||
},
|
||||
requestBody =
|
||||
@io.swagger.v3.oas.annotations.parameters.RequestBody(
|
||||
description = "the User with the updated fields",
|
||||
required = true,
|
||||
content =
|
||||
@Content(
|
||||
schema = @Schema(implementation = UserRepresentationModel.class),
|
||||
examples = {
|
||||
@ExampleObject(
|
||||
value =
|
||||
"{\n"
|
||||
+ " \"userId\": \"teamlead-1\",\n"
|
||||
+ " \"groups\": [],\n"
|
||||
+ " \"permissions\": [],\n"
|
||||
+ " \"domains\": [\"DOMAIN_A\"],\n"
|
||||
+ " \"firstName\": \"new name\",\n"
|
||||
+ " \"lastName\": \"Toll\",\n"
|
||||
+ " \"fullName\": \"Toll, Titus\",\n"
|
||||
+ " \"longName\": \"Toll, Titus - (teamlead-1)\",\n"
|
||||
+ " \"email\": \"titus.toll@web.de\",\n"
|
||||
+ " \"phone\": \"040-2951854\",\n"
|
||||
+ " \"mobilePhone\": \"015637683197\",\n"
|
||||
+ " \"orgLevel4\": \"Novatec\",\n"
|
||||
+ " \"orgLevel3\": \"BPM\",\n"
|
||||
+ " \"orgLevel2\": \"Human Workflow\",\n"
|
||||
+ " \"orgLevel1\": \"TASKANA\",\n"
|
||||
+ " \"data\": \"xy\"\n"
|
||||
+ "}")
|
||||
})),
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "The updated User",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = UserRepresentationModel.class)))
|
||||
})
|
||||
@PutMapping(RestEndpoints.URL_USERS_ID)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<UserRepresentationModel> updateUser(
|
||||
@PathVariable(value = "userId") String userId, @RequestBody UserRepresentationModel repModel)
|
||||
@PathVariable("userId") String userId, @RequestBody UserRepresentationModel repModel)
|
||||
throws InvalidArgumentException, UserNotFoundException, NotAuthorizedException {
|
||||
if (!userId.equals(repModel.getUserId())) {
|
||||
throw new InvalidArgumentException(
|
||||
|
@ -161,9 +289,24 @@ public class UserController {
|
|||
* @throws NotAuthorizedException if the current user is no admin or business-admin
|
||||
* @throws InvalidArgumentException if the id is null or empty
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Delete a User",
|
||||
description = "This endpoint deletes a User.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "userId",
|
||||
description = "The ID of the user to delete",
|
||||
example = "user-1-1")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "204",
|
||||
description = "User deleted",
|
||||
content = @Content(schema = @Schema()))
|
||||
})
|
||||
@DeleteMapping(RestEndpoints.URL_USERS_ID)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<UserRepresentationModel> deleteUser(@PathVariable String userId)
|
||||
public ResponseEntity<UserRepresentationModel> deleteUser(@PathVariable("userId") String userId)
|
||||
throws UserNotFoundException, NotAuthorizedException, InvalidArgumentException {
|
||||
userService.deleteUser(userId);
|
||||
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.user.rest.models;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.Collection;
|
||||
import pro.taskana.common.rest.models.CollectionRepresentationModel;
|
||||
|
@ -13,6 +14,7 @@ public class UserCollectionRepresentationModel
|
|||
}
|
||||
|
||||
/** The embedded users. */
|
||||
@Schema(name = "users", description = "The embedded users.")
|
||||
@JsonProperty("users")
|
||||
@Override
|
||||
public Collection<UserRepresentationModel> getContent() {
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
package pro.taskana.user.rest.models;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import java.util.Collections;
|
||||
import java.util.Objects;
|
||||
|
@ -11,10 +12,13 @@ import pro.taskana.user.api.models.User;
|
|||
public class UserRepresentationModel extends RepresentationModel<UserRepresentationModel> {
|
||||
|
||||
/** Unique Id. */
|
||||
@Schema(name = "userId", description = "Unique Id.")
|
||||
@NotNull private String userId;
|
||||
/** The groups of the User. */
|
||||
@Schema(name = "groups", description = "The groups of the User.")
|
||||
private Set<String> groups;
|
||||
/** The permissions of the User. */
|
||||
@Schema(name = "permissions", description = "The permissions of the User.")
|
||||
private Set<String> permissions;
|
||||
/**
|
||||
* The domains of the User.
|
||||
|
@ -24,28 +28,43 @@ public class UserRepresentationModel extends RepresentationModel<UserRepresentat
|
|||
*/
|
||||
private Set<String> domains = Collections.emptySet();
|
||||
/** The first name of the User. */
|
||||
@Schema(name = "firstName", description = "The first name of the User.")
|
||||
private String firstName;
|
||||
/** The last name of the User. */
|
||||
@Schema(name = "lastName", description = "The last name of the User.")
|
||||
private String lastName;
|
||||
/** The full name of the User. */
|
||||
@Schema(name = "fullName", description = "The full name of the User.")
|
||||
private String fullName;
|
||||
/** The long name of the User. */
|
||||
@Schema(name = "longName", description = "The long name of the User.")
|
||||
private String longName;
|
||||
/** The email of the User. */
|
||||
@Schema(name = "email", description = "The email of the User.")
|
||||
private String email;
|
||||
/** The phone number of the User. */
|
||||
@Schema(name = "phone", description = "The phone number of the User.")
|
||||
private String phone;
|
||||
/** The mobile phone number of the User. */
|
||||
@Schema(name = "mobilePhone", description = "The mobile phone number of the User.")
|
||||
private String mobilePhone;
|
||||
/** The fourth organisation level of the User. */
|
||||
@Schema(name = "orgLevel4", description = "The fourth organisation level of the User.")
|
||||
private String orgLevel4;
|
||||
/** The third organisation level of the User. */
|
||||
@Schema(name = "orgLevel3", description = "The third organisation level of the User.")
|
||||
private String orgLevel3;
|
||||
/** The second organisation level of the User. */
|
||||
@Schema(name = "orgLevel2", description = "The second organisation level of the User.")
|
||||
private String orgLevel2;
|
||||
/** The first organisation level of the User. */
|
||||
@Schema(name = "orgLevel1", description = "The first organisation level of the User.")
|
||||
private String orgLevel1;
|
||||
/** The data of the User. This field is used for additional information about the User. */
|
||||
@Schema(
|
||||
name = "data",
|
||||
description =
|
||||
"The data of the User. This field is used for additional information about the User.")
|
||||
private String data;
|
||||
|
||||
public String getUserId() {
|
||||
|
|
|
@ -1,10 +1,17 @@
|
|||
package pro.taskana.workbasket.rest;
|
||||
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.media.Content;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||
import jakarta.servlet.http.HttpServletRequest;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.List;
|
||||
import java.util.function.BiConsumer;
|
||||
import org.springdoc.core.annotations.ParameterObject;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.hateoas.MediaTypes;
|
||||
import org.springframework.hateoas.config.EnableHypermediaSupport;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||
|
@ -56,12 +63,35 @@ public class WorkbasketAccessItemController {
|
|||
* @return the Workbasket Access Items with the given filter, sort and paging options.
|
||||
* @throws NotAuthorizedException if the user is not authorized.
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Get a list of all Workbasket Access Items",
|
||||
description =
|
||||
"This endpoint retrieves a list of existing Workbasket Access Items. Filters can be "
|
||||
+ "applied.",
|
||||
parameters = {
|
||||
@Parameter(name = "sort-by", example = "WORKBASKET_KEY"),
|
||||
@Parameter(name = "order", example = "ASCENDING"),
|
||||
@Parameter(name = "access-id", example = "user-2-2")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description =
|
||||
"the Workbasket Access Items with the given filter, sort and paging options.",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema =
|
||||
@Schema(implementation = WorkbasketAccessItemPagedRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_WORKBASKET_ACCESS_ITEMS)
|
||||
public ResponseEntity<WorkbasketAccessItemPagedRepresentationModel> getWorkbasketAccessItems(
|
||||
HttpServletRequest request,
|
||||
WorkbasketAccessItemQueryFilterParameter filterParameter,
|
||||
WorkbasketAccessItemQuerySortParameter sortParameter,
|
||||
QueryPagingParameter<WorkbasketAccessItem, WorkbasketAccessItemQuery> pagingParameter)
|
||||
@ParameterObject WorkbasketAccessItemQueryFilterParameter filterParameter,
|
||||
@ParameterObject WorkbasketAccessItemQuerySortParameter sortParameter,
|
||||
@ParameterObject
|
||||
QueryPagingParameter<WorkbasketAccessItem, WorkbasketAccessItemQuery> pagingParameter)
|
||||
throws NotAuthorizedException {
|
||||
|
||||
QueryParamsValidator.validateParams(
|
||||
|
@ -91,6 +121,21 @@ public class WorkbasketAccessItemController {
|
|||
* @throws NotAuthorizedException if the user is not authorized.
|
||||
* @throws InvalidArgumentException if some argument is invalid.
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Delete a Workbasket Access Item",
|
||||
description = "This endpoint deletes all Workbasket Access Items for a provided Access Id.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "accessId",
|
||||
description = "the Access Id whose Workbasket Access Items should be removed",
|
||||
example = "user-2-1",
|
||||
required = true)
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "204",
|
||||
content = {@Content(schema = @Schema())})
|
||||
})
|
||||
@DeleteMapping(path = RestEndpoints.URL_WORKBASKET_ACCESS_ITEMS)
|
||||
public ResponseEntity<Void> removeWorkbasketAccessItems(
|
||||
@RequestParam("access-id") String accessId)
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.workbasket.rest;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.Optional;
|
||||
import pro.taskana.common.rest.QueryParameter;
|
||||
|
@ -8,8 +9,26 @@ import pro.taskana.workbasket.api.WorkbasketAccessItemQuery;
|
|||
|
||||
public class WorkbasketAccessItemQueryFilterParameter
|
||||
implements QueryParameter<WorkbasketAccessItemQuery, Void> {
|
||||
public String[] getWorkbasketKey() {
|
||||
return workbasketKey;
|
||||
}
|
||||
|
||||
public String[] getWorkbasketKeyLike() {
|
||||
return workbasketKeyLike;
|
||||
}
|
||||
|
||||
public String[] getAccessId() {
|
||||
return accessId;
|
||||
}
|
||||
|
||||
public String[] getAccessIdLike() {
|
||||
return accessIdLike;
|
||||
}
|
||||
|
||||
/** Filter by the key of the Workbasket. This is an exact match. */
|
||||
@Schema(
|
||||
name = "workbasket-key",
|
||||
description = "Filter by the key of the Workbasket. This is an exact match.")
|
||||
@JsonProperty("workbasket-key")
|
||||
private final String[] workbasketKey;
|
||||
|
||||
|
@ -18,10 +37,19 @@ public class WorkbasketAccessItemQueryFilterParameter
|
|||
* beginning and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "workbasket-key-like",
|
||||
description =
|
||||
"Filter by the key of the Workbasket. This results in a substring search.. (% is appended"
|
||||
+ " to the beginning and end of the requested value). Further SQL \"LIKE\" wildcard "
|
||||
+ "characters will be resolved correctly.")
|
||||
@JsonProperty("workbasket-key-like")
|
||||
private final String[] workbasketKeyLike;
|
||||
|
||||
/** Filter by the name of the access id. This is an exact match. */
|
||||
@Schema(
|
||||
name = "access-id",
|
||||
description = "Filter by the name of the access id. This is an exact match.")
|
||||
@JsonProperty("access-id")
|
||||
private final String[] accessId;
|
||||
|
||||
|
@ -30,6 +58,12 @@ public class WorkbasketAccessItemQueryFilterParameter
|
|||
* beginning and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "access-id-like",
|
||||
description =
|
||||
"Filter by the name of the access id. This results in a substring search.. (% is appended"
|
||||
+ " to the beginning and end of the requested value). Further SQL \"LIKE\" wildcard "
|
||||
+ "characters will be resolved correctly.")
|
||||
@JsonProperty("access-id-like")
|
||||
private final String[] accessIdLike;
|
||||
|
||||
|
|
|
@ -1,11 +1,19 @@
|
|||
package pro.taskana.workbasket.rest;
|
||||
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.media.ArraySchema;
|
||||
import io.swagger.v3.oas.annotations.media.Content;
|
||||
import io.swagger.v3.oas.annotations.media.ExampleObject;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||
import jakarta.servlet.http.HttpServletRequest;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.List;
|
||||
import java.util.function.BiConsumer;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springdoc.core.annotations.ParameterObject;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.hateoas.MediaTypes;
|
||||
import org.springframework.hateoas.config.EnableHypermediaSupport;
|
||||
|
@ -89,13 +97,29 @@ public class WorkbasketController {
|
|||
* @param pagingParameter the paging parameters
|
||||
* @return the Workbaskets with the given filter, sort and paging options.
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Get a list of all Workbaskets",
|
||||
description =
|
||||
"This endpoint retrieves a list of existing Workbaskets. Filters can be applied.",
|
||||
parameters = {@Parameter(name = "type", example = "PERSONAL")},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "Found all Workbaskets",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema =
|
||||
@Schema(implementation = WorkbasketSummaryPagedRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_WORKBASKET)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<WorkbasketSummaryPagedRepresentationModel> getWorkbaskets(
|
||||
HttpServletRequest request,
|
||||
WorkbasketQueryFilterParameter filterParameter,
|
||||
WorkbasketQuerySortParameter sortParameter,
|
||||
QueryPagingParameter<WorkbasketSummary, WorkbasketQuery> pagingParameter) {
|
||||
@ParameterObject WorkbasketQueryFilterParameter filterParameter,
|
||||
@ParameterObject WorkbasketQuerySortParameter sortParameter,
|
||||
@ParameterObject QueryPagingParameter<WorkbasketSummary, WorkbasketQuery> pagingParameter) {
|
||||
|
||||
QueryParamsValidator.validateParams(
|
||||
request,
|
||||
|
@ -125,10 +149,30 @@ public class WorkbasketController {
|
|||
* @throws NotAuthorizedOnWorkbasketException if the current user has no permissions to access the
|
||||
* requested Workbasket
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Get a single Workbasket",
|
||||
description = "This endpoint retrieves a single Workbasket.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "workbasketId",
|
||||
description = "the Id of the requested Workbasket",
|
||||
required = true,
|
||||
example = "WBI:100000000000000000000000000000000001")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the requested Workbasket",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = WorkbasketRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_WORKBASKET_ID, produces = MediaTypes.HAL_JSON_VALUE)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<WorkbasketRepresentationModel> getWorkbasket(
|
||||
@PathVariable(value = "workbasketId") String workbasketId)
|
||||
@PathVariable("workbasketId") String workbasketId)
|
||||
throws WorkbasketNotFoundException, NotAuthorizedOnWorkbasketException {
|
||||
Workbasket workbasket = workbasketService.getWorkbasket(workbasketId);
|
||||
|
||||
|
@ -157,10 +201,39 @@ public class WorkbasketController {
|
|||
* @throws WorkbasketInUseException if the Workbasket contains tasks.
|
||||
* @throws NotAuthorizedException if the current user has not correct permissions
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Delete a Workbasket",
|
||||
description = "This endpoint deletes an existing Workbasket",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "workbasketId",
|
||||
description = "the Id of the requested Workbasket",
|
||||
required = true,
|
||||
example = "WBI:100000000000000000000000000000000002")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "204",
|
||||
description = "<b>204 NO_CONTENT</b> - Workbasket has been deleted successfully",
|
||||
content = @Content(schema = @Schema())),
|
||||
@ApiResponse(
|
||||
responseCode = "202",
|
||||
description =
|
||||
"<b>202 ACCEPTED</b> - Workbasket still contains completed Tasks. It has been "
|
||||
+ "marked for deletion and will be deleted automatically as soon as all "
|
||||
+ "completed Tasks are deleted.",
|
||||
content = @Content(schema = @Schema())),
|
||||
@ApiResponse(
|
||||
responseCode = "423",
|
||||
description =
|
||||
"<b>423 LOCKED</b> - Workbasket contains non-completed Tasks and cannot be "
|
||||
+ "deleted.",
|
||||
content = @Content(schema = @Schema()))
|
||||
})
|
||||
@DeleteMapping(path = RestEndpoints.URL_WORKBASKET_ID)
|
||||
@Transactional(rollbackFor = Exception.class, noRollbackFor = WorkbasketNotFoundException.class)
|
||||
public ResponseEntity<WorkbasketRepresentationModel> deleteWorkbasket(
|
||||
@PathVariable(value = "workbasketId") String workbasketId)
|
||||
@PathVariable("workbasketId") String workbasketId)
|
||||
throws InvalidArgumentException,
|
||||
WorkbasketNotFoundException,
|
||||
WorkbasketInUseException,
|
||||
|
@ -195,6 +268,35 @@ public class WorkbasketController {
|
|||
* @throws WorkbasketAlreadyExistException if the Workbasket exists already
|
||||
* @throws DomainNotFoundException if the domain does not exist in the configuration.
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Create a new Workbasket",
|
||||
description = "This endpoint creates a persistent Workbasket.",
|
||||
requestBody =
|
||||
@io.swagger.v3.oas.annotations.parameters.RequestBody(
|
||||
description = "the Workbasket which should be created.",
|
||||
content =
|
||||
@Content(
|
||||
schema = @Schema(implementation = WorkbasketRepresentationModel.class),
|
||||
examples =
|
||||
@ExampleObject(
|
||||
value =
|
||||
"{\n"
|
||||
+ " \"key\" : \"asdasdasd\",\n"
|
||||
+ " \"name\" : \"this is a wonderful workbasket name\",\n"
|
||||
+ " \"domain\" : \"DOMAIN_A\",\n"
|
||||
+ " \"type\" : \"GROUP\",\n"
|
||||
+ " \"markedForDeletion\" : false\n"
|
||||
+ "}"))),
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "201",
|
||||
description = "the created Workbasket",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = WorkbasketRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@PostMapping(path = RestEndpoints.URL_WORKBASKET)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<WorkbasketRepresentationModel> createWorkbasket(
|
||||
|
@ -226,10 +328,64 @@ public class WorkbasketController {
|
|||
* updated it already
|
||||
* @throws NotAuthorizedOnWorkbasketException if the current user has not correct permissions
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Update a Workbasket",
|
||||
description = "This endpoint creates a persistent Workbasket.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "workbasketId",
|
||||
description = "the Id of the requested Workbasket",
|
||||
required = true,
|
||||
example = "WBI:100000000000000000000000000000000001")
|
||||
},
|
||||
requestBody =
|
||||
@io.swagger.v3.oas.annotations.parameters.RequestBody(
|
||||
description = "the new Workbasket for the requested id",
|
||||
content =
|
||||
@Content(
|
||||
schema = @Schema(implementation = WorkbasketRepresentationModel.class),
|
||||
examples =
|
||||
@ExampleObject(
|
||||
value =
|
||||
"{\n"
|
||||
+ " \"workbasketId\" : "
|
||||
+ "\"WBI:100000000000000000000000000000000001\",\n"
|
||||
+ " \"key\" : \"GPK_KSC\",\n"
|
||||
+ " \"name\" : \"new name\",\n"
|
||||
+ " \"domain\" : \"DOMAIN_A\",\n"
|
||||
+ " \"type\" : \"GROUP\",\n"
|
||||
+ " \"description\" : \"Gruppenpostkorb KSC\",\n"
|
||||
+ " \"owner\" : \"teamlead-1\",\n"
|
||||
+ " \"custom1\" : \"ABCQVW\",\n"
|
||||
+ " \"custom2\" : \"\",\n"
|
||||
+ " \"custom3\" : \"xyz4\",\n"
|
||||
+ " \"custom4\" : \"\",\n"
|
||||
+ " \"custom5\" : \"\",\n"
|
||||
+ " \"custom6\" : \"\",\n"
|
||||
+ " \"custom7\" : \"\",\n"
|
||||
+ " \"custom8\" : \"\",\n"
|
||||
+ " \"orgLevel1\" : \"\",\n"
|
||||
+ " \"orgLevel2\" : \"\",\n"
|
||||
+ " \"orgLevel3\" : \"\",\n"
|
||||
+ " \"orgLevel4\" : \"\",\n"
|
||||
+ " \"markedForDeletion\" : false,\n"
|
||||
+ " \"created\" : \"2018-02-01T12:00:00.000Z\",\n"
|
||||
+ " \"modified\" : \"2018-02-01T12:00:00.000Z\"\n"
|
||||
+ "}"))),
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the requested Workbasket",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema = @Schema(implementation = WorkbasketRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@PutMapping(path = RestEndpoints.URL_WORKBASKET_ID)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<WorkbasketRepresentationModel> updateWorkbasket(
|
||||
@PathVariable(value = "workbasketId") String workbasketId,
|
||||
@PathVariable("workbasketId") String workbasketId,
|
||||
@RequestBody WorkbasketRepresentationModel workbasketRepresentationModel)
|
||||
throws WorkbasketNotFoundException,
|
||||
NotAuthorizedException,
|
||||
|
@ -262,12 +418,34 @@ public class WorkbasketController {
|
|||
* @throws WorkbasketNotFoundException if the requested Workbasket does not exist.
|
||||
* @throws NotAuthorizedOnWorkbasketException if the current user has not correct permissions
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Get all Workbasket Access Items",
|
||||
description = "This endpoint retrieves all Workbasket Access Items for a given Workbasket.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "workbasketId",
|
||||
description = "the Id of the requested Workbasket",
|
||||
required = true,
|
||||
example = "WBI:100000000000000000000000000000000001")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the access items for the requested Workbasket.",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema =
|
||||
@Schema(
|
||||
implementation = WorkbasketAccessItemCollectionRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@GetMapping(
|
||||
path = RestEndpoints.URL_WORKBASKET_ID_ACCESS_ITEMS,
|
||||
produces = MediaTypes.HAL_JSON_VALUE)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<WorkbasketAccessItemCollectionRepresentationModel> getWorkbasketAccessItems(
|
||||
@PathVariable(value = "workbasketId") String workbasketId)
|
||||
@PathVariable("workbasketId") String workbasketId)
|
||||
throws WorkbasketNotFoundException,
|
||||
NotAuthorizedException,
|
||||
NotAuthorizedOnWorkbasketException {
|
||||
|
@ -295,10 +473,73 @@ public class WorkbasketController {
|
|||
* in the provided list.
|
||||
* @throws NotAuthorizedOnWorkbasketException if the current user has not correct permissions
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Set all Workbasket Access Items",
|
||||
description =
|
||||
"This endpoint replaces all Workbasket Access Items for a given Workbasket with the "
|
||||
+ "provided",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "workbasketId",
|
||||
description = "the Id of the Workbasket whose Workbasket Access Items will be replaced",
|
||||
required = true,
|
||||
example = "WBI:100000000000000000000000000000000001")
|
||||
},
|
||||
requestBody =
|
||||
@io.swagger.v3.oas.annotations.parameters.RequestBody(
|
||||
description = "the new Workbasket Access Items.",
|
||||
content =
|
||||
@Content(
|
||||
schema =
|
||||
@Schema(
|
||||
implementation =
|
||||
WorkbasketAccessItemCollectionRepresentationModel.class),
|
||||
examples =
|
||||
@ExampleObject(
|
||||
value =
|
||||
"{\n"
|
||||
+ " \"accessItems\" : [ {\n"
|
||||
+ " \"workbasketId\" : "
|
||||
+ "\"WBI:100000000000000000000000000000000001\",\n"
|
||||
+ " \"accessId\" : \"new-access-id\",\n"
|
||||
+ " \"accessName\" : \"new-access-name\",\n"
|
||||
+ " \"permRead\" : false,\n"
|
||||
+ " \"permReadTasks\" : false,\n"
|
||||
+ " \"permOpen\" : true,\n"
|
||||
+ " \"permAppend\" : false,\n"
|
||||
+ " \"permEditTasks\" : false,\n"
|
||||
+ " \"permTransfer\" : false,\n"
|
||||
+ " \"permDistribute\" : false,\n"
|
||||
+ " \"permCustom1\" : false,\n"
|
||||
+ " \"permCustom2\" : false,\n"
|
||||
+ " \"permCustom3\" : false,\n"
|
||||
+ " \"permCustom4\" : false,\n"
|
||||
+ " \"permCustom5\" : false,\n"
|
||||
+ " \"permCustom6\" : false,\n"
|
||||
+ " \"permCustom7\" : false,\n"
|
||||
+ " \"permCustom8\" : false,\n"
|
||||
+ " \"permCustom9\" : false,\n"
|
||||
+ " \"permCustom10\" : false,\n"
|
||||
+ " \"permCustom11\" : false,\n"
|
||||
+ " \"permCustom12\" : false\n"
|
||||
+ " } ]\n"
|
||||
+ "}"))),
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the new Workbasket Access Items for the requested Workbasket",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema =
|
||||
@Schema(
|
||||
implementation = WorkbasketAccessItemCollectionRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@PutMapping(path = RestEndpoints.URL_WORKBASKET_ID_ACCESS_ITEMS)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<WorkbasketAccessItemCollectionRepresentationModel> setWorkbasketAccessItems(
|
||||
@PathVariable(value = "workbasketId") String workbasketId,
|
||||
@PathVariable("workbasketId") String workbasketId,
|
||||
@RequestBody WorkbasketAccessItemCollectionRepresentationModel workbasketAccessItemRepModels)
|
||||
throws InvalidArgumentException,
|
||||
WorkbasketNotFoundException,
|
||||
|
@ -332,12 +573,34 @@ public class WorkbasketController {
|
|||
* @throws NotAuthorizedOnWorkbasketException if the current user has no read permission for the
|
||||
* specified Workbasket
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Get all Distribution Targets for a Workbasket",
|
||||
description = "This endpoint retrieves all Distribution Targets for a requested Workbasket.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "workbasketId",
|
||||
description = "the Id of the Workbasket whose Distribution Targets will be retrieved",
|
||||
required = true,
|
||||
example = "WBI:100000000000000000000000000000000002")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the Distribution Targets for the requested Workbasket",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema =
|
||||
@Schema(
|
||||
implementation = DistributionTargetsCollectionRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@GetMapping(
|
||||
path = RestEndpoints.URL_WORKBASKET_ID_DISTRIBUTION,
|
||||
produces = MediaTypes.HAL_JSON_VALUE)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<DistributionTargetsCollectionRepresentationModel> getDistributionTargets(
|
||||
@PathVariable(value = "workbasketId") String workbasketId)
|
||||
@PathVariable("workbasketId") String workbasketId)
|
||||
throws WorkbasketNotFoundException, NotAuthorizedOnWorkbasketException {
|
||||
List<WorkbasketSummary> distributionTargets =
|
||||
workbasketService.getDistributionTargets(workbasketId);
|
||||
|
@ -359,11 +622,46 @@ public class WorkbasketController {
|
|||
* the source Workbasket
|
||||
* @throws NotAuthorizedException if the current user has not correct permissions
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Set all Distribution Targets for a Workbasket",
|
||||
description =
|
||||
"This endpoint replaces all Distribution Targets for a given Workbasket with the "
|
||||
+ "provided ones.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "workbasketId",
|
||||
description = "the source Workbasket",
|
||||
required = true,
|
||||
example = "WBI:100000000000000000000000000000000001")
|
||||
},
|
||||
requestBody =
|
||||
@io.swagger.v3.oas.annotations.parameters.RequestBody(
|
||||
description = "the destination Workbaskets.",
|
||||
content =
|
||||
@Content(
|
||||
array = @ArraySchema(schema = @Schema(implementation = String.class)),
|
||||
examples =
|
||||
@ExampleObject(
|
||||
value =
|
||||
"[ \"WBI:100000000000000000000000000000000002\", "
|
||||
+ "\"WBI:100000000000000000000000000000000003\" ]"))),
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "the new Distribution Targets for the requested Workbasket.",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema =
|
||||
@Schema(
|
||||
implementation = DistributionTargetsCollectionRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@PutMapping(path = RestEndpoints.URL_WORKBASKET_ID_DISTRIBUTION)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<DistributionTargetsCollectionRepresentationModel>
|
||||
setDistributionTargetsForWorkbasketId(
|
||||
@PathVariable(value = "workbasketId") String sourceWorkbasketId,
|
||||
@PathVariable("workbasketId") String sourceWorkbasketId,
|
||||
@RequestBody List<String> targetWorkbasketIds)
|
||||
throws WorkbasketNotFoundException,
|
||||
NotAuthorizedException,
|
||||
|
@ -388,10 +686,21 @@ public class WorkbasketController {
|
|||
* @throws NotAuthorizedException if the requested user ist not ADMIN or BUSINESS_ADMIN.
|
||||
* @throws NotAuthorizedOnWorkbasketException if the current user has not correct permissions
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Remove a Workbasket as Distribution Target",
|
||||
description =
|
||||
"This endpoint removes all Distribution Target references for a provided Workbasket.",
|
||||
parameters = {
|
||||
@Parameter(
|
||||
name = "workbasketId",
|
||||
description = "the Id of the requested Workbasket.",
|
||||
required = true,
|
||||
example = "WBI:100000000000000000000000000000000007")
|
||||
})
|
||||
@DeleteMapping(path = RestEndpoints.URL_WORKBASKET_ID_DISTRIBUTION)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<Void> removeDistributionTargetForWorkbasketId(
|
||||
@PathVariable(value = "workbasketId") String targetWorkbasketId)
|
||||
@PathVariable("workbasketId") String targetWorkbasketId)
|
||||
throws WorkbasketNotFoundException,
|
||||
NotAuthorizedOnWorkbasketException,
|
||||
NotAuthorizedException {
|
||||
|
|
|
@ -4,6 +4,11 @@ import static pro.taskana.common.internal.util.CheckedFunction.wrap;
|
|||
|
||||
import com.fasterxml.jackson.core.type.TypeReference;
|
||||
import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.media.Content;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||
import java.io.IOException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
|
@ -15,7 +20,9 @@ import java.util.Optional;
|
|||
import java.util.Set;
|
||||
import java.util.stream.Collectors;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.hateoas.MediaTypes;
|
||||
import org.springframework.hateoas.config.EnableHypermediaSupport;
|
||||
import org.springframework.http.MediaType;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
|
@ -79,10 +86,30 @@ public class WorkbasketDefinitionController {
|
|||
* @param domain Filter the export for a specific domain.
|
||||
* @return all workbaskets.
|
||||
*/
|
||||
@Operation(
|
||||
summary = "Export Workbaskets",
|
||||
description =
|
||||
"This endpoint exports all Workbaskets with the corresponding Workbasket Access Items "
|
||||
+ "and Distribution Targets. We call this data structure Workbasket Definition.",
|
||||
parameters = {
|
||||
@Parameter(name = "domain", description = "Filter the export for a specific domain.")
|
||||
},
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "200",
|
||||
description = "all workbaskets.",
|
||||
content = {
|
||||
@Content(
|
||||
mediaType = MediaTypes.HAL_JSON_VALUE,
|
||||
schema =
|
||||
@Schema(
|
||||
implementation = WorkbasketDefinitionCollectionRepresentationModel.class))
|
||||
})
|
||||
})
|
||||
@GetMapping(path = RestEndpoints.URL_WORKBASKET_DEFINITIONS)
|
||||
@Transactional(readOnly = true, rollbackFor = Exception.class)
|
||||
public ResponseEntity<WorkbasketDefinitionCollectionRepresentationModel> exportWorkbaskets(
|
||||
@RequestParam(required = false) String[] domain) {
|
||||
@RequestParam(value = "domain", required = false) String[] domain) {
|
||||
WorkbasketQuery query = workbasketService.createWorkbasketQuery();
|
||||
Optional.ofNullable(domain).ifPresent(query::domainIn);
|
||||
|
||||
|
@ -123,7 +150,30 @@ public class WorkbasketDefinitionController {
|
|||
* @throws ConcurrencyException if Workbasket was updated by an other user
|
||||
* @throws NotAuthorizedOnWorkbasketException if the current user has not correct permissions
|
||||
*/
|
||||
@PostMapping(path = RestEndpoints.URL_WORKBASKET_DEFINITIONS)
|
||||
@Operation(
|
||||
summary = "Import Workbaskets",
|
||||
description =
|
||||
"This endpoint imports a list of Workbasket Definitions.<p>This does not exactly match "
|
||||
+ "the REST norm, but we want to have an option to import all settings at once. When"
|
||||
+ " a logical equal (key and domain are equal) Workbasket already exists an update "
|
||||
+ "will be executed. Otherwise a new Workbasket will be created.",
|
||||
requestBody =
|
||||
@io.swagger.v3.oas.annotations.parameters.RequestBody(
|
||||
description =
|
||||
"the list of Workbasket Definitions which will be imported to the current system."
|
||||
+ " To get an example file containing Workbasket Definitions, go to the "
|
||||
+ "[TASKANA UI](http://localhost:8080/taskana/index.html) and export the"
|
||||
+ "Workbaskets",
|
||||
required = true,
|
||||
content = @Content(mediaType = MediaType.MULTIPART_FORM_DATA_VALUE)),
|
||||
responses = {
|
||||
@ApiResponse(
|
||||
responseCode = "204",
|
||||
content = {@Content(schema = @Schema())})
|
||||
})
|
||||
@PostMapping(
|
||||
path = RestEndpoints.URL_WORKBASKET_DEFINITIONS,
|
||||
consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public ResponseEntity<Void> importWorkbaskets(@RequestParam("file") MultipartFile file)
|
||||
throws IOException,
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.workbasket.rest;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.Optional;
|
||||
import pro.taskana.common.rest.QueryParameter;
|
||||
|
@ -11,6 +12,9 @@ import pro.taskana.workbasket.api.WorkbasketType;
|
|||
public class WorkbasketQueryFilterParameter implements QueryParameter<WorkbasketQuery, Void> {
|
||||
|
||||
/** Filter by the name of the Workbasket. This is an exact match. */
|
||||
@Schema(
|
||||
name = "name",
|
||||
description = "Filter by the name of the Workbasket. This is an exact match.")
|
||||
@JsonProperty("name")
|
||||
private final String[] name;
|
||||
|
||||
|
@ -19,10 +23,19 @@ public class WorkbasketQueryFilterParameter implements QueryParameter<Workbasket
|
|||
* beginning and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "name-like",
|
||||
description =
|
||||
"Filter by the name of the Workbasket. This results in a substring search. (% is "
|
||||
+ "appended to beginning and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("name-like")
|
||||
private final String[] nameLike;
|
||||
|
||||
/** Filter by the key of the Workbasket. This is an exact match. */
|
||||
@Schema(
|
||||
name = "key",
|
||||
description = "Filter by the key of the Workbasket. This is an exact match.")
|
||||
@JsonProperty("key")
|
||||
private final String[] key;
|
||||
|
||||
|
@ -31,10 +44,19 @@ public class WorkbasketQueryFilterParameter implements QueryParameter<Workbasket
|
|||
* beginning and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "key-like",
|
||||
description =
|
||||
"Filter by the key of the Workbasket. This results in a substring search.. (% is "
|
||||
+ "appended to the beginning and end of the requested value). Further SQL \"LIKE\""
|
||||
+ " wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("key-like")
|
||||
private final String[] keyLike;
|
||||
|
||||
/** Filter by the owner of the Workbasket. This is an exact match. */
|
||||
@Schema(
|
||||
name = "owner",
|
||||
description = "Filter by the owner of the Workbasket. This is an exact match.")
|
||||
@JsonProperty("owner")
|
||||
private final String[] owner;
|
||||
|
||||
|
@ -43,6 +65,12 @@ public class WorkbasketQueryFilterParameter implements QueryParameter<Workbasket
|
|||
* the beginning and end of the requested value). Further SQL "LIKE" wildcard characters will be
|
||||
* resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "owner-like",
|
||||
description =
|
||||
"Filter by the owner of the Workbasket. This results in a substring search.. (% is "
|
||||
+ "appended to the beginning and end of the requested value). Further SQL \"LIKE\" "
|
||||
+ "wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("owner-like")
|
||||
private final String[] ownerLike;
|
||||
|
||||
|
@ -51,21 +79,76 @@ public class WorkbasketQueryFilterParameter implements QueryParameter<Workbasket
|
|||
* appended to the beginning and end of the requested value). Further SQL "LIKE" wildcard
|
||||
* characters will be resolved correctly.
|
||||
*/
|
||||
@Schema(
|
||||
name = "description-like",
|
||||
description =
|
||||
"Filter by the description of the Workbasket. This results in a substring search.. (% "
|
||||
+ "is appended to the beginning and end of the requested value). Further SQL "
|
||||
+ "\"LIKE\" wildcard characters will be resolved correctly.")
|
||||
@JsonProperty("description-like")
|
||||
private final String[] descriptionLike;
|
||||
|
||||
/** Filter by the domain of the Workbasket. This is an exact match. */
|
||||
@Schema(
|
||||
name = "domain",
|
||||
description = "Filter by the domain of the Workbasket. This is an exact match.")
|
||||
@JsonProperty("domain")
|
||||
private final String[] domain;
|
||||
|
||||
/** Filter by the type of the Workbasket. This is an exact match. */
|
||||
@Schema(
|
||||
name = "type",
|
||||
description = "Filter by the type of the Workbasket. This is an exact match.")
|
||||
@JsonProperty("type")
|
||||
private final WorkbasketType[] type;
|
||||
|
||||
/** Filter by the required permission for the Workbasket. */
|
||||
@Schema(
|
||||
name = "required-permission",
|
||||
description = "Filter by the required permission for the Workbasket.")
|
||||
@JsonProperty("required-permission")
|
||||
private final WorkbasketPermission[] requiredPermissions;
|
||||
|
||||
public String[] getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public String[] getNameLike() {
|
||||
return nameLike;
|
||||
}
|
||||
|
||||
public String[] getKey() {
|
||||
return key;
|
||||
}
|
||||
|
||||
public String[] getKeyLike() {
|
||||
return keyLike;
|
||||
}
|
||||
|
||||
public String[] getOwner() {
|
||||
return owner;
|
||||
}
|
||||
|
||||
public String[] getOwnerLike() {
|
||||
return ownerLike;
|
||||
}
|
||||
|
||||
public String[] getDescriptionLike() {
|
||||
return descriptionLike;
|
||||
}
|
||||
|
||||
public String[] getDomain() {
|
||||
return domain;
|
||||
}
|
||||
|
||||
public WorkbasketType[] getType() {
|
||||
return type;
|
||||
}
|
||||
|
||||
public WorkbasketPermission[] getRequiredPermissions() {
|
||||
return requiredPermissions;
|
||||
}
|
||||
|
||||
@SuppressWarnings("indentation")
|
||||
@ConstructorProperties({
|
||||
"name",
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.workbasket.rest.models;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.Collection;
|
||||
import pro.taskana.common.rest.models.CollectionRepresentationModel;
|
||||
|
@ -15,6 +16,7 @@ public class DistributionTargetsCollectionRepresentationModel
|
|||
}
|
||||
|
||||
/** the embedded distribution targets. */
|
||||
@Schema(name = "distributionTargets", description = "the embedded distribution targets.")
|
||||
@JsonProperty("distributionTargets")
|
||||
@Override
|
||||
public Collection<WorkbasketSummaryRepresentationModel> getContent() {
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.workbasket.rest.models;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.Collection;
|
||||
import pro.taskana.common.rest.models.CollectionRepresentationModel;
|
||||
|
@ -16,6 +17,7 @@ public class WorkbasketAccessItemCollectionRepresentationModel
|
|||
|
||||
/** the embedded access items. */
|
||||
@JsonProperty("accessItems")
|
||||
@Schema(name = "accessItems", description = "the embedded access items.")
|
||||
@Override
|
||||
public Collection<WorkbasketAccessItemRepresentationModel> getContent() {
|
||||
return super.getContent();
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.workbasket.rest.models;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.Collection;
|
||||
import pro.taskana.common.rest.models.PageMetadata;
|
||||
|
@ -16,6 +17,7 @@ public class WorkbasketAccessItemPagedRepresentationModel
|
|||
}
|
||||
|
||||
/** the embedded access items. */
|
||||
@Schema(name = "accessItems", description = "the embedded access items.")
|
||||
@JsonProperty("accessItems")
|
||||
@Override
|
||||
public Collection<WorkbasketAccessItemRepresentationModel> getContent() {
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
package pro.taskana.workbasket.rest.models;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import org.springframework.hateoas.RepresentationModel;
|
||||
import pro.taskana.workbasket.api.models.WorkbasketAccessItem;
|
||||
|
||||
|
@ -8,54 +9,96 @@ public class WorkbasketAccessItemRepresentationModel
|
|||
extends RepresentationModel<WorkbasketAccessItemRepresentationModel> {
|
||||
|
||||
/** Unique Id. */
|
||||
@Schema(name = "accessItemId", description = "Unique Id.")
|
||||
private String accessItemId;
|
||||
/** The workbasket Id. */
|
||||
@Schema(name = "workbasketId", description = "The workbasket Id.")
|
||||
private String workbasketId;
|
||||
/** The Access Id. This could be either a user Id or a full qualified group Id. */
|
||||
@Schema(
|
||||
name = "accessId",
|
||||
description = "The Access Id. This could be either a user Id or a full qualified group Id.")
|
||||
private String accessId;
|
||||
/** The workbasket key. */
|
||||
@Schema(name = "workbasketKey", description = "The workbasket key.")
|
||||
private String workbasketKey;
|
||||
/** The name. */
|
||||
@Schema(name = "accessName", description = "The name.")
|
||||
private String accessName;
|
||||
/** The permission to read the information about the workbasket. */
|
||||
@Schema(
|
||||
name = "permRead",
|
||||
description = "The permission to read the information about the workbasket.")
|
||||
private boolean permRead;
|
||||
/** The permission to access a task from the workbasket. */
|
||||
@Schema(
|
||||
name = "permReadTasks",
|
||||
description = "The permission to access a task from the workbasket.")
|
||||
private boolean permReadTasks;
|
||||
/** The permission to view the content (the tasks) of a workbasket. */
|
||||
@Schema(
|
||||
name = "permOpen",
|
||||
description = "The permission to view the content (the tasks) of a workbasket.")
|
||||
private boolean permOpen;
|
||||
/**
|
||||
* The permission to add tasks to the workbasket. Required for creation and transferring of tasks.
|
||||
*/
|
||||
@Schema(
|
||||
name = "permAppend",
|
||||
description =
|
||||
"The permission to add tasks to the workbasket. Required for creation and transferring "
|
||||
+ "of tasks.")
|
||||
private boolean permAppend;
|
||||
/** The permission to edit a task from the workbasket. */
|
||||
@Schema(
|
||||
name = "permEditTasks",
|
||||
description = "The permission to edit a task from the workbasket.")
|
||||
private boolean permEditTasks;
|
||||
/** The permission to transfer tasks (out of the current workbasket). */
|
||||
@Schema(
|
||||
name = "permTransfer",
|
||||
description = "The permission to transfer tasks (out of the current workbasket).")
|
||||
private boolean permTransfer;
|
||||
/** The permission to distribute tasks from the workbasket. */
|
||||
@Schema(
|
||||
name = "permDistribute",
|
||||
description = "The permission to distribute tasks from the workbasket.")
|
||||
private boolean permDistribute;
|
||||
/** The custom permission with the name "1". */
|
||||
@Schema(name = "permCustom1", description = "The custom permission with the name '1'.")
|
||||
private boolean permCustom1;
|
||||
/** The custom permission with the name "2". */
|
||||
@Schema(name = "permCustom2", description = "The custom permission with the name '2'.")
|
||||
private boolean permCustom2;
|
||||
/** The custom permission with the name "3". */
|
||||
@Schema(name = "permCustom3", description = "The custom permission with the name '3'.")
|
||||
private boolean permCustom3;
|
||||
/** The custom permission with the name "4". */
|
||||
@Schema(name = "permCustom4", description = "The custom permission with the name '4'.")
|
||||
private boolean permCustom4;
|
||||
/** The custom permission with the name "5". */
|
||||
@Schema(name = "permCustom5", description = "The custom permission with the name '5'.")
|
||||
private boolean permCustom5;
|
||||
/** The custom permission with the name "6". */
|
||||
@Schema(name = "permCustom6", description = "The custom permission with the name '6'.")
|
||||
private boolean permCustom6;
|
||||
/** The custom permission with the name "7". */
|
||||
@Schema(name = "permCustom7", description = "The custom permission with the name '7'.")
|
||||
private boolean permCustom7;
|
||||
/** The custom permission with the name "8". */
|
||||
@Schema(name = "permCustom8", description = "The custom permission with the name '8'.")
|
||||
private boolean permCustom8;
|
||||
/** The custom permission with the name "9". */
|
||||
@Schema(name = "permCustom9", description = "The custom permission with the name '9'.")
|
||||
private boolean permCustom9;
|
||||
/** The custom permission with the name "10". */
|
||||
@Schema(name = "permCustom10", description = "The custom permission with the name '10'.")
|
||||
private boolean permCustom10;
|
||||
/** The custom permission with the name "11". */
|
||||
@Schema(name = "permCustom11", description = "The custom permission with the name '11'.")
|
||||
private boolean permCustom11;
|
||||
/** The custom permission with the name "12". */
|
||||
@Schema(name = "permCustom12", description = "The custom permission with the name '12'.")
|
||||
private boolean permCustom12;
|
||||
|
||||
public String getAccessItemId() {
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.workbasket.rest.models;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.Collection;
|
||||
import pro.taskana.common.rest.models.CollectionRepresentationModel;
|
||||
|
@ -15,6 +16,7 @@ public class WorkbasketDefinitionCollectionRepresentationModel
|
|||
}
|
||||
|
||||
/** the embedded workbasket definitions. */
|
||||
@Schema(name = "workbasketDefinitions", description = "the embedded workbasket definitions.")
|
||||
@JsonProperty("workbasketDefinitions")
|
||||
@Override
|
||||
public Collection<WorkbasketDefinitionRepresentationModel> getContent() {
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.workbasket.rest.models;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.HashSet;
|
||||
|
@ -12,11 +13,16 @@ public class WorkbasketDefinitionRepresentationModel
|
|||
extends RepresentationModel<WorkbasketDefinitionRepresentationModel> {
|
||||
|
||||
/** The workbasket which is represented. */
|
||||
@Schema(name = "workbasket", description = "The workbasket which is represented.")
|
||||
@JsonIgnoreProperties("_links")
|
||||
private WorkbasketRepresentationModel workbasket;
|
||||
/** The workbasket authorizations. */
|
||||
@Schema(name = "authorizations", description = "The workbasket authorizations.")
|
||||
private Collection<WorkbasketAccessItemRepresentationModel> authorizations = new ArrayList<>();
|
||||
/** The distribution targets for this workbasket. */
|
||||
@Schema(
|
||||
name = "distributionTargets",
|
||||
description = "The distribution targets for this workbasket.")
|
||||
private Set<String> distributionTargets = new HashSet<>();
|
||||
|
||||
public Set<String> getDistributionTargets() {
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
package pro.taskana.workbasket.rest.models;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.time.Instant;
|
||||
import pro.taskana.workbasket.api.models.Workbasket;
|
||||
|
||||
|
@ -11,12 +12,21 @@ public class WorkbasketRepresentationModel extends WorkbasketSummaryRepresentati
|
|||
*
|
||||
* <p>The format is ISO-8601.
|
||||
*/
|
||||
@Schema(
|
||||
name = "created",
|
||||
description =
|
||||
"The creation timestamp of the workbasket in the system. The format is ISO-8601.")
|
||||
private Instant created;
|
||||
|
||||
/**
|
||||
* The timestamp of the last modification.
|
||||
*
|
||||
* <p>The format is ISO-8601.
|
||||
*/
|
||||
@Schema(
|
||||
name = "modified",
|
||||
description =
|
||||
"The timestamp of the last modification. The format is ISO-8601.")
|
||||
private Instant modified;
|
||||
|
||||
public Instant getCreated() {
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package pro.taskana.workbasket.rest.models;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.beans.ConstructorProperties;
|
||||
import java.util.Collection;
|
||||
import pro.taskana.common.rest.models.PageMetadata;
|
||||
|
@ -16,6 +17,7 @@ public class WorkbasketSummaryPagedRepresentationModel
|
|||
}
|
||||
|
||||
/** the embedded workbaskets. */
|
||||
@Schema(name = "workbaskets", description = "the embedded workbaskets.")
|
||||
@JsonProperty("workbaskets")
|
||||
@Override
|
||||
public Collection<WorkbasketSummaryRepresentationModel> getContent() {
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
package pro.taskana.workbasket.rest.models;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import org.springframework.hateoas.RepresentationModel;
|
||||
import pro.taskana.workbasket.api.WorkbasketType;
|
||||
import pro.taskana.workbasket.api.models.WorkbasketSummary;
|
||||
|
@ -9,38 +10,72 @@ public class WorkbasketSummaryRepresentationModel
|
|||
extends RepresentationModel<WorkbasketSummaryRepresentationModel> {
|
||||
|
||||
/** Unique Id. */
|
||||
@Schema(name = "workbasketId", description = "Unique Id.")
|
||||
protected String workbasketId;
|
||||
|
||||
/** the professional key for the workbasket. */
|
||||
@Schema(name = "key", description = "the professional key for the workbasket.")
|
||||
protected String key;
|
||||
|
||||
/** The name of the workbasket. */
|
||||
@Schema(name = "name", description = "The name of the workbasket.")
|
||||
protected String name;
|
||||
|
||||
/** The domain the workbasket belongs to. */
|
||||
@Schema(name = "domain", description = "The domain the workbasket belongs to.")
|
||||
protected String domain;
|
||||
|
||||
/** The type of the workbasket. */
|
||||
@Schema(name = "type", description = "The type of the workbasket.")
|
||||
protected WorkbasketType type;
|
||||
|
||||
/** the description of the workbasket. */
|
||||
@Schema(name = "description", description = "the description of the workbasket.")
|
||||
protected String description;
|
||||
|
||||
/**
|
||||
* The owner of the workbasket. The owner is responsible for the on-time completion of all tasks
|
||||
* in the workbasket.
|
||||
*/
|
||||
@Schema(
|
||||
name = "owner",
|
||||
description =
|
||||
"The owner of the workbasket. The owner is responsible for the on-time completion of "
|
||||
+ "all tasks in the workbasket.")
|
||||
protected String owner;
|
||||
|
||||
/** A custom property with name "1". */
|
||||
@Schema(name = "custom1", description = "A custom property with name \"1\".")
|
||||
protected String custom1;
|
||||
|
||||
/** A custom property with name "2". */
|
||||
@Schema(name = "custom2", description = "A custom property with name \"2\".")
|
||||
protected String custom2;
|
||||
|
||||
/** A custom property with name "3". */
|
||||
@Schema(name = "custom3", description = "A custom property with name \"3\".")
|
||||
protected String custom3;
|
||||
|
||||
/** A custom property with name "4". */
|
||||
@Schema(name = "custom4", description = "A custom property with name \"4\".")
|
||||
protected String custom4;
|
||||
|
||||
/** A custom property with name "5". */
|
||||
@Schema(name = "custom5", description = "A custom property with name \"5\".")
|
||||
protected String custom5;
|
||||
|
||||
/** A custom property with name "6". */
|
||||
@Schema(name = "custom6", description = "A custom property with name \"6\".")
|
||||
protected String custom6;
|
||||
|
||||
/** A custom property with name "7". */
|
||||
@Schema(name = "custom7", description = "A custom property with name \"7\".")
|
||||
protected String custom7;
|
||||
|
||||
/** A custom property with name "8". */
|
||||
@Schema(name = "custom8", description = "A custom property with name \"8\".")
|
||||
protected String custom8;
|
||||
|
||||
/**
|
||||
* The first Org Level (the top one).
|
||||
*
|
||||
|
@ -48,13 +83,27 @@ public class WorkbasketSummaryRepresentationModel
|
|||
* are used for monitoring and statistical purposes and should reflect who is responsible of the
|
||||
* tasks in the workbasket.
|
||||
*/
|
||||
@Schema(
|
||||
name = "orgLevel1",
|
||||
description =
|
||||
"The first Org Level (the top one).<p>The Org Level is an association with an org "
|
||||
+ "hierarchy level in the organization. The values are used for monitoring and "
|
||||
+ "statistical purposes and should reflect who is responsible of the tasks in the"
|
||||
+ " workbasket.")
|
||||
protected String orgLevel1;
|
||||
|
||||
/** The second Org Level. */
|
||||
@Schema(name = "orgLevel2", description = "The second Org Level.")
|
||||
protected String orgLevel2;
|
||||
|
||||
/** The third Org Level. */
|
||||
@Schema(name = "orgLevel3", description = "The third Org Level.")
|
||||
protected String orgLevel3;
|
||||
|
||||
/** The fourth Org Level (the lowest one). */
|
||||
@Schema(name = "orgLevel4", description = "The fourth Org Level.")
|
||||
protected String orgLevel4;
|
||||
|
||||
/** Identifier to tell if this workbasket can be deleted. */
|
||||
private boolean markedForDeletion;
|
||||
|
||||
|
|
|
@ -5,6 +5,7 @@ import static org.springframework.restdocs.mockmvc.RestDocumentationRequestBuild
|
|||
import static org.springframework.restdocs.mockmvc.RestDocumentationRequestBuilders.post;
|
||||
import static org.springframework.restdocs.mockmvc.RestDocumentationRequestBuilders.put;
|
||||
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.test.web.servlet.result.MockMvcResultMatchers;
|
||||
|
@ -15,6 +16,7 @@ import pro.taskana.classification.rest.models.ClassificationRepresentationModel;
|
|||
import pro.taskana.common.rest.RestEndpoints;
|
||||
import pro.taskana.rest.test.BaseRestDocTest;
|
||||
|
||||
@Disabled
|
||||
class ClassificationControllerRestDocTest extends BaseRestDocTest {
|
||||
|
||||
@Autowired ClassificationRepresentationModelAssembler assembler;
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue