Skip to content
This repository has been archived by the owner on Sep 6, 2020. It is now read-only.

Commit

Permalink
add plugin-tasklist-detail-iframe
Browse files Browse the repository at this point in the history
  • Loading branch information
Sebastian Warnke committed Apr 10, 2019
1 parent ebe67b8 commit a66f1d4
Show file tree
Hide file tree
Showing 7 changed files with 136 additions and 0 deletions.
70 changes: 70 additions & 0 deletions snippets/plugin-tasklist-detail-iframe/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<groupId>com.camunda.consulting.example.plugin.tasklist.detail</groupId>
<artifactId>tasklist-plugin-iframe-detail</artifactId>
<version>1.0.0-SNAPSHOT</version>

<packaging>jar</packaging>

<url></url>

<properties>
<camunda.version>7.10.3-ee</camunda.version>
<maven.compiler.source>1.9</maven.compiler.source>
<maven.compiler.target>1.9</maven.compiler.target>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>

<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.camunda.bpm</groupId>
<artifactId>camunda-bom</artifactId>
<version>${camunda.version}</version>
<scope>import</scope>
<type>pom</type>
</dependency>
</dependencies>
</dependencyManagement>

<dependencies>
<dependency>
<!-- Cockpit Plugin API, needs to be provided -->
<groupId>org.camunda.bpm.webapp</groupId>
<artifactId>camunda-webapp</artifactId>
<classifier>classes</classifier>
<!-- not part of camunda bom -->
<scope>provided</scope>
</dependency>
<dependency>
<!-- process engine, needs to be provided -->
<groupId>org.camunda.bpm</groupId>
<artifactId>camunda-engine</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<!-- Java EE 6 APIs -->
<groupId>javax</groupId>
<artifactId>javaee-api</artifactId>
<version>6.0</version>
<scope>provided</scope>
</dependency>

<!-- Add your own dependencies here, if in compile scope, they are added to the war -->

</dependencies>

<repositories>
<repository>
<id>camunda-bpm-nexus</id>
<name>camunda-bpm-nexus</name>
<url>https://app.camunda.com/nexus/content/groups/public</url>
</repository>
</repositories>

<build>
<finalName>${project.artifactId}</finalName>
</build>
</project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
package com.camunda.consulting.example.plugin.tasklist.detail;

import java.util.HashSet;
import java.util.Set;

import org.camunda.bpm.tasklist.plugin.spi.impl.AbstractTasklistPlugin;

import com.camunda.consulting.example.plugin.tasklist.detail.resources.IframeDetailTasklistPluginRootResource;

public class IframeDetailTasklistPlugin extends AbstractTasklistPlugin {

public static final String ID = "iframe-detail-tasklist-plugin";

public String getId() {
return ID;
}

@Override
public Set<Class<?>> getResourceClasses() {
Set<Class<?>> classes = new HashSet<Class<?>>();
classes.add(IframeDetailTasklistPluginRootResource.class);
return classes;
}

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
package com.camunda.consulting.example.plugin.tasklist.detail.resources;

import javax.ws.rs.Path;

import org.camunda.bpm.tasklist.resource.AbstractTasklistPluginRootResource;

import com.camunda.consulting.example.plugin.tasklist.detail.IframeDetailTasklistPlugin;

@Path("plugin/" + IframeDetailTasklistPlugin.ID)
public class IframeDetailTasklistPluginRootResource extends AbstractTasklistPluginRootResource {
public IframeDetailTasklistPluginRootResource() {
super(IframeDetailTasklistPlugin.ID);
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
com.camunda.consulting.example.plugin.tasklist.detail.IframeDetailTasklistPlugin
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<div class="form-inline">

<iframe src="https://www.camunda.com"></iframe>

</div>
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
// this file is required but does not have content here
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
define(['angular'], function(angular) {

var Configuration = ['ViewsProvider', function(ViewsProvider) {

ViewsProvider.registerDefaultView('tasklist.task.detail', {
id: 'iframe-detail-tasklist-plugin',
label: 'iframe Detail',
url: 'plugin://iframe-detail-tasklist-plugin/static/app/iframe.html',

// less priority as form-detail plugin (https://github.com/camunda/camunda-tasklist-ui/blob/master/client/scripts/task/plugins/detail/cam-tasklist-task-detail-form-plugin.js)
priority: 800
});
}];

var ngModule = angular.module('tasklist.plugin.iframe-detail-tasklist-plugin', []);

ngModule.config(Configuration);

return ngModule;
});

0 comments on commit a66f1d4

Please sign in to comment.