2018-03-21 14:40:59 +01:00
|
|
|
|
using System;
|
|
|
|
|
|
using System.Runtime.Serialization;
|
2021-02-18 11:06:02 +01:00
|
|
|
|
using Umbraco.Cms.Core.Models.Entities;
|
2018-03-21 14:40:59 +01:00
|
|
|
|
|
2021-02-18 11:06:02 +01:00
|
|
|
|
namespace Umbraco.Cms.Core.Models
|
2018-03-21 14:40:59 +01:00
|
|
|
|
{
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// Represents an audited event.
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
[Serializable]
|
|
|
|
|
|
[DataContract(IsReference = true)]
|
2019-05-27 11:20:33 +02:00
|
|
|
|
public class AuditEntry : EntityBase, IAuditEntry
|
2018-03-21 14:40:59 +01:00
|
|
|
|
{
|
|
|
|
|
|
private int _performingUserId;
|
|
|
|
|
|
private string _performingDetails;
|
|
|
|
|
|
private string _performingIp;
|
|
|
|
|
|
private int _affectedUserId;
|
|
|
|
|
|
private string _affectedDetails;
|
|
|
|
|
|
private string _eventType;
|
|
|
|
|
|
private string _eventDetails;
|
2019-02-04 10:09:32 +01:00
|
|
|
|
|
2018-03-21 14:40:59 +01:00
|
|
|
|
/// <inheritdoc />
|
|
|
|
|
|
public int PerformingUserId
|
|
|
|
|
|
{
|
|
|
|
|
|
get => _performingUserId;
|
2019-02-04 19:52:04 +11:00
|
|
|
|
set => SetPropertyValueAndDetectChanges(value, ref _performingUserId, nameof(PerformingUserId));
|
2018-03-21 14:40:59 +01:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// <inheritdoc />
|
|
|
|
|
|
public string PerformingDetails
|
|
|
|
|
|
{
|
|
|
|
|
|
get => _performingDetails;
|
2019-02-04 19:52:04 +11:00
|
|
|
|
set => SetPropertyValueAndDetectChanges(value, ref _performingDetails, nameof(PerformingDetails));
|
2018-03-21 14:40:59 +01:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// <inheritdoc />
|
|
|
|
|
|
public string PerformingIp
|
|
|
|
|
|
{
|
|
|
|
|
|
get => _performingIp;
|
2019-02-04 19:52:04 +11:00
|
|
|
|
set => SetPropertyValueAndDetectChanges(value, ref _performingIp, nameof(PerformingIp));
|
2018-03-21 14:40:59 +01:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// <inheritdoc />
|
|
|
|
|
|
public DateTime EventDateUtc
|
|
|
|
|
|
{
|
|
|
|
|
|
get => CreateDate;
|
|
|
|
|
|
set => CreateDate = value;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// <inheritdoc />
|
2019-02-04 10:09:32 +01:00
|
|
|
|
public int AffectedUserId
|
2018-03-21 14:40:59 +01:00
|
|
|
|
{
|
|
|
|
|
|
get => _affectedUserId;
|
2019-02-04 19:52:04 +11:00
|
|
|
|
set => SetPropertyValueAndDetectChanges(value, ref _affectedUserId, nameof(AffectedUserId));
|
2018-03-21 14:40:59 +01:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// <inheritdoc />
|
2019-02-04 10:09:32 +01:00
|
|
|
|
public string AffectedDetails
|
2018-03-21 14:40:59 +01:00
|
|
|
|
{
|
|
|
|
|
|
get => _affectedDetails;
|
2019-02-04 19:52:04 +11:00
|
|
|
|
set => SetPropertyValueAndDetectChanges(value, ref _affectedDetails, nameof(AffectedDetails));
|
2018-03-21 14:40:59 +01:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// <inheritdoc />
|
2019-02-04 10:09:32 +01:00
|
|
|
|
public string EventType
|
2018-03-21 14:40:59 +01:00
|
|
|
|
{
|
|
|
|
|
|
get => _eventType;
|
2019-02-04 19:52:04 +11:00
|
|
|
|
set => SetPropertyValueAndDetectChanges(value, ref _eventType, nameof(EventType));
|
2018-03-21 14:40:59 +01:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// <inheritdoc />
|
2019-02-04 10:09:32 +01:00
|
|
|
|
public string EventDetails
|
2018-03-21 14:40:59 +01:00
|
|
|
|
{
|
|
|
|
|
|
get => _eventDetails;
|
2019-02-04 19:52:04 +11:00
|
|
|
|
set => SetPropertyValueAndDetectChanges(value, ref _eventDetails, nameof(EventDetails));
|
2018-03-21 14:40:59 +01:00
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|