yavsc/Yavsc/Models/Market/Service.cs

40 lines
1.2 KiB
C#
Raw Normal View History

2017-01-31 13:19:12 +01:00
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
2016-07-27 10:55:44 +02:00
namespace Yavsc.Models.Market {
2017-02-27 19:28:32 +01:00
using System.ComponentModel.DataAnnotations;
2016-09-05 19:01:43 +02:00
using Billing;
2017-01-31 13:19:12 +01:00
using Workflow;
2016-07-27 10:55:44 +02:00
2017-02-27 19:28:32 +01:00
public class Service : BaseProduct
2016-07-27 10:55:44 +02:00
{
2017-02-27 19:28:32 +01:00
/// <summary>
/// An unique product identifier.
/// </summary>
/// <returns></returns>
[Key(),DatabaseGenerated(DatabaseGeneratedOption.Identity)]
public long Id { get; set; }
2016-07-27 10:55:44 +02:00
public string ContextId { get; set; }
[ForeignKey("ContextId")]
public virtual Activity Context { get; set; }
/// <summary>
/// List of billing clause,
/// associated to this service,
/// that defines the transformation rules
/// to take in account during the transformation
/// of a corresponding prestation to an amount to pay.
/// This property is built at constructing a new instance
/// and is not mapped in database.
/// For the moment, it's hard coded only.
/// </summary>
/// <returns></returns>
[NotMapped]
2016-08-30 23:04:25 +02:00
public List<IBillingClause> Billing { get; set; }
2016-07-27 10:55:44 +02:00
2016-11-16 10:17:39 +01:00
2016-07-27 10:55:44 +02:00
}
}