Пример #1
0
 public IUserPermissionMvoStateEvent GetStateEvent(string id, long version)
 {
     try {
         var idObj = UserPermissionMvosControllerUtils.ParseIdString(id);
         return(_userPermissionMvoApplicationService.GetStateEvent(idObj, version));
     } catch (Exception ex) { var response = UserPermissionMvosControllerUtils.GetErrorHttpResponseMessage(ex); throw new HttpResponseException(response); }
 }
Пример #2
0
 public UserPermissionMvoStateDto Get(string id, string fields = null)
 {
     try {
         var idObj = UserPermissionMvosControllerUtils.ParseIdString(id);
         var state = (UserPermissionMvoState)_userPermissionMvoApplicationService.Get(idObj);
         if (state == null)
         {
             return(null);
         }
         var stateDto = new UserPermissionMvoStateDto(state);
         if (String.IsNullOrWhiteSpace(fields))
         {
             stateDto.AllFieldsReturned = true;
         }
         else
         {
             stateDto.ReturnedFieldsString = fields;
         }
         return(stateDto);
     } catch (Exception ex) { var response = UserPermissionMvosControllerUtils.GetErrorHttpResponseMessage(ex); throw new HttpResponseException(response); }
 }