using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace Mesnac.Action.ChemicalWeighing.Entity
{
///
/// 配方简单实体封装
///
[Serializable]
public class SimplePmtRecipe
{
///
/// ID
///
public string ID { get; set; }
///
/// 配方物料GUID
///
public string MaterialGUID { get; set; }
///
/// 配方物料代码
///
public string RecipeMaterialCode { get; set; }
///
/// 配方物料名称
///
public string RecipeMaterialName { get; set; }
///
/// 配方编码
///
public string Recipe_Code { get; set; }
///
/// 配方名称
///
public string Recipe_Name { get; set; }
///
/// 配方类型
///
public string Recipe_type { get; set; }
///
/// 版本号
///
public string Version { get; set; }
private string _content = String.Empty;
///
/// 内容
///
public string Content
{
get { return _content; }
set { _content = value; }
}
public override string ToString()
{
if (String.IsNullOrEmpty(this._content))
{
if (String.IsNullOrEmpty(this.Version))
{
return String.Format("{0}({1})", this.RecipeMaterialName, this.Recipe_Name);
}
else
{
return String.Format("{0}({1})[{2}]", this.RecipeMaterialName, this.Recipe_Name, this.Version);
}
}
else
{
return this._content;
}
}
}
}