Skip to content

Commit

Permalink
Add timestamp filtering to workflow instance list
Browse files Browse the repository at this point in the history
A new TimestampFilterModel class was added and integrated into the WorkflowInstanceList component for enhanced data filtering based on timestamps. The UI was also adjusted to accommodate these changes, allowing users to select and apply timestamp filters. Modifications were also made to maintain privacy by changing a few collection properties from public to private.
  • Loading branch information
sfmskywalker committed Feb 17, 2024
1 parent 9348321 commit 59c68e4
Show file tree
Hide file tree
Showing 5 changed files with 327 additions and 229 deletions.
16 changes: 4 additions & 12 deletions src/framework/Elsa.Studio.Shell/wwwroot/css/shell.css
Original file line number Diff line number Diff line change
Expand Up @@ -16,20 +16,12 @@
/*****************************************************
* CSS hacks for the MudBlazorExtensions components
******************************************************/
.mud-select-extended {
min-width: 100px;
}

.mud-select-extended .mud-input-slot {
min-height: 2.1em !important;
.mud-select.timespan-operator {
min-width: 150px;
}

/*****************************************************
* Environment Picker
******************************************************/
.elsa-environment-picker .mud-input > input.mud-input-root-outlined, div.mud-input-slot.mud-input-root-outlined {
padding-top: 11px;
padding-bottom: 11px;
.mud-select-extended {
min-width: 100px;
}

/*****************************************************
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
using Elsa.Api.Client.Shared.Enums;
using JetBrains.Annotations;

namespace Elsa.Studio.Workflows.Components.WorkflowInstanceList.Models;

/// <summary>
/// Represents a timestamp filter used for filtering data based on a specified timestamp column and operator.
/// </summary>
public class TimestampFilterModel
{
/// <summary>
/// Gets or sets the column to filter by.
/// </summary>
public string Column { get; set; } = default!;

/// <summary>
/// Gets or sets the operator to use for filtering.
/// </summary>
public TimestampFilterOperator Operator { get; set; }

/// <summary>
/// Gets or sets the date to filter by.
/// </summary>
public string Date { get; set; }

/// <summary>
/// Gets or sets the time to filter by.
/// </summary>
public string Time { get; set; }
}
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,5 @@ internal record WorkflowInstanceRow(
int IncidentCount,
DateTimeOffset CreatedAt,
DateTimeOffset? UpdatedAt,
DateTimeOffset? FinishedAt);
DateTimeOffset? FinishedAt
);
Loading

0 comments on commit 59c68e4

Please sign in to comment.