feat(store): 扩展临时时段配置
This commit is contained in:
@@ -1,10 +1,11 @@
|
||||
using MediatR;
|
||||
using TakeoutSaaS.Application.App.Stores.Dto;
|
||||
using TakeoutSaaS.Domain.Stores.Enums;
|
||||
|
||||
namespace TakeoutSaaS.Application.App.Stores.Commands;
|
||||
|
||||
/// <summary>
|
||||
/// 创建节假日配置命令。
|
||||
/// 创建临时时段配置命令。
|
||||
/// </summary>
|
||||
public sealed record CreateStoreHolidayCommand : IRequest<StoreHolidayDto>
|
||||
{
|
||||
@@ -14,14 +15,34 @@ public sealed record CreateStoreHolidayCommand : IRequest<StoreHolidayDto>
|
||||
public long StoreId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 日期。
|
||||
/// 开始日期。
|
||||
/// </summary>
|
||||
public DateTime Date { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 是否闭店。
|
||||
/// 结束日期(可选)。
|
||||
/// </summary>
|
||||
public bool IsClosed { get; init; } = true;
|
||||
public DateTime? EndDate { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 是否全天。
|
||||
/// </summary>
|
||||
public bool IsAllDay { get; init; } = true;
|
||||
|
||||
/// <summary>
|
||||
/// 开始时间(IsAllDay=false 时必填)。
|
||||
/// </summary>
|
||||
public TimeSpan? StartTime { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 结束时间(IsAllDay=false 时必填)。
|
||||
/// </summary>
|
||||
public TimeSpan? EndTime { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 覆盖类型。
|
||||
/// </summary>
|
||||
public OverrideType OverrideType { get; init; } = OverrideType.Closed;
|
||||
|
||||
/// <summary>
|
||||
/// 说明。
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
using MediatR;
|
||||
using TakeoutSaaS.Application.App.Stores.Dto;
|
||||
using TakeoutSaaS.Domain.Stores.Enums;
|
||||
|
||||
namespace TakeoutSaaS.Application.App.Stores.Commands;
|
||||
|
||||
/// <summary>
|
||||
/// 更新节假日配置命令。
|
||||
/// 更新临时时段配置命令。
|
||||
/// </summary>
|
||||
public sealed record UpdateStoreHolidayCommand : IRequest<StoreHolidayDto?>
|
||||
{
|
||||
@@ -19,14 +20,34 @@ public sealed record UpdateStoreHolidayCommand : IRequest<StoreHolidayDto?>
|
||||
public long StoreId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 日期。
|
||||
/// 开始日期。
|
||||
/// </summary>
|
||||
public DateTime Date { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 是否闭店。
|
||||
/// 结束日期(可选)。
|
||||
/// </summary>
|
||||
public bool IsClosed { get; init; } = true;
|
||||
public DateTime? EndDate { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 是否全天。
|
||||
/// </summary>
|
||||
public bool IsAllDay { get; init; } = true;
|
||||
|
||||
/// <summary>
|
||||
/// 开始时间(IsAllDay=false 时必填)。
|
||||
/// </summary>
|
||||
public TimeSpan? StartTime { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 结束时间(IsAllDay=false 时必填)。
|
||||
/// </summary>
|
||||
public TimeSpan? EndTime { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 覆盖类型。
|
||||
/// </summary>
|
||||
public OverrideType OverrideType { get; init; } = OverrideType.Closed;
|
||||
|
||||
/// <summary>
|
||||
/// 说明。
|
||||
|
||||
Reference in New Issue
Block a user