using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.IO;
using System.Linq;
using System.Runtime.Serialization;
using System.Runtime.Serialization.Formatters.Binary;
using System.Text;
using Core.Mes.Client.Comm.Attribute;
using Newtonsoft.Json;
namespace Core.StlMes.Client.SaleOrder
{
[Serializable]
public class CraftOrdDesignStdPicSmpTotalEntity: ICloneable
{
///
/// 工艺文件号
///
private string craftNo = "";
///
/// 工序代码
///
private string processCode = "";
///
/// ORD_LN_PK
///
private string ordLnPk = "";
///
/// CRAFT_SEQ
///
private string craftSeq = "";
///
/// ORD_LN_PK
///
[Description("ORD_LN_PK")]
[Nullable(false)]
[DataLength(150)]
public string OrdLnPk
{
get { return ordLnPk; }
set { ordLnPk = value; }
}
///
/// 序号
///
[Description("序号")]
[Nullable(false)]
[DataLength(150)]
public string CraftSeq
{
get { return craftSeq; }
set { craftSeq = value; }
}
///
/// 工艺文件号
///
[Description("工艺文件号")]
[Nullable(false)]
[DataLength(150)]
public string CraftNo
{
get { return craftNo; }
set { craftNo = value; }
}
///
/// 工序代码
///
[Description("工序代码")]
[Nullable(false)]
[DataLength(100)]
public string ProcessCode
{
get { return processCode; }
set { processCode = value; }
}
///
/// 根据批数分情况讨论
///
private decimal? batchNum;
///
/// 根据批数分情况讨论
///
[Description("分类")]
[Nullable(false)]
[DataLength(40)]
[JsonProperty("type")]
public decimal? BatchNum
{
get { return batchNum; }
set { batchNum = value; }
}
///
/// 第几批
///
private decimal? batchNo = 0;
///
/// 第几批
///
[Description("批号")]
[Nullable(false)]
[DataLength(40)]
[JsonProperty("batchNo")]
public decimal? BatchNo
{
get { return batchNo; }
set { batchNo = value; }
}
///
/// SAMPLE_LENGTH
///
private string sampleLength = "";
///
/// SAMPLE_NO
///
[Description("样管长度")]
[Nullable(false)]
[DataLength(40)]
[JsonProperty("sampleLength")]
public string SampleLength
{
get { return sampleLength; }
set { sampleLength = value; }
}
///
/// POSITION
///
private string position = "";
///
/// POSITION
///
[Description("取样位置代码")]
[Nullable(false)]
[DataLength(40)]
[JsonProperty("position")]
public string Position
{
get { return position; }
set { position = value; }
}
///
/// DESC_POSITION
///
private string descPosition = "";
///
/// DESC_POSITION
///
[Description("取样位置")]
[Nullable(false)]
[DataLength(40)]
[JsonProperty("type")]
public string DescPosition
{
get { return descPosition; }
set { descPosition = value; }
}
///
/// SAMPLE_COUNT
///
private string sampleCount = "";
///
/// SAMPLE_COUNT
///
[Description("取样数量(管头)")]
[Nullable(false)]
[DataLength(40)]
[JsonProperty("sampleCount")]
public string SampleCount
{
get { return sampleCount; }
set { sampleCount = value; }
}
///
/// REMARK
///
private string remark = "";
///
/// REMARK
///
[Description("备注说明")]
[Nullable(false)]
[DataLength(40)]
[JsonProperty("remark")]
public string Remark
{
get { return remark; }
set { remark = value; }
}
///
/// PHY_NAME_GROUP
///
private string phyNameGroup = "";
///
/// PHY_NAME_GROUP
///
[Description("试样码集合")]
[Nullable(false)]
[DataLength(40)]
[JsonProperty("phyNameGroup")]
public string PhyNameGroup
{
get { return phyNameGroup; }
set { phyNameGroup = value; }
}
///
/// SPLINE_NO
///
private string phyCodeGroup = "";
///
/// PHY_CODE_GROUP
///
[Description("试样码集合")]
[Nullable(false)]
[DataLength(40)]
[JsonProperty("phyCodeGroup")]
public string PhyCodeGroup
{
get { return phyCodeGroup; }
set { phyCodeGroup = value; }
}
///
/// 根据炉数分情况讨论,可能是公式 5n+2 或者<=2
///
private string stoveNum = "";
///
/// 根据炉数分情况讨论,可能是公式 5n+2 或者<=2
///
[Description("炉数")]
[Nullable(true)]
[DataLength(20)]
public string StoveNum
{
get { return stoveNum; }
set { stoveNum = value; }
}
public object Tag { get; set; }
public object Clone()
{
using (var memStream = new MemoryStream())
{
var binaryFormatter = new BinaryFormatter(null,
new StreamingContext(StreamingContextStates.Clone));
binaryFormatter.Serialize(memStream, this);
memStream.Seek(0, SeekOrigin.Begin);
return binaryFormatter.Deserialize(memStream);
}
}
}
}