This commit is contained in:
Tizian.Breuch
2025-11-26 17:02:18 +01:00
parent 2e30755901
commit ee5abfd829
18 changed files with 1968 additions and 208 deletions

View File

@@ -0,0 +1,9 @@
using System.Threading.Tasks;
namespace Webshop.Application.Services.Customers.Interfaces
{
public interface ICartService
{
Task ClearCartAsync(string userId);
}
}

View File

@@ -1,13 +1,20 @@
// src/Webshop.Application/Services/Customers/Interfaces/ICheckoutService.cs
using System;
using System.Collections.Generic;
using System.Threading.Tasks;
using Webshop.Application;
using Webshop.Application.DTOs.Orders;
using Webshop.Application.DTOs.Shipping;
using Webshop.Application; // F<>r ServiceResult
namespace Webshop.Application.Services.Customers.Interfaces
{
public interface ICheckoutService
{
// Methode 1: F<>r den Checkout (interne Verarbeitung)
Task<ServiceResult<IEnumerable<ShippingMethodDto>>> GetCompatibleShippingMethodsAsync(IEnumerable<CreateOrderItemDto> items);
// +++ METHODE 2: DIESE FEHLTE +++
// F<>r den Warenkorb-Check (kommt vom Controller als List<CartItemDto>)
Task<ServiceResult<IEnumerable<ShippingMethodDto>>> GetCompatibleShippingMethodsAsync(List<CartItemDto> items);
Task<ServiceResult<OrderDetailDto>> CreateOrderAsync(CreateOrderDto orderDto, string? userId);
}
}

View File

@@ -1,11 +1,9 @@
// src/Webshop.Application/Services/Customers/ICustomerService.cs
using System.Threading.Tasks;
using Webshop.Application;
using Webshop.Application.DTOs;
using System.Threading.Tasks;
using Webshop.Application; // Für ServiceResult
using Webshop.Application.DTOs.Auth;
using Webshop.Application.DTOs.Customers;
namespace Webshop.Application.Services.Customers
namespace Webshop.Application.Services.Customers.Interfaces // Namespace angepasst auf .Interfaces
{
public interface ICustomerService
{