- a module for IT services business
- Mvc-like action binding in the WF web api ... ? * Yavsc.sln: * Web.csproj: * MvcActionValueBinder.cs: * yavscModel.csproj: * WFOrder.cs: * IWFOrder.cs: * BasketImpact.cs: * ProjectInfo.cs: * IWFModule.cs: * IWFCommand.cs: * WorkFlowController.cs: * NewProjectModel.cs: * IContentProvider.cs: * ITCPNpgsqlProvider.cs: * WorkFlowProvider.csproj: * ITContentProvider.csproj: * AssemblyInfo.cs: * OrderStatusChangedEventArgs.cs: * NpgsqlContentProvider.cs:
This commit is contained in:
parent
04804b89a9
commit
fa93ce7fee
19 changed files with 412 additions and 122 deletions
|
|
@ -2,28 +2,35 @@ using System;
|
|||
using SalesCatalog.Model;
|
||||
using yavscModel.WorkFlow;
|
||||
|
||||
namespace WorkFlow
|
||||
namespace yavscModel.WorkFlow
|
||||
{
|
||||
public class WFOrder : IWFCommand
|
||||
public class WFOrder : IWFOrder
|
||||
{
|
||||
private Product p;
|
||||
private DateTime date;
|
||||
private string catref;
|
||||
private string id = null;
|
||||
public WFOrder(Product prod,string catalogReference){
|
||||
date = DateTime.Now;
|
||||
catref=catalogReference;
|
||||
p = prod;
|
||||
id = Guid.NewGuid ().ToString();
|
||||
}
|
||||
public override string ToString ()
|
||||
{
|
||||
return string.Format ("[Commande date={0} prodref={1}, cat={2}]",date,p.Reference,catref);
|
||||
}
|
||||
|
||||
#region IWFCommand implementation
|
||||
public event EventHandler<OrderStatusChangedEventArgs> StatusChanged;
|
||||
|
||||
public string CatalogReference {
|
||||
#region IWFCommand implementation
|
||||
/// <summary>
|
||||
/// Gets the catalog reference, a unique id for the catalog (not a product id).
|
||||
/// </summary>
|
||||
/// <value>The catalog reference.</value>
|
||||
public string UniqueID {
|
||||
get {
|
||||
return catref;
|
||||
return id;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue