bild update

This commit is contained in:
Tizian.Breuch
2025-08-08 16:00:42 +02:00
parent c2af53c5ce
commit 37dd4f2db1
4 changed files with 65 additions and 34 deletions

View File

@@ -1,4 +1,5 @@
// src/Webshop.Application/DTOs/Products/CreateAdminProductDto.cs
using Microsoft.AspNetCore.Http; // FÜR IFormFile
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
@@ -15,14 +16,13 @@ namespace Webshop.Application.DTOs.Products
[Required]
public decimal Price { get; set; }
public bool IsActive { get; set; } = true;
public bool IsInStock { get; set; } = true;
public int StockQuantity { get; set; }
[Required]
public string Slug { get; set; }
// << KORREKTUR: Felder für Bild-URLs, keine IFormFile >>
public string? MainImageUrl { get; set; }
public List<string>? AdditionalImageUrls { get; set; }
// << ZURÜCK ZU IFormFile >>
public IFormFile? MainImageFile { get; set; }
public List<IFormFile>? AdditionalImageFiles { get; set; }
public List<Guid> CategorieIds { get; set; } = new List<Guid>();

View File

@@ -1,4 +1,5 @@
// src/Webshop.Application/DTOs/Products/UpdateAdminProductDto.cs
using Microsoft.AspNetCore.Http;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
@@ -17,14 +18,14 @@ namespace Webshop.Application.DTOs.Products
[Required]
public decimal Price { get; set; }
public bool IsActive { get; set; }
public bool IsInStock { get; set; }
public int StockQuantity { get; set; }
[Required]
public string Slug { get; set; }
// << KORREKTUR: Felder für Bild-URLs >>
public string? MainImageUrl { get; set; }
public List<string>? AdditionalImageUrls { get; set; }
// << ZURÜCK ZU IFormFile >>
public IFormFile? MainImageFile { get; set; }
public List<IFormFile>? AdditionalImageFiles { get; set; }
public List<Guid>? ImagesToDelete { get; set; }
public List<Guid> CategorieIds { get; set; } = new List<Guid>();