/// <summary> /// From SectionParagraph Request to SectionParagraph Request pivot. /// </summary> /// <param name="request">the request to assemble.</param> /// <returns>SectionParagraph Request pivot result.</returns> public static SectionParagraphRequestPivot ToPivot(this SectionParagraphRequest request) { return(new SectionParagraphRequestPivot { FindSectionParagraphPivot = Utility.EnumToEnum <FindSectionParagraphDto, FindSectionParagraphPivot>(request.FindSectionParagraphDto), SectionParagraphPivot = request.SectionParagraphDto.ToPivot() }); }
/// <summary> /// Delete SectionParagraph /// </summary> /// <param name="request">sectionParagraph request.</param> /// <returns>SectionParagraph message.</returns> public SectionParagraphMessage DeleteSectionParagraph(SectionParagraphRequest request) { SectionParagraphMessage message = new SectionParagraphMessage(); try { _serviceSectionParagraph.DeleteSectionParagraph(request.ToPivot()); message.OperationSuccess = true; } catch (Exception e) { message.ErrorType = ErrorType.TechnicalError; message.ErrorMessage = e.Message; } return(message); }