using System.Linq.Expressions;
using Monitoring.Core.Domain.EventManagement;

namespace Monitoring.Features.AlarmManagement;

public record AlarmScopeStatusChangingModel(
	Guid Id,
	Guid AlarmScopeId,
	Guid? UserId,
	DateTime ChangedAt,
	AlarmScopeStatus Status
)
{
	public static readonly Expression<
		Func<AlarmScopeStatusChanging, AlarmScopeStatusChangingModel>
	> Projection = x => new AlarmScopeStatusChangingModel(
		x.Id.Value,
		x.AlarmScopeId.Value,
		x.UserId!.Value,
		x.CreatedAt,
		x.Status
	);
}
