This commit is contained in:
espent1004 2019-11-20 11:18:50 +01:00
parent 89c5addfe8
commit 02c644f79a
6 changed files with 34 additions and 6 deletions

View File

@ -6,6 +6,7 @@ using System.IO;
using System.Net.Http;
using Microsoft.eShopOnContainers.BuildingBlocks.EventBus.Abstractions;
using Microsoft.Extensions.Logging;
using Ordering.API.Application.IntegrationEvents.Events;
namespace Ordering.API.Application.IntegrationEvents.EventHandling
{

View File

@ -0,0 +1,23 @@
using Microsoft.eShopOnContainers.BuildingBlocks.EventBus.Events;
using Ordering.API.Application.IntegrationEvents.Events;
using System;
using System.Collections.Generic;
using System.Text;
namespace Ordering.API.Application.IntegrationEvents.Events
{
public class CustomisationEvent : IntegrationEvent
{
public CustomisationEvent(int tenantId, IntegrationEvent @event)
{
TenantId = tenantId;
eventType = @event.GetType().Name;
//TODO
userCheckoutAcceptedIntegrationEvent = (UserCheckoutAcceptedIntegrationEvent)@event;
}
public int TenantId { get; set; }
public String eventType { get; set; }
public UserCheckoutAcceptedIntegrationEvent userCheckoutAcceptedIntegrationEvent { get; set; }
}
}

View File

@ -7,7 +7,9 @@ using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using TenantACustomisations.IntegrationEvents.Events;
using TenantACustomisations.Services;
using CustomisationEvent = TenantACustomisations.IntegrationEvents.Events.CustomisationEvent;
namespace TenantACustomisations.IntegrationEvents.EventHandling
{

View File

@ -1,8 +1,10 @@
using System;
using Microsoft.eShopOnContainers.BuildingBlocks.EventBus.Events;
using Ordering.API.Application.IntegrationEvents.Events;
using System;
using System.Collections.Generic;
using System.Text;
namespace Microsoft.eShopOnContainers.BuildingBlocks.EventBus.Events
namespace TenantACustomisations.IntegrationEvents.Events
{
public class CustomisationEvent : IntegrationEvent
{
@ -11,10 +13,13 @@ namespace Microsoft.eShopOnContainers.BuildingBlocks.EventBus.Events
TenantId = tenantId;
this.@event = @event;
eventType = @event.GetType().Name;
//TODO
userCheckoutAcceptedIntegrationEvent = (UserCheckoutAcceptedIntegrationEvent)@event;
}
public int TenantId { get; set; }
public IntegrationEvent @event { get; set; }
public String eventType { get; set; }
public UserCheckoutAcceptedIntegrationEvent userCheckoutAcceptedIntegrationEvent { get; set; }
}
}

View File

@ -35,6 +35,7 @@
using global::TenantACustomisations.Infrastructure.Filters;
using Microsoft.eShopOnContainers.BuildingBlocks.EventBus.Events;
using global::TenantACustomisations.IntegrationEvents.EventHandling;
using global::TenantACustomisations.IntegrationEvents.Events;
public class Startup
{

View File

@ -42,10 +42,6 @@
<PackageReference Include="System.ValueTuple" Version="4.5.0" />
</ItemGroup>
<ItemGroup>
<Folder Include="IntegrationEvents\Events\" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\..\BuildingBlocks\EventBus\EventBusRabbitMQ\EventBusRabbitMQ.csproj" />
<ProjectReference Include="..\..\..\BuildingBlocks\EventBus\EventBusServiceBus\EventBusServiceBus.csproj" />