TSK-747 Add history.plugin profile to add history plugin

This commit is contained in:
Martin Rojas Miguel Angel 2019-02-20 11:08:38 +01:00 committed by Holger Hagen
parent 3819b4c5b2
commit 90f3b0b485
7 changed files with 23 additions and 18 deletions

View File

@ -47,7 +47,7 @@ jobs:
script: script:
- (cd web && npm run build:prod) - (cd web && npm run build:prod)
&& mvn clean install -q -f lib -DskipTests -Dmaven.javadoc.skip=true && mvn clean install -q -f lib -DskipTests -Dmaven.javadoc.skip=true
&& mvn clean install -q -f rest -DskipTests -Dmaven.javadoc.skip=true && mvn clean install -q -f rest -DskipTests -Dmaven.javadoc.skip=true -P history.plugin
- stage: "Release / Deploy" - stage: "Release / Deploy"
name: "Release stage" name: "Release stage"
script: script:

View File

@ -29,8 +29,7 @@ function main {
if [[ "$1" == "H2" ]]; then if [[ "$1" == "H2" ]]; then
(cd $REL/../web && npm run test) (cd $REL/../web && npm run test)
mvn clean verify -q -f $REL/../lib/ -B mvn clean verify -q -f $REL/../lib/ -B
mvn clean install -q -f $REL/../rest/ -B mvn clean install -q -f $REL/../rest/ -B -P history.plugin
mvn clean verify -q -f $REL/../rest/ -B -pl taskana-rest-spring-example -P history.plugin
elif [[ "$1" == "POSTGRES_10_4" ]]; then elif [[ "$1" == "POSTGRES_10_4" ]]; then
mvn clean verify -q -f $REL/../lib/taskana-core -B mvn clean verify -q -f $REL/../lib/taskana-core -B
mvn clean install -q -f $REL/../rest/ -B -P postgres mvn clean install -q -f $REL/../rest/ -B -P postgres

View File

@ -28,6 +28,22 @@
</repositories> </repositories>
--> -->
<profiles>
<profile>
<id>history.plugin</id>
<activation>
<activeByDefault>false</activeByDefault>
</activation>
<dependencies>
<dependency>
<groupId>pro.taskana</groupId>
<artifactId>taskana-history-rest-spring</artifactId>
<version>${project.version}</version>
</dependency>
</dependencies>
</profile>
</profiles>
<properties> <properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding> <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
@ -41,16 +57,6 @@
<artifactId>taskana-rest-spring</artifactId> <artifactId>taskana-rest-spring</artifactId>
<version>${project.version}</version> <version>${project.version}</version>
</dependency> </dependency>
<dependency>
<groupId>pro.taskana</groupId>
<artifactId>taskana-history-rest-spring</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>pro.taskana.simplehistory</groupId>
<artifactId>taskana-simplehistory-provider</artifactId>
<version>0.0.6</version>
</dependency>
<dependency> <dependency>
<groupId>org.springframework.boot</groupId> <groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId> <artifactId>spring-boot-starter-web</artifactId>

View File

@ -9,7 +9,7 @@ import org.springframework.web.bind.annotation.RequestMapping;
@Controller @Controller
public class ViewController { public class ViewController {
@RequestMapping({"", "/administration*/**", "/workplace*/**", "/monitor*/**", "/no-role*/**"}) @RequestMapping({"", "/administration*/**", "/workplace*/**", "/monitor*/**", "/history*/**", "/no-role*/**"})
public String index() { public String index() {
return "forward:/index.html"; return "forward:/index.html";
} }

View File

@ -11,7 +11,7 @@
<h4 class="panel-header">Taskana history query</h4> <h4 class="panel-header">Taskana history query</h4>
</div> </div>
<div class="panel-body"> <div class="panel-body">
<div class="divTable table-striped"> <div class="divTable table-striped" *ngIf="taskQuery">
<form [formGroup]="taskQueryForm"> <form [formGroup]="taskQueryForm">
<div class="divTableHeading"> <div class="divTableHeading">
<div class="divTableRow"> <div class="divTableRow">

View File

@ -170,7 +170,7 @@ export class TaskQueryComponent implements OnInit {
} }
private performRequest() { private performRequest() {
setTimeout(() => this.requestInProgressService.setRequestInProgress(true), 1) this.requestInProgressService.setRequestInProgress(true);
this.calculateQueryPages(); this.calculateQueryPages();
this.taskQuerySubscription = this.taskQueryService.queryTask( this.taskQuerySubscription = this.taskQueryService.queryTask(
this.orderBy.sortBy.replace(/([A-Z])|([0-9])/g, (g) => `-${g[0].toLowerCase()}`), this.orderBy.sortBy.replace(/([A-Z])|([0-9])/g, (g) => `-${g[0].toLowerCase()}`),
@ -195,7 +195,7 @@ export class TaskQueryComponent implements OnInit {
this.taskQueryForm.get('custom3') ? this.taskQueryForm.get('custom3').value : undefined, this.taskQueryForm.get('custom3') ? this.taskQueryForm.get('custom3').value : undefined,
this.taskQueryForm.get('custom4') ? this.taskQueryForm.get('custom4').value : undefined, this.taskQueryForm.get('custom4') ? this.taskQueryForm.get('custom4').value : undefined,
false).subscribe(taskQueryResource => { false).subscribe(taskQueryResource => {
this.requestInProgressService.setRequestInProgress(false) this.requestInProgressService.setRequestInProgress(false);
if (!taskQueryResource._embedded) { if (!taskQueryResource._embedded) {
this.taskQuery = null; this.taskQuery = null;
this.taskQueryResource = null; this.taskQueryResource = null;

View File

@ -9,7 +9,7 @@ export class RequestInProgressService {
constructor() { } constructor() { }
setRequestInProgress(value: boolean) { setRequestInProgress(value: boolean) {
this.requestInProgressTriggered.next(value); setTimeout(() => this.requestInProgressTriggered.next(value), 0);
} }
getRequestInProgress(): Observable<boolean> { getRequestInProgress(): Observable<boolean> {