yavsc/Yavsc/Models/Workflow/Activity.cs

87 lines
2.1 KiB
C#

8 years ago
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
8 years ago
using Newtonsoft.Json;
8 years ago
namespace Yavsc.Models.Workflow
{
8 years ago
using Market;
using YavscLib;
public class Activity : IBaseTrackedEntity, IActivity
{
8 years ago
[StringLength(512), Required, Key]
public string Code { get; set; }
/// <summary>
///
/// </summary>
/// <returns></returns>
8 years ago
[StringLength(512), Required()]
public string Name { get; set; }
[StringLength(512)]
public string ParentCode { get; set; }
8 years ago
[ForeignKey("ParentCode"), JsonIgnore]
public virtual Activity Parent { get; set; }
8 years ago
[InverseProperty("Parent"), JsonIgnore]
public virtual List<Activity> Children { get; set; }
8 years ago
public string Description { get; set; }
/// <summary>
/// Name to associate to a performer in this activity domain
/// </summary>
8 years ago
[Obsolete]
public string ActorDenomination { get; set; }
8 years ago
public string Photo { get; set; }
8 years ago
[InverseProperty("Context")]
public List<Service> Services { get; set; }
8 years ago
/// <summary>
/// Moderation settings
/// </summary>
/// <returns></returns>
8 years ago
public string ModeratorGroupName { get; set; }
/// <summary>
/// indice de recherche de cette activité
/// rendu par le système.
/// Valide entre 0 et 100,
/// Il démarre à 0.
/// </summary>
8 years ago
[Range(0, 100)]
public int Rate { get; set; }
[DisplayAttribute(Name = "SettingsClass")]
public string SettingsClassName { get; set; }
[InverseProperty("Context")]
public virtual List<CommandForm> Forms { get; set; }
8 years ago
public DateTime DateCreated
{
8 years ago
get; set;
8 years ago
}
public string UserCreated
{
8 years ago
get; set;
8 years ago
}
public DateTime DateModified
{
8 years ago
get; set;
8 years ago
}
public string UserModified
{
8 years ago
get; set;
8 years ago
}
}
}