diff --git a/lib/process-services-cloud/src/lib/process/process-filters/models/process-filter-cloud.model.ts b/lib/process-services-cloud/src/lib/process/process-filters/models/process-filter-cloud.model.ts index cc6762e5ef..93d4e5750a 100644 --- a/lib/process-services-cloud/src/lib/process/process-filters/models/process-filter-cloud.model.ts +++ b/lib/process-services-cloud/src/lib/process/process-filters/models/process-filter-cloud.model.ts @@ -58,7 +58,7 @@ export class ProcessFilterCloudModel { appVersions: string[] | null; statuses: string[] | null; - processVariableFilters?: ProcessVariableFilterModel[] + processVariableFilters?: ProcessVariableFilterModel[]; private dateRangeFilterService = new DateRangeFilterService(); private _completedFrom: string; @@ -108,13 +108,13 @@ export class ProcessFilterCloudModel { this._suspendedFrom = obj._suspendedFrom || null; this._suspendedTo = obj._suspendedTo || null; - this.processDefinitionNames = obj.processDefinitionNames || null; - this.processNames = obj.processNames || null; - this.processInstanceIds = obj.processInstanceIds || null; - this.parentIds = obj.parentIds || null; - this.initiators = obj.initiators || null; - this.appVersions = obj.appVersions || null; - this.statuses = obj.statuses || null; + this.processDefinitionNames = obj.processDefinitionNames || obj.processDefinitionName ? [obj.processDefinitionName] : null; + this.processNames = obj.processNames || obj.processName ? [obj.processName] : null; + this.processInstanceIds = obj.processInstanceIds || obj.processInstanceId ? [obj.processInstanceId] : null; + this.parentIds = obj.parentIds || obj.parentId ? [obj.parentId] : null; + this.initiators = obj.initiators || obj.initiator ? [obj.initiator] : null; + this.appVersions = obj.appVersions || obj.appVersion ? [`${obj.appVersion}`] : null; + this.statuses = obj.statuses || obj.status ? [obj.status] : null; this.processVariableFilters = obj.processVariableFilters ?? []; } } diff --git a/lib/process-services-cloud/src/lib/task/task-filters/models/filter-cloud.model.ts b/lib/process-services-cloud/src/lib/task/task-filters/models/filter-cloud.model.ts index c32d4abf0f..cba7ba82f9 100644 --- a/lib/process-services-cloud/src/lib/task/task-filters/models/filter-cloud.model.ts +++ b/lib/process-services-cloud/src/lib/task/task-filters/models/filter-cloud.model.ts @@ -122,16 +122,17 @@ export class TaskFilterCloudModel { this.createdTo = obj._createdTo || null; this.candidateGroups = obj.candidateGroups || null; this.showCounter = obj.showCounter || false; - this.taskNames = obj.taskNames || null; - this.statuses = obj.statuses || null; - this.assignees = obj.assignees || null; - this.processNames = obj.processNames || null; - this.processDefinitionNames = obj.processDefinitionNames || null; - this.taskIds = obj.taskIds || null; - this.parentTaskIds = obj.parentTaskIds || null; - this.processInstanceIds = obj.processInstanceIds || null; - this.priorities = obj.priorities || null; - this.completedByUsers = obj.completedByUsers || null; + + this.taskNames = obj.taskNames || obj.taskName ? [obj.taskName] : null; + this.statuses = obj.statuses || obj.status ? [obj.status] : null; + this.assignees = obj.assignees || obj.assignee ? [obj.assignee] : null; + this.processNames = obj.processNames || obj.processName ? [obj.processName] : null; + this.processDefinitionNames = obj.processDefinitionNames || obj.processDefinitionName ? [obj.processDefinitionName] : null; + this.taskIds = obj.taskIds || obj.taskId ? [obj.taskId] : null; + this.parentTaskIds = obj.parentTaskIds || obj.parentTaskId ? [obj.parentTaskId] : null; + this.processInstanceIds = obj.processInstanceIds || obj.processInstanceId ? [obj.processInstanceId] : null; + this.priorities = obj.priorities || obj.priority ? [obj.priority] : null; + this.completedByUsers = obj.completedByUsers || obj.completedBy ? [obj.completedBy] : null; this.processVariableFilters = obj.processVariableFilters ?? []; } }