Beispiel #1
0
 public Entity.BaseResponse <Entity.SearchResult <List <Entity.AlertResponse> > > GetBySearch(string deviceGuid = "", string entityGuid = "", int?pageNo = 1, int?pageSize = 10, string orderBy = "")
 {
     Entity.BaseResponse <Entity.SearchResult <List <Entity.AlertResponse> > > response = new Entity.BaseResponse <Entity.SearchResult <List <Entity.AlertResponse> > >(true);
     try
     {
         response.Data = _ruleService.AlertList(new Entity.AlertRequest()
         {
             DeviceGuid = deviceGuid,
             EntityGuid = entityGuid,
             OrderBy    = orderBy,
             PageNumber = pageNo,
             PageSize   = pageSize
         });
     }
     catch (Exception ex)
     {
         base.LogException(ex);
         return(new Entity.BaseResponse <Entity.SearchResult <List <Entity.AlertResponse> > >(false, ex.Message));
     }
     return(response);
 }