diff --git a/AxonIvyPortal/PortalKitTestHelper/src_hd/ch/ivy/addon/portalkit/test/DataCreation/DataCreation.xhtml b/AxonIvyPortal/PortalKitTestHelper/src_hd/ch/ivy/addon/portalkit/test/DataCreation/DataCreation.xhtml index 9fb09525011..b55830140b8 100644 --- a/AxonIvyPortal/PortalKitTestHelper/src_hd/ch/ivy/addon/portalkit/test/DataCreation/DataCreation.xhtml +++ b/AxonIvyPortal/PortalKitTestHelper/src_hd/ch/ivy/addon/portalkit/test/DataCreation/DataCreation.xhtml @@ -1,25 +1,37 @@ - -

Create tasks

- - - - - - - - - - - - - - - - + + Create tasks + + +
+ + + + + + + + + + + + + + +
+
+ +
+
- \ No newline at end of file + + diff --git a/AxonIvyPortal/PortalKitTestHelper/webContent/layouts/frame-10.xhtml b/AxonIvyPortal/PortalKitTestHelper/webContent/layouts/frame-10.xhtml new file mode 100644 index 00000000000..4f33eb13ed2 --- /dev/null +++ b/AxonIvyPortal/PortalKitTestHelper/webContent/layouts/frame-10.xhtml @@ -0,0 +1,60 @@ + + + + + + + + + + <ui:insert name="title">Ivy Html Dialog</ui:insert> + + + + + + + + + +
+ + default content + +
+ + + + + + + +
+ diff --git a/AxonIvyPortal/portal-components/src/com/axonivy/portal/components/ivydata/bo/JsonVersion.java b/AxonIvyPortal/portal-components/src/com/axonivy/portal/components/ivydata/bo/JsonVersion.java index c5b79675b9a..41f2b12c747 100644 --- a/AxonIvyPortal/portal-components/src/com/axonivy/portal/components/ivydata/bo/JsonVersion.java +++ b/AxonIvyPortal/portal-components/src/com/axonivy/portal/components/ivydata/bo/JsonVersion.java @@ -5,7 +5,7 @@ import org.apache.commons.lang3.StringUtils; public class JsonVersion implements Comparable { - public static final JsonVersion LATEST = new JsonVersion("10.0.0"); + public static final JsonVersion LATEST = new JsonVersion("12.0.0"); private String value; diff --git a/AxonIvyPortal/portal/config/variables.yaml b/AxonIvyPortal/portal/config/variables.yaml index 05d9d33f6c3..c7242e6ff95 100644 --- a/AxonIvyPortal/portal/config/variables.yaml +++ b/AxonIvyPortal/portal/config/variables.yaml @@ -72,8 +72,8 @@ Variables: # Set URL to download Axon Ivy mobile app on Google Play. GooglePlayURL: 'https://play.google.com/store/apps/details?id=com.axonivy&pli=1' - # You can configure the look and feel for dashboard according to your needs via this json file. - # This setting will be taken over for all other dashboard. + # You can configure the look and feel of the dashboard according to your needs via this JSON file. + # These settings will apply to all other dashboards. # [file: json] Dashboard: # You can customize the name and icon of the main menu entry for Portal dashboards via this JSON file. diff --git a/AxonIvyPortal/portal/config/variables/Portal/Dashboard.json b/AxonIvyPortal/portal/config/variables/Portal/Dashboard.json index e54f226b68a..2aaa50dba32 100644 --- a/AxonIvyPortal/portal/config/variables/Portal/Dashboard.json +++ b/AxonIvyPortal/portal/config/variables/Portal/Dashboard.json @@ -1,7 +1,7 @@ [ { "id": "1", - "version": "11.4.0", + "version": "12.0.0", "templateId": "default-portal-dashboard-template", "titles": [ { @@ -51,7 +51,6 @@ "y": 2 }, "enableQuickSearch": true, - "rowsPerPage": 5, "columns": [ { "field": "start" @@ -61,21 +60,17 @@ }, { "field": "id", - "visible": false, - "quickSearch": false + "visible": false }, { - "field": "name", - "quickSearch": true + "field": "name" }, { "field": "description", - "visible": false, - "quickSearch": false + "visible": false }, { - "field": "activator", - "quickSearch": false + "field": "activator" }, { "field": "state", @@ -90,8 +85,7 @@ }, { "field": "category", - "visible": false, - "quickSearch": false + "visible": false }, { "field": "actions" @@ -140,27 +134,23 @@ "x": 3, "y": 8 }, - "rowsPerPage": 5, + "enableQuickSearch": true, "columns": [ { - "field": "id", - "quickSearch": false + "field": "id" }, { - "field": "name", - "quickSearch": true + "field": "name" }, { "field": "description", - "visible": false, - "quickSearch": false + "visible": false }, { "field": "state" }, { - "field": "creator", - "quickSearch": false + "field": "creator" }, { "field": "startTimestamp" @@ -171,8 +161,7 @@ }, { "field": "category", - "visible": false, - "quickSearch": false + "visible": false }, { "field": "actions" @@ -331,7 +320,7 @@ }, { "id": "default-task-list-dashboard", - "version": "11.4.0", + "version": "12.0.0", "templateId": "create-from-scratch", "titles": [ { diff --git a/AxonIvyPortal/portal/config/variables/Portal/DashboardTemplates.json b/AxonIvyPortal/portal/config/variables/Portal/DashboardTemplates.json index c1d838f125b..298ad622469 100644 --- a/AxonIvyPortal/portal/config/variables/Portal/DashboardTemplates.json +++ b/AxonIvyPortal/portal/config/variables/Portal/DashboardTemplates.json @@ -1,6 +1,6 @@ [ { - "version": "11.4.0", + "version": "12.0.0", "id": "default-portal-dashboard-template", "titles": [ { @@ -71,7 +71,6 @@ "y": 2 }, "enableQuickSearch": true, - "rowsPerPage": 5, "canWorkOn": true, "columns": [ { @@ -82,37 +81,30 @@ }, { "field": "id", - "visible": false, - "quickSearch": false + "visible": false }, { - "field": "name", - "quickSearch": true + "field": "name" }, { "field": "description", - "visible": false, - "quickSearch": false + "visible": false }, { - "field": "activator", - "quickSearch": false + "field": "activator" }, { - "field": "state", - "visible": false + "field": "state" }, { - "field": "startTimestamp", - "visible": false + "field": "startTimestamp" }, { "field": "expiryTimestamp" }, { "field": "category", - "visible": false, - "quickSearch": false + "visible": false }, { "field": "actions" @@ -160,27 +152,23 @@ "x": 3, "y": 8 }, - "rowsPerPage": 5, + "enableQuickSearch": true, "columns": [ { - "field": "id", - "quickSearch": false + "field": "id" }, { - "field": "name", - "quickSearch": true + "field": "name" }, { "field": "description", - "visible": false, - "quickSearch": false + "visible": false }, { "field": "state" }, { - "field": "creator", - "quickSearch": false + "field": "creator" }, { "field": "startTimestamp" @@ -191,8 +179,7 @@ }, { "field": "category", - "visible": false, - "quickSearch": false + "visible": false }, { "field": "actions" @@ -351,7 +338,7 @@ } }, { - "version": "11.4.0", + "version": "12.0.0", "id": "two-task-widget-dashboard-template", "titles": [ { @@ -410,7 +397,7 @@ "x": 0, "y": 0 }, - "rowsPerPage": 5, + "enableQuickSearch": true, "sortDescending": true, "columns": [ { @@ -427,8 +414,7 @@ }, { "field": "description", - "visible": false, - "quickSearch": false + "visible": false }, { "field": "activator", @@ -473,7 +459,7 @@ "x": 0, "y": 5 }, - "rowsPerPage": 5, + "enableQuickSearch": true, "sortDescending": true, "columns": [ { @@ -490,8 +476,7 @@ }, { "field": "description", - "visible": false, - "quickSearch": false + "visible": false }, { "field": "activator", @@ -536,7 +521,8 @@ "h": 10, "x": 9, "y": 0 - } + }, + "enableQuickSearch": true } ], "permissions": [ @@ -545,7 +531,7 @@ } }, { - "version": "11.4.0", + "version": "12.0.0", "id": "accessibility-dashboard-template", "titles": [ { @@ -591,7 +577,7 @@ "widgets": [ { "type": "task", - "id": "task_d898829cd7a745a0812f44923e3596d1", + "id": "task_1", "names": [ { "locale": "en", @@ -616,9 +602,7 @@ "x": 3, "y": 3 }, - "rowsPerPage": 5, - "enableQuickSearch": false, - "showWidgetInfo": true, + "enableQuickSearch": true, "showFullscreenMode": false, "columns": [ { @@ -628,15 +612,13 @@ "field": "actions" }, { - "field": "name", - "quickSearch": false + "field": "name" }, { "field": "priority" }, { - "field": "activator", - "quickSearch": false + "field": "activator" }, { "field": "state" @@ -649,18 +631,15 @@ }, { "field": "id", - "visible": false, - "quickSearch": false + "visible": false }, { "field": "description", - "visible": false, - "quickSearch": false + "visible": false }, { "field": "category", - "visible": false, - "quickSearch": false + "visible": false } ], "sortField": "id", @@ -669,7 +648,7 @@ }, { "type": "compact-process", - "id": "process_de6d9dc244334aeeafeef353d5f70488", + "id": "process_1", "names": [ { "locale": "en", @@ -695,13 +674,11 @@ "y": 3 }, "showFullscreenMode": false, - "showWidgetInfo": true, - "sorting": "BY_ALPHABETICALLY", - "enableQuickSearch": false + "enableQuickSearch": true }, { "type": "custom", - "id": "custom_e736fea7d4044b21b17a21a5b694e6a9", + "id": "custom_1", "names": [ { "locale": "en", @@ -733,7 +710,7 @@ }, { "type": "case", - "id": "case_46a4814004424383872bf5c19098d657", + "id": "case_1", "names": [ { "locale": "en", @@ -758,31 +735,25 @@ "x": 3, "y": 7 }, - "rowsPerPage": 5, - "enableQuickSearch": false, - "showWidgetInfo": true, + "enableQuickSearch": true, "showFullscreenMode": false, "columns": [ { "field": "id", - "visible": false, - "quickSearch": false + "visible": false }, { - "field": "name", - "quickSearch": false + "field": "name" }, { "field": "description", - "visible": false, - "quickSearch": false + "visible": false }, { "field": "state" }, { - "field": "creator", - "quickSearch": false + "field": "creator" }, { "field": "startTimestamp" @@ -795,15 +766,11 @@ }, { "field": "category", - "visible": false, - "quickSearch": false + "visible": false }, { "field": "application", - "styleClass": "dashboard-tasks__priority u-text-align-center", - "style": "width: 80px", - "visible": false, - "quickSearch": false + "visible": false }, { "field": "actions" diff --git a/AxonIvyPortal/portal/src/ch/ivy/addon/portal/generic/bean/DashboardBean.java b/AxonIvyPortal/portal/src/ch/ivy/addon/portal/generic/bean/DashboardBean.java index b53300089f7..b573ec9dde1 100644 --- a/AxonIvyPortal/portal/src/ch/ivy/addon/portal/generic/bean/DashboardBean.java +++ b/AxonIvyPortal/portal/src/ch/ivy/addon/portal/generic/bean/DashboardBean.java @@ -7,6 +7,7 @@ import java.io.Serializable; import java.util.ArrayList; import java.util.List; +import java.util.Optional; import javax.annotation.PostConstruct; import javax.faces.bean.ManagedBean; @@ -513,7 +514,11 @@ public boolean isHideCaseCreator() { } public String getScreenReaderNotificationContent() { - if (this.selectedDashboard != null && ACCESSIBILITY_DASHBOARD_TEMPLATE_ID.equals(this.selectedDashboard.getTemplateId())) { + String templateId = Optional.ofNullable(this.selectedDashboard) + .map(Dashboard::getTemplateId).orElse(StringUtils.EMPTY); + + if (StringUtils.isNotBlank(templateId) + && ACCESSIBILITY_DASHBOARD_TEMPLATE_ID.equals(templateId)) { return Ivy.cms().co("/Dialogs/com/axonivy/portal/dashboard/component/AccessibilityShortcuts/title"); } return StringUtils.EMPTY; diff --git a/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/dto/dashboard/CaseDashboardWidget.java b/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/dto/dashboard/CaseDashboardWidget.java index b3f562bca65..82bfb5d720f 100644 --- a/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/dto/dashboard/CaseDashboardWidget.java +++ b/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/dto/dashboard/CaseDashboardWidget.java @@ -31,7 +31,6 @@ public class CaseDashboardWidget extends DashboardWidget { private static final long serialVersionUID = 3048837559125720787L; - private int rowsPerPage = 5; @JsonIgnore private DashboardCaseLazyDataModel dataModel; @JsonIgnore @@ -192,14 +191,6 @@ public DashboardWidgetType getType() { return DashboardWidgetType.CASE; } - public int getRowsPerPage() { - return rowsPerPage; - } - - public void setRowsPerPage(int rowsPerPage) { - this.rowsPerPage = rowsPerPage; - } - public List getFilters() { return this.dataModel.getCriteria().getFilters(); } @@ -240,7 +231,11 @@ public void loadUserFilter() { updateSavedFiltersSelection(); // Don't load user filters when already loaded from session - if (CollectionUtils.isNotEmpty(getUserFilters())) { + List userFilters = getUserFilters(); + if (CollectionUtils.isNotEmpty(userFilters)) { + // Clear temporary filters + setUserFilters(userFilters.stream().filter(filter -> !filter.isTemp()) + .collect(Collectors.toList())); return; } diff --git a/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/dto/dashboard/TaskDashboardWidget.java b/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/dto/dashboard/TaskDashboardWidget.java index f33a5746615..8fe651d2aca 100644 --- a/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/dto/dashboard/TaskDashboardWidget.java +++ b/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/dto/dashboard/TaskDashboardWidget.java @@ -32,7 +32,6 @@ public class TaskDashboardWidget extends DashboardWidget { private static final long serialVersionUID = 3246735956282078091L; protected static final String LIKE_FORMAT = "%%%s%%"; - private int rowsPerPage = 5; @JsonIgnore private DashboardTaskLazyDataModel dataModel; @JsonIgnore @@ -203,14 +202,6 @@ public DashboardWidgetType getType() { return DashboardWidgetType.TASK; } - public int getRowsPerPage() { - return isInConfiguration() ? 5 : rowsPerPage; - } - - public void setRowsPerPage(int rowsPerPage) { - this.rowsPerPage = rowsPerPage; - } - @Override public void setQuickSearchKeyword() { if (BooleanUtils.isTrue(this.enableQuickSearch)) { @@ -268,7 +259,11 @@ public void loadUserFilter() { updateSavedFiltersSelection(); // Don't load user filters when already loaded from session - if (CollectionUtils.isNotEmpty(getUserFilters())) { + List userFilters = getUserFilters(); + if (CollectionUtils.isNotEmpty(userFilters)) { + // Clear temporary filters + setUserFilters(userFilters.stream().filter(filter -> !filter.isTemp()) + .collect(Collectors.toList())); return; } diff --git a/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/dto/dashboard/taskcolumn/StartColumnModel.java b/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/dto/dashboard/taskcolumn/StartColumnModel.java index 0ef9a0724e3..91c901ccbc4 100644 --- a/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/dto/dashboard/taskcolumn/StartColumnModel.java +++ b/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/dto/dashboard/taskcolumn/StartColumnModel.java @@ -34,6 +34,6 @@ protected int getDefaultColumnWidth() { @Override public String getDefaultStyleClass() { - return "dashboard-tasks__start u-text-align-center widget-column"; + return "dashboard-tasks__start u-text-align-center widget-column ui-sm-hidden"; } } diff --git a/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/service/WidgetFilterService.java b/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/service/WidgetFilterService.java index c35fcfc1694..67773e66be9 100644 --- a/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/service/WidgetFilterService.java +++ b/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/service/WidgetFilterService.java @@ -174,6 +174,7 @@ public void updateFilterOptionsData(DashboardWidget widget, WidgetFilterModel us private void mergeUserFilterInput(WidgetFilterModel userFilterOptions, ColumnModel column) { userFilterOptions.getFilterableColumns().stream() + .filter(userSelected -> userSelected.getField() != null) .filter(userSelected -> userSelected.getField().equals(column.getField()) && userSelected.getType( )== column.getType()).findFirst() .ifPresent(selectedColumn -> { diff --git a/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/util/DashboardWidgetUtils.java b/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/util/DashboardWidgetUtils.java index 3b89cde52aa..cae74c02430 100644 --- a/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/util/DashboardWidgetUtils.java +++ b/AxonIvyPortal/portal/src/ch/ivy/addon/portalkit/util/DashboardWidgetUtils.java @@ -439,6 +439,9 @@ public static List initProcessFilterableColumns() { case CATEGORY -> { columnModel = new ch.ivy.addon.portalkit.dto.dashboard.process.CategoryColumnModel(); } + case DESCRIPTION -> { + columnModel = new ch.ivy.addon.portalkit.dto.dashboard.process.DescriptionColumnModel(); + } default -> { } } diff --git a/AxonIvyPortal/portal/src/com/axonivy/portal/bean/dashboard/filter/TaskWidgetUserFilterBean.java b/AxonIvyPortal/portal/src/com/axonivy/portal/bean/dashboard/filter/TaskWidgetUserFilterBean.java index d34287c2616..899a8379bc0 100644 --- a/AxonIvyPortal/portal/src/com/axonivy/portal/bean/dashboard/filter/TaskWidgetUserFilterBean.java +++ b/AxonIvyPortal/portal/src/com/axonivy/portal/bean/dashboard/filter/TaskWidgetUserFilterBean.java @@ -28,11 +28,11 @@ public class TaskWidgetUserFilterBean extends AbstractTaskWidgetFilterBean imple @Override public void preRender(TaskDashboardWidget widget) { super.preRender(widget); - initUSerFilters(); + initUserFilters(); originalUserFilters = widget.getUserFilters(); } - private void initUSerFilters() { + private void initUserFilters() { if (CollectionUtils.isEmpty(Optional.ofNullable(this.widget).map(TaskDashboardWidget::getUserFilters).get())) { return; } diff --git a/AxonIvyPortal/portal/src_hd/ch/ivy/addon/portal/generic/dashboard/component/DashboardDetails/DashboardDetails.xhtml b/AxonIvyPortal/portal/src_hd/ch/ivy/addon/portal/generic/dashboard/component/DashboardDetails/DashboardDetails.xhtml index 8be8ac14903..0311c8d959d 100644 --- a/AxonIvyPortal/portal/src_hd/ch/ivy/addon/portal/generic/dashboard/component/DashboardDetails/DashboardDetails.xhtml +++ b/AxonIvyPortal/portal/src_hd/ch/ivy/addon/portal/generic/dashboard/component/DashboardDetails/DashboardDetails.xhtml @@ -61,9 +61,9 @@ cache="true" maxResults="100" multiple="true" moreText="#{ivy.cms.co('/ch.ivy.addon.portalkit.ui.jsf/common/more')}..." dynamic="true" forceSelection="true"> + update="dashboard-permission" global="false" process="@this" immediate="true"/> + global="false" process="@this" immediate="true"/> diff --git a/AxonIvyPortal/portal/src_hd/ch/ivy/addon/portalkit/component/ProcessWidget/ProcessWidgetDialogs.xhtml b/AxonIvyPortal/portal/src_hd/ch/ivy/addon/portalkit/component/ProcessWidget/ProcessWidgetDialogs.xhtml index 9845f46b0e1..2827e269108 100644 --- a/AxonIvyPortal/portal/src_hd/ch/ivy/addon/portalkit/component/ProcessWidget/ProcessWidgetDialogs.xhtml +++ b/AxonIvyPortal/portal/src_hd/ch/ivy/addon/portalkit/component/ProcessWidget/ProcessWidgetDialogs.xhtml @@ -232,6 +232,7 @@ header="#{ivy.cms.co('/ch.ivy.addon.portalkit.ui.jsf/processwidget/addNewExternalLinkHeader')}" closeOnEscape="true" modal="true" appendTo="@(body)" resizable="false" responsive="true" positionType="absolute" fitViewport="true" styleClass="add-external-link-dialog"> +