interface
This commit is contained in:
@ -4,48 +4,50 @@ using System.Collections.Generic;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
using Newtonsoft.Json;
|
||||
using Yavsc.Models.Market;
|
||||
|
||||
namespace Yavsc.Models.Workflow
|
||||
{
|
||||
public class Activity : IBaseTrackedEntity
|
||||
using Market;
|
||||
using YavscLib;
|
||||
|
||||
public class Activity : IBaseTrackedEntity, IActivity
|
||||
{
|
||||
|
||||
[StringLength(512),Required,Key]
|
||||
public string Code {get; set;}
|
||||
[StringLength(512), Required, Key]
|
||||
public string Code { get; set; }
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
[StringLength(512),Required()]
|
||||
public string Name {get; set;}
|
||||
[StringLength(512), Required()]
|
||||
public string Name { get; set; }
|
||||
|
||||
[StringLength(512)]
|
||||
public string ParentCode { get; set; }
|
||||
|
||||
[ForeignKey("ParentCode"),JsonIgnore]
|
||||
[ForeignKey("ParentCode"), JsonIgnore]
|
||||
public virtual Activity Parent { get; set; }
|
||||
|
||||
[InverseProperty("Parent"),JsonIgnore]
|
||||
[InverseProperty("Parent"), JsonIgnore]
|
||||
public virtual List<Activity> Children { get; set; }
|
||||
|
||||
public string Description {get; set;}
|
||||
public string Description { get; set; }
|
||||
/// <summary>
|
||||
/// Name to associate to a performer in this activity domain
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public string ActorDenomination {get; set;}
|
||||
[Obsolete]
|
||||
public string ActorDenomination { get; set; }
|
||||
|
||||
public string Photo {get; set;}
|
||||
public string Photo { get; set; }
|
||||
|
||||
[InverseProperty("Context")]
|
||||
[InverseProperty("Context")]
|
||||
public List<Service> Services { get; set; }
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Moderation settings
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
string ModeratorGroupName { get; set; }
|
||||
public string ModeratorGroupName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// indice de recherche de cette activité
|
||||
@ -53,32 +55,32 @@ namespace Yavsc.Models.Workflow
|
||||
/// Valide entre 0 et 100,
|
||||
/// Il démarre à 0.
|
||||
/// </summary>
|
||||
[Range(0,100)]
|
||||
public int Rate { get; set; }
|
||||
[DisplayAttribute(Name="SettingsClass")]
|
||||
public string SettingsClassName { get; set; }
|
||||
[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; }
|
||||
|
||||
public DateTime DateCreated
|
||||
{
|
||||
get; set;
|
||||
get; set;
|
||||
}
|
||||
|
||||
public string UserCreated
|
||||
{
|
||||
get; set;
|
||||
get; set;
|
||||
}
|
||||
|
||||
public DateTime DateModified
|
||||
{
|
||||
get; set;
|
||||
get; set;
|
||||
}
|
||||
|
||||
public string UserModified
|
||||
{
|
||||
get; set;
|
||||
get; set;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -3,7 +3,9 @@ using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
namespace Yavsc.Models.Workflow
|
||||
{
|
||||
public class CoWorking
|
||||
using YavscLib;
|
||||
|
||||
public class CoWorking: ICoWorking
|
||||
{
|
||||
[Key(), DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||
public long Id {get; set; }
|
||||
|
@ -4,7 +4,8 @@ using Newtonsoft.Json;
|
||||
|
||||
namespace Yavsc.Models.Workflow
|
||||
{
|
||||
public class CommandForm
|
||||
using YavscLib;
|
||||
public class CommandForm : ICommandForm
|
||||
{
|
||||
[Key,DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||
public long Id { get; set; }
|
||||
|
35
YavscLib/IActivity.cs
Normal file
35
YavscLib/IActivity.cs
Normal file
@ -0,0 +1,35 @@
|
||||
using System;
|
||||
|
||||
namespace YavscLib
|
||||
{
|
||||
public interface IActivity
|
||||
{
|
||||
string Code { get; set; }
|
||||
string Name { get; set; }
|
||||
string ParentCode { get; set; }
|
||||
string Photo { get; set; }
|
||||
|
||||
string ModeratorGroupName { get; set; }
|
||||
int Rate { get; set; }
|
||||
string SettingsClassName { get; set; }
|
||||
DateTime DateCreated
|
||||
{
|
||||
get; set;
|
||||
}
|
||||
|
||||
string UserCreated
|
||||
{
|
||||
get; set;
|
||||
}
|
||||
|
||||
DateTime DateModified
|
||||
{
|
||||
get; set;
|
||||
}
|
||||
|
||||
string UserModified
|
||||
{
|
||||
get; set;
|
||||
}
|
||||
}
|
||||
}
|
10
YavscLib/ICoWorking.cs
Normal file
10
YavscLib/ICoWorking.cs
Normal file
@ -0,0 +1,10 @@
|
||||
namespace YavscLib
|
||||
{
|
||||
public interface ICoWorking
|
||||
{
|
||||
long Id {get; set; }
|
||||
string PerformerId { get; set; }
|
||||
string WorkingForId { get; set; }
|
||||
|
||||
}
|
||||
}
|
11
YavscLib/ICommandForm.cs
Normal file
11
YavscLib/ICommandForm.cs
Normal file
@ -0,0 +1,11 @@
|
||||
namespace YavscLib
|
||||
{
|
||||
public interface ICommandForm
|
||||
{
|
||||
long Id { get; set; }
|
||||
string Action { get; set; }
|
||||
string Title { get; set; }
|
||||
string ActivityCode { get; set; }
|
||||
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user