Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IVYPORTAL-17431 Remove Express from Portal #1051

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
dc2d88b
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Remove ChatRende…
ntloc-axonivy Sep 17, 2024
55f6fdb
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Remove from Abst…
ntloc-axonivy Sep 18, 2024
500761e
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Remove all AdHoc…
ntloc-axonivy Sep 18, 2024
a01c6b9
feature/IVYPORTAL-17431-Remove-Express-from-Portal - remove process e…
ntloc-axonivy Sep 18, 2024
d294b41
Merge branch 'master' into feature/IVYPORTAL-17431-Remove-Express-fro…
ntloc-axonivy Sep 19, 2024
163bd26
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Remove express f…
ntloc-axonivy Sep 19, 2024
2374cac
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Make sidestep nicer
ntloc-axonivy Sep 19, 2024
1c08ebc
Merge branch 'master' into feature/IVYPORTAL-17431-Remove-Express-fro…
ntloc-axonivy Sep 19, 2024
199e358
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Remove from case…
ntloc-axonivy Sep 19, 2024
3b3f94e
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Remove Express M…
ntloc-axonivy Sep 19, 2024
7773ac3
feature/IVYPORTAL-17427-Remove-old-statistics-Area - Remove gui test …
ntloc-axonivy Sep 20, 2024
59551cc
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Fix gui test part 2
ntloc-axonivy Sep 20, 2024
80d9cb7
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Update gui test …
ntloc-axonivy Sep 20, 2024
661f98d
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Fix gui test part 4
ntloc-axonivy Sep 20, 2024
e7b2086
Merge branch 'master' into feature/IVYPORTAL-17431-Remove-Express-fro…
ntloc-axonivy Sep 23, 2024
a3173a7
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Fix merge
ntloc-axonivy Sep 23, 2024
2df7406
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Remove cms
ntloc-axonivy Sep 23, 2024
5ef801f
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Remove css p2
ntloc-axonivy Sep 23, 2024
5683590
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Fix GUI test
ntloc-axonivy Sep 23, 2024
5bacfcd
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Change slave
ntloc-axonivy Sep 23, 2024
818164a
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Remove express f…
ntloc-axonivy Sep 23, 2024
b9f8bdc
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Remove express f…
ntloc-axonivy Sep 23, 2024
622d700
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Fix screenshot
ntloc-axonivy Sep 23, 2024
514b69c
Merge branch 'master' into feature/IVYPORTAL-17431-Remove-Express-fro…
ntloc-axonivy Sep 23, 2024
78e43d6
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Update build int…
ntloc-axonivy Sep 23, 2024
8288039
feature/IVYPORTAL-17431-Remove-Express-from-Portal - Handle feedback
ntloc-axonivy Sep 25, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -1351,63 +1351,6 @@
"connect" : [
{ "id" : "f139", "to" : "S10" }
]
}, {
"id" : "f145",
"type" : "RequestStart",
"name" : "createSampleExpressWorkflowProcess.ivp",
"config" : {
"signature" : "createSampleExpressWorkflowProcess",
"input" : {
"params" : [
{ "name" : "filePath", "type" : "String", "desc" : "" }
],
"map" : {
"out.expressExportFilePath" : "param.filePath"
}
},
"request" : {
"isVisibleOnStartList" : false
}
},
"visual" : {
"at" : { "x" : 816, "y" : 1280 },
"labelOffset" : { "x" : 5, "y" : 49 }
},
"connect" : [
{ "id" : "f148", "to" : "f147" }
]
}, {
"id" : "f146",
"type" : "TaskEnd",
"visual" : {
"at" : { "x" : 1120, "y" : 1280 }
}
}, {
"id" : "f147",
"type" : "Script",
"name" : "Import Express from file",
"config" : {
"output" : {
"code" : [
"import java.util.Map;",
"import java.io.FileInputStream;",
"import java.io.InputStream;",
"import ch.ivy.addon.portalkit.util.ExpressManagementUtils;",
"",
"Map output = ExpressManagementUtils.initOutputMessage();",
"InputStream inputstream = new FileInputStream(in.expressExportFilePath);",
"ExpressManagementUtils.installExpressWorkflows(inputstream, output);"
]
},
"sudo" : true
},
"visual" : {
"at" : { "x" : 984, "y" : 1280 },
"size" : { "width" : 144 }
},
"connect" : [
{ "id" : "f149", "to" : "f146" }
]
}, {
"id" : "f150",
"type" : "RequestStart",
Expand Down Expand Up @@ -1821,19 +1764,6 @@
"import ch.ivy.addon.portalkit.service.ExternalLinkService;",
"import ch.ivyteam.ivy.security.ISecurityContext;",
"import ch.ivy.addon.portalkit.configuration.ExternalLink;",
"import ch.ivy.addon.portalkit.service.ExpressProcessService;",
"import ch.ivy.addon.portalkit.bo.ExpressProcess;",
"ExpressProcess expressProcess = new ExpressProcess();",
"expressProcess.ableToEdit = true;",
"expressProcess.processName = \"A sample for Express process\";",
"expressProcess.processDescription = \"A sample for Express process\";",
"expressProcess.readyToExecute = true;",
"expressProcess.processFolder = \"test\";",
"expressProcess.processType = \"AHWF\";",
"expressProcess.processPermissions = [\"#demo\"];",
"expressProcess.processOwner = \"#demo\";",
"ExpressProcessService expressProcessService = new ExpressProcessService();",
"expressProcessService.save(expressProcess);",
"",
"ExternalLink externalLink = new ExternalLink();",
"externalLink.name = \"A sample for External link to Google\";",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -446,12 +446,7 @@
"import ch.ivyteam.ivy.security.restricted.permission.IPermissionRepository;",
"import ch.ivyteam.ivy.security.IPermission;",
"",
"IPermission iPermission = IPermissionRepository.instance().findByName(PortalPermission.EXPRESS_CREATE_WORKFLOW.getValue());",
" if (Objects.nonNull(iPermission)){",
" ISecurityContext.current().securityDescriptor().grantPermission(iPermission, ivy.session.getSessionUser());",
" }",
"",
" iPermission = IPermissionRepository.instance().findByName(PortalPermission.SHOW_CASE_DETAILS.getValue());",
" IPermission iPermission = IPermissionRepository.instance().findByName(PortalPermission.SHOW_CASE_DETAILS.getValue());",
" if (Objects.nonNull(iPermission)){",
" ISecurityContext.current().securityDescriptor().grantPermission(iPermission, ivy.session.getSessionUser());",
" }",
Expand Down Expand Up @@ -594,12 +589,7 @@
"import ch.ivyteam.ivy.security.restricted.permission.IPermissionRepository;",
"import ch.ivyteam.ivy.security.IPermission;",
"",
" IPermission iPermission = IPermissionRepository.instance().findByName(PortalPermission.EXPRESS_CREATE_WORKFLOW.getValue());",
" if (Objects.nonNull(iPermission)){",
" ISecurityContext.current().securityDescriptor().denyPermission(iPermission, ivy.session.getSessionUser());",
" }",
"",
" iPermission = IPermissionRepository.instance().findByName(PortalPermission.SHOW_CASE_DETAILS.getValue());",
" IPermission iPermission = IPermissionRepository.instance().findByName(PortalPermission.SHOW_CASE_DETAILS.getValue());",
" if (Objects.nonNull(iPermission)){",
" ISecurityContext.current().securityDescriptor().denyPermission(iPermission, ivy.session.getSessionUser());",
" }",
Expand Down
1 change: 0 additions & 1 deletion AxonIvyPortal/portal-components/cms/cms.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ Dialogs:
ProcessIsHidden: The current process is hidden!
ProcessType:
CASE_MAP: Case Map
EXPRESS_PROCESS: Express Workflow
EXTERNAL_LINK: External Link
IVY_PROCESS: Business Process
Labels:
Expand Down
1 change: 0 additions & 1 deletion AxonIvyPortal/portal-components/cms/cms_de.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,6 @@ Dialogs:
ProcessNotFound: Der definierte Process kann nicht gefunden werden.
ProcessType:
CASE_MAP: Fall Karte
EXPRESS_PROCESS: Express Workflow
EXTERNAL_LINK: External Link
IVY_PROCESS: Geschäftsprozess
ProcessViewerIFrameTitle: Prozessbetrachterrahmen
Expand Down
1 change: 0 additions & 1 deletion AxonIvyPortal/portal-components/cms/cms_en.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,6 @@ Dialogs:
ProcessNotFound: The defined process cannot be found.
ProcessType:
CASE_MAP: Case Map
EXPRESS_PROCESS: Express Workflow
EXTERNAL_LINK: External Link
IVY_PROCESS: Business Process
ProcessViewerIFrameTitle: Process viewer frame
Expand Down
1 change: 0 additions & 1 deletion AxonIvyPortal/portal-components/cms/cms_es.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,6 @@ Dialogs:
ProcessNotFound: No se encuentra el proceso definido.
ProcessType:
CASE_MAP: Mapa del caso
EXPRESS_PROCESS: Flujo de trabajo exprés
EXTERNAL_LINK: Link externo
IVY_PROCESS: Proceso de negocio
ProcessViewerIFrameTitle: Marco del visor de procesos
Expand Down
1 change: 0 additions & 1 deletion AxonIvyPortal/portal-components/cms/cms_fr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,6 @@ Dialogs:
ProcessNotFound: Le processus défini est introuvable.
ProcessType:
CASE_MAP: Carte de cas
EXPRESS_PROCESS: Flux de travail express
EXTERNAL_LINK: Lien externe
IVY_PROCESS: Processus d'entreprise
ProcessViewerIFrameTitle: Cadre de visualisation du processus
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package com.axonivy.portal.components.constant;

public class CustomFields {
public static final String IS_EXPRESS_PROCESS = "isExpress";
public static final String IS_DASHBOARD_PROCESS = "isDashboardProcess";
public static final String BUSINESS_DETAILS = "businessDetails";
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ public enum PortalVariable {
THIRD_PARTY_APP("Portal.ThirdPartyApplications"),
WIDGET_FILTER("Portal.Dashboard.WidgetFilters"),
EXTERNAL_LINK("Portal.Processes.ExternalLinks"),
EXPRESS_PROCESS("Portal.Processes.ExpressProcesses"),
TASK_DETAIL("Portal.TaskDetails"),
CASE_DETAIL("Portal.CaseDetails"),
DASHBOARD("Portal.Dashboard"),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
import ch.ivyteam.ivy.environment.Ivy;

public enum ProcessType {
EXPRESS_PROCESS("ExpressProcess"),
EXTERNAL_LINK("ExternalLink"),
CASE_MAP("casemap"),
IVY_PROCESS("process-start");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@

public class CaseDocumentService {

public static final String EXPRESS_UPLOAD_FOLDER = "AxonIvyExpress";
private ICase iCase;

private CaseDocumentService(ICase iCase) {
Expand All @@ -51,15 +50,7 @@ public IDocument upload(String filename, InputStream content) {
}

public List<IDocument> getAll() {
List<IDocument> documents = new ArrayList<>(getAllDocumentsOf(iCase));
List<IDocument> expressDocs = new ArrayList<>();
for (IDocument doc : documents) {
if (doc.getPath().asString().contains(EXPRESS_UPLOAD_FOLDER)) {
expressDocs.add(doc);
}
}
documents.removeAll(expressDocs);
return new ArrayList<>(documents);
return new ArrayList<>(getAllDocumentsOf(iCase));
}

/**
Expand All @@ -74,7 +65,7 @@ public StreamedContent download(IvyDocument document) {

public boolean doesDocumentExist(String filename) {
IDocument document = documentsOf(iCase).get(new Path(filename));
return document != null && !document.getPath().asString().contains(EXPRESS_UPLOAD_FOLDER);
return document != null;
}

public static boolean isDocumentTypeValid(String filename, String allowedFileTypes) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,8 @@
import java.util.function.Predicate;

import org.apache.commons.collections4.CollectionUtils;
import org.apache.commons.lang3.BooleanUtils;
import org.apache.commons.lang3.StringUtils;

import com.axonivy.portal.components.constant.CustomFields;
import com.axonivy.portal.components.dto.ProcessViewerDTO;
import com.axonivy.portal.components.service.impl.ProcessService;

Expand Down Expand Up @@ -132,11 +130,6 @@ private static List<IWebStartable> getWebStartables() {
return Optional.ofNullable(webStartables).orElse(new ArrayList<>());
}

public static boolean isExpressCase(ICase iCase) {
return iCase != null
&& BooleanUtils.toBoolean(iCase.customFields().stringField(CustomFields.IS_EXPRESS_PROCESS).getOrNull());
}

public static ICaseMap findCaseMapByCase(ICase caze) {
if (Objects.isNull(caze)) {
return null;
Expand All @@ -149,7 +142,7 @@ public static boolean hasCaseMap(IBusinessCase businessCase) {
}

public static boolean isViewerAllowed(ICase caze) {
if (caze == null || isExpressCase(caze) || !caze.isBusinessCase()) {
if (caze == null || !caze.isBusinessCase()) {
return false;
} else if (hasCaseMap(caze.getBusinessCase())) {
return true;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"$schema" : "https://json-schema.axonivy.com/data-class/11.4.0/data-class.json",
"simpleName" : "ExpressResponsible",
"simpleName" : "Responsible",
"namespace" : "ch.ivyteam.ivy.project.portal.test",
"isBusinessCaseData" : false,
"fields" : [ {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -153,16 +153,12 @@ function highlightProcessItems() {
createRedMediumOutline(processSearch);
appendStepAnnotation(processSearch, "1", -5, processSearch.width() - 40);

var expressLogo = $('.express-workflow .image-process-icon:eq(0)');
createRedMediumOutline(expressLogo);
appendStepAnnotation(expressLogo, "2", -15, -30);

var externalLink = $('.js-external-link-process-item .image-process-icon:eq(0)');
createRedMediumOutline(externalLink);
appendStepAnnotation(externalLink, "3", -15, -30);
appendStepAnnotation(externalLink, "2", -15, -30);

createRedMediumOutline($('[id$="process-widget:process-view-mode:view-mode-selection"]'));
appendStepAnnotation($("[id$='process-widget:process-view-mode:view-mode-selection'] div[class$='ui-state-active']"), "4", -10, -40);
appendStepAnnotation($("[id$='process-widget:process-view-mode:view-mode-selection'] div[class$='ui-state-active']"), "3", -10, -40);
}

function highlightEditProcessIcon() {
Expand Down Expand Up @@ -192,7 +188,6 @@ function highlightAdminSettings() {

function highlightUserMenuConfiguration() {
createRedMediumOutline($("a[id$='menu-configuration-0']"));
createRedMediumOutline($("a[id$='menu-configuration-1']"));
}

function highlightCaseMenuItem() {
Expand Down Expand Up @@ -346,40 +341,6 @@ function highlightShowWorkflowEvents() {
createRedMediumOutline($("a[id$=':task-workflow-event-command']"));
}

function highlightCreateExpressWorkflow() {
createRedMediumOutline($("[id$='process-widget:create-express-link']"));
}

function highlightExpressTaskResponsible(stepNumber) {
var taskResponsible = '.task-responsible:eq(' + stepNumber + ')';
createRedMediumOutline($(taskResponsible));
}

function highlightManagementExpressTab() {
$("a[href$=':adminTabView:express-management-tab']").parent().addClass("red-medium-border");
}

function highlightDeployExpress() {
createRedMediumOutline($(".ui-fileupload-upload"));
}

function highlightExportExpress() {
var expressTable = $("[id$=':express-management-component:express-management-form:express-workflow-summary-table']");
var checkAll = expressTable.find(".express-selection-column:eq(0)").find(".ui-chkbox-box");
createRedMediumOutline(checkAll);
appendStepAnnotation(checkAll, 1, -10, checkAll.width() + 10);

var exportButton = $("[id$=':express-management-component:express-management-form:export-express-btn']");
appendStepAnnotation(exportButton, 2, -10, exportButton.width() + 15);
}

function cleanHighlightExportExpress() {
var expressTable = $("[id$=':express-management-component:express-management-form:express-workflow-summary-table']");
var checkAll = expressTable.find(".express-selection-column:eq(0)").find(".ui-chkbox-box");
checkAll.removeClass("red-medium-outline");
$('.marker').remove();
}

function scrollToMiddleOfLayoutContent() {
window.scrollTo(0, document.body.scrollHeight/2);
}
Expand Down Expand Up @@ -462,10 +423,6 @@ function highlightShowAllProcesses() {
createRedThickOutlineWithOffset($('.layout-menu .PROCESS'));
}

function highlightShowAdditionalLink() {
createRedMediumOutline($("[id$='case-item:case-item-action-form:action-step-component:show-additional-case-details-link']"));
}

function highlightTaskExportToExcelButton() {
createRedMediumOutline($("[id$=':task-export-to-excel-form']"));
}
Expand Down
Loading
Loading