using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace BLL { public static class InformationProject_ConstructionStandardIdentifyFileService { public static Model.InformationProject_ConstructionStandardIdentifyFile GetInformationProject_ConstructionStandardIdentifyFileById(string Id ) { return Funs.DB.InformationProject_ConstructionStandardIdentifyFile.FirstOrDefault(e => e.Id == Id ); } public static void AddInformationProject_ConstructionStandardIdentifyFile(Model.InformationProject_ConstructionStandardIdentifyFile newtable) { Model.InformationProject_ConstructionStandardIdentifyFile table = new Model.InformationProject_ConstructionStandardIdentifyFile(); table.Id = newtable.Id; table.Code = newtable.Code; table.FileName = newtable.FileName; table.VersionNumber = newtable.VersionNumber; table.Remark = newtable.Remark; table.Auditer = newtable.Auditer; table.ProjectId = newtable.ProjectId; table.Creater = newtable.Creater; table.CreateDate = newtable.CreateDate; Funs.DB.InformationProject_ConstructionStandardIdentifyFile.InsertOnSubmit(table); Funs.DB.SubmitChanges(); } public static void UpdateInformationProject_ConstructionStandardIdentifyFile(Model.InformationProject_ConstructionStandardIdentifyFile newtable) { Model.InformationProject_ConstructionStandardIdentifyFile table = Funs.DB.InformationProject_ConstructionStandardIdentifyFile.FirstOrDefault(e => e.Id == newtable.Id ); if (table != null) { table.Id = newtable.Id; table.Code = newtable.Code; table.FileName = newtable.FileName; table.VersionNumber = newtable.VersionNumber; table.Remark = newtable.Remark; table.Auditer = newtable.Auditer; table.ProjectId = newtable.ProjectId; table.Creater = newtable.Creater; table.CreateDate = newtable.CreateDate; Funs.DB.SubmitChanges(); } } public static void DeleteInformationProject_ConstructionStandardIdentifyFileById(string Id ) { Model.InformationProject_ConstructionStandardIdentifyFile table = Funs.DB.InformationProject_ConstructionStandardIdentifyFile.FirstOrDefault(e => e.Id == Id ); if (table != null) { Funs.DB.InformationProject_ConstructionStandardIdentifyFile.DeleteOnSubmit(table); Funs.DB.SubmitChanges(); } } } }