using Cksoft.Unity; using System; using System.Collections; using System.Collections.Generic; namespace DllEapEntity { [Table("MacModel")] public class MacModel : BaseEntity { ////自动产生代码开始&&此行不能删除 #region 自动产生代码 public MacModel() { base.EntityStatusID = 1; } [ColDetail(20, "代码", 1, 1, 80, 1, "a.FCode", "editFCode", 1, 1)] public string FCode { get; set; } [ColDetail(30, "名称", 1, 1, 100, 1, "a.FName", "editFName", 1, 1)] public string FName { get; set; } [ColDetail(40, "备注", 1, 1, 200, 1, "a.Remark", "editRemark", 1, 1)] public string Remark { get; set; } [ColDetail(50, "录入人代码", 1, 1, 100, 1, "a.RecCode", "editRecCode", 1, 1)] public string RecCode { get; set; } [ColDetail(60, "录入日期", 1, 1, 100, 1, "a.RecTime", "editRecTime", 1, 1)] public DateTime RecTime { get; set; } [ColDetail(70, "修改人代码", 1, 1, 100, 1, "a.ModCode", "editModCode", 1, 1)] public string ModCode { get; set; } [ColDetail(80, "修改时间", 1, 1, 100, 1, "a.ModTime", "editModTime", 1, 1)] public DateTime ModTime { get; set; } [ColDetail(90, "录入人", 1, 0, 100, 1, "b.FName", "editRecName", 1, 1)] public string RecName { get; set; } [ColDetail(100, "修改人", 1, 0, 100, 1, "c.FName", "editModName", 1, 1)] public string ModName { get; set; } [ColDetail(10000, "ID", 1, 1, 100, 1, "a.ID", "editID", 1, 1)] [Key] [Identity] public int ID { get; set; } [ColDetail(10010, "软件版本", 1, 1, 100, 1, "a.SoftVersion", "editSoftVersion", 1, 1)] public string SoftVersion { get; set; } [ColDetail(10020, "厂商ID", 1, 1, 100, 1, "a.SupplierID", "editSupplierFCode", 1, 2)] public int SupplierID { get; set; } [ColDetail(10030, "厂商代码", 1, 0, 100, 1, "d.FCode", "editSupplierFCode", 1, 1)] public string SupplierFCode { get; set; } [ColDetail(10040, "ProRootPath", 1, 1, 100, 1, "a.ProRootPath", "", 1, 1)] public string ProRootPath { get; set; } public override string GetSelectSql() { return string.Format($"select { GetQueryColSql()} from { GetQueryTabSql()}"); } public override string GetQueryColSql() { string sqlstr = "a.FCode FCode,a.FName FName,a.Remark Remark,a.RecCode RecCode,a.RecTime RecTime,a.ModCode ModCode,a.ModTime ModTime,b.FName RecName"; sqlstr += ",c.FName ModName,a.ID ID,a.SoftVersion SoftVersion,a.SupplierID SupplierID,d.FCode SupplierFCode,a.ProRootPath ProRootPath,0 EntityStatusID"; return sqlstr; } public override string GetQueryTabSql() { string sqlstr = " MacModel a "; sqlstr += " left outer join staff b on a.RecCode =b.FCode"; sqlstr += " left outer join staff c on a.ModCode =c.FCode"; sqlstr += " left outer join supplier d on a.SupplierID =d.id"; return sqlstr; } public override string GetQuerySortSql() { return " "; } #endregion ////自动产生代码结束&&此行不能删除 /// public string TPCode { get; set; } public IEnumerable MMSecDetails { get; set; } } }