예제 #1
0
 public PicklistRoleMvoStateCreatedOrMergePatchedOrDeletedDto GetStateEvent(string id, long version)
 {
     try {
         var idObj = PicklistRoleMvosControllerUtils.ParseIdString(id);
         var conv  = new PicklistRoleMvoStateEventDtoConverter();
         var se    = _picklistRoleMvoApplicationService.GetEvent(idObj, version);
         return(se == null ? null : conv.ToPicklistRoleMvoStateEventDto(se));
     } catch (Exception ex) { var response = PicklistRoleMvosControllerUtils.GetErrorHttpResponseMessage(ex); throw new HttpResponseException(response); }
 }
예제 #2
0
 public IPicklistRoleMvoStateDto Get(string id, string fields = null)
 {
     try {
         var idObj = PicklistRoleMvosControllerUtils.ParseIdString(id);
         var state = _picklistRoleMvoApplicationService.Get(idObj);
         if (state == null)
         {
             return(null);
         }
         var stateDto = new PicklistRoleMvoStateDtoWrapper(state);
         if (String.IsNullOrWhiteSpace(fields))
         {
             stateDto.AllFieldsReturned = true;
         }
         else
         {
             stateDto.ReturnedFieldsString = fields;
         }
         return(stateDto);
     } catch (Exception ex) { var response = PicklistRoleMvosControllerUtils.GetErrorHttpResponseMessage(ex); throw new HttpResponseException(response); }
 }