-
Notifications
You must be signed in to change notification settings - Fork 75
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Add MediatR package * event and event handlers structure added * fix endpoint and add tests * delete taskName change endpoint
- Loading branch information
1 parent
3498c6c
commit b5fb51e
Showing
17 changed files
with
251 additions
and
199 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 16 additions & 0 deletions
16
...gner/EventHandlers/ProcessTaskIdChanged/ProcessTaskIdChangedApplicationMetadataHandler.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
using System.Threading; | ||
using System.Threading.Tasks; | ||
using Altinn.Studio.Designer.Events; | ||
using MediatR; | ||
|
||
namespace Altinn.Studio.Designer.EventHandlers.ProcessTaskIdChanged; | ||
|
||
public class ProcessTaskIdChangedApplicationMetadataHandler : INotificationHandler<ProcessTaskIdChangedEvent> | ||
{ | ||
public Task Handle(ProcessTaskIdChangedEvent notification, CancellationToken cancellationToken) | ||
{ | ||
// TODO: Implement logic to handle the event here: https://github.com/Altinn/altinn-studio/issues/12220 | ||
// Here we should think how to handle errors in the handlers. Should we throw exceptions or use websocket to send error messages to the client? | ||
return Task.CompletedTask; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
using MediatR; | ||
|
||
namespace Altinn.Studio.Designer.Events; | ||
|
||
public class ProcessTaskIdChangedEvent : INotification | ||
{ | ||
public string OldId { get; set; } | ||
public string NewId { get; set; } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
using System.Collections.Generic; | ||
|
||
namespace Altinn.Studio.Designer.Models.Dto; | ||
|
||
public class ProcessDefinitionMetadata | ||
{ | ||
public List<TaskIdChange> TaskIdChanges { get; set; } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
namespace Altinn.Studio.Designer.Models.Dto; | ||
|
||
public class TaskIdChange | ||
{ | ||
public string OldId { get; set; } | ||
public string NewId { get; set; } | ||
} |
2 changes: 1 addition & 1 deletion
2
...er/ViewModels/Response/VersionResponse.cs → ...rc/Designer/Models/Dto/VersionResponse.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
54 changes: 0 additions & 54 deletions
54
.../tests/Designer.Tests/Controllers/ProcessModelingController/UpdateProcessTaskNameTests.cs
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.