@Override public MailTemplateResponse getTemplateById( @WebParam(name = "id", targetNamespace = "") String id) { MailTemplateResponse resp = new MailTemplateResponse(ResponseStatus.SUCCESS); MailTemplateDto mailTemplateDto = tmplService.getTemplateById(id); if (mailTemplateDto.getTmplId() == null || mailTemplateDto.getTmplId().isEmpty()) { resp.setStatus(ResponseStatus.FAILURE); } else { resp.setMailTemplate(mailTemplateDto); } return resp; }
@Override public MailTemplateResponse updateTemplate( @WebParam(name = "template", targetNamespace = "") MailTemplateDto template) { MailTemplateResponse resp = new MailTemplateResponse(ResponseStatus.SUCCESS); MailTemplateDto mailTemplate = tmplService.updateTemplate(template); if (mailTemplate.getTmplId() == null || mailTemplate.getTmplId().isEmpty()) { resp.setStatus(ResponseStatus.FAILURE); } else { resp.setMailTemplate(mailTemplate); } return resp; }