first commit
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
namespace Fitness_core_BE.DTOs.Place
|
||||
{
|
||||
public class PlaceDto
|
||||
{
|
||||
public Guid PlaceId { get; set; }
|
||||
public string Name { get; set; } = string.Empty;
|
||||
public string? Description { get; set; }
|
||||
public bool IsActive { get; set; }
|
||||
public DateTime CreatedAt { get; set; }
|
||||
|
||||
// At most one for now -- see AccessDevice.FKPlaceId.
|
||||
public Guid? DeviceId { get; set; }
|
||||
public string? DeviceName { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace Fitness_core_BE.DTOs.Place
|
||||
{
|
||||
public class CreatePlaceRequest
|
||||
{
|
||||
[Required]
|
||||
public string Name { get; set; } = string.Empty;
|
||||
public string? Description { get; set; }
|
||||
}
|
||||
|
||||
public class UpdatePlaceRequest
|
||||
{
|
||||
[Required]
|
||||
public Guid PlaceId { get; set; }
|
||||
public string? Name { get; set; }
|
||||
public string? Description { get; set; }
|
||||
public bool? IsActive { get; set; }
|
||||
}
|
||||
|
||||
public class SetPlaceStatusRequest
|
||||
{
|
||||
[Required]
|
||||
public bool IsActive { get; set; }
|
||||
}
|
||||
|
||||
public class AssignPlaceDeviceRequest
|
||||
{
|
||||
// Null unassigns the place's current device.
|
||||
public Guid? DeviceId { get; set; }
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user