public static int GetVal(int i) { List <BusParViewModel> result = new List <BusParViewModel>(); result = BusParMethod.get_BusPar().Select(bpar => new BusParViewModel { ID = bpar.ID, Code = bpar.Code, Name = bpar.Name, ValueType = bpar.ValueType }).ToList(); return(result.Find(x => x.ID == i).ValueType); }
public static DataSourceResult GetBusParDatasource([DataSourceRequest] DataSourceRequest request) { DataSourceResult result = BusParMethod.get_BusPar().ToDataSourceResult(request, busfunc => new BusParViewModel { ID = busfunc.ID, Name = busfunc.Name, Code = busfunc.Code, ValueType = busfunc.ValueType, Comment = busfunc.Comment }); return(result); }
public static DataSourceResult GetBusParByIDDatasource(int id, [DataSourceRequest] DataSourceRequest request) { return(BusParMethod.HierarchyBusParDataSource(id, request)); }
public static void UpdateBusParModel(BusParViewModel bus) { BusParMethod.BusParModelUpdate(ConvertToBusPar(bus)); }
public static void DestroyBusParModel(BusParViewModel bus) { BusParMethod.DestroyBusParModel(ConvertToBusPar(bus)); }
public static void CreateBusParModel(BusParViewModel bus) { BusParMethod.CreateBusParModel(ConvertToBusPar(bus)); }