public void NUnit_DynamicColumn_Domain_GetById() { Sys_DynamicColumnServices service = new Sys_DynamicColumnServices(); var model = new Sys_DynamicColumn { Id = 75 }; var result = service.GetById<Sys_DynamicColumn>(model.Id,ref status) as Sys_DynamicColumn; NUnit.Framework.Assert.IsNotNull(result); Console.Write("SearchResult: " + result.Id + " | " + result.Code + " | " + result.ColumnName ); }
public void NUnit_DynamicColumn_Domain_GetById() { Sys_DynamicColumnServices service = new Sys_DynamicColumnServices(); var model = new Sys_DynamicColumn { Id = 75 }; var result = service.GetById <Sys_DynamicColumn>(model.Id, ref status) as Sys_DynamicColumn; NUnit.Framework.Assert.IsNotNull(result); Console.Write("SearchResult: " + result.Id + " | " + result.Code + " | " + result.ColumnName ); }
// GET api/<controller>/5 public Sys_DynamicColumnModel Get(Guid id) { string status = string.Empty; var service = new Sys_DynamicColumnServices(); var result = service.GetById <Sys_DynamicColumnEntity>(id, ref status); var Sys_DynamicColumn = new Sys_DynamicColumnModel { ID = result.ID, ColumnName = result.ColumnName, Code = result.Code, Status = result.Status, DataType = result.DataType, Length = result.Length, TableName = result.TableName, Comment = result.Comment }; return(Sys_DynamicColumn); }