Class HvlNotificationMailTemplateController

java.lang.Object
tr.com.havelsan.javarch.notification.mail.starter.controller.HvlNotificationMailTemplateController
All Implemented Interfaces:
HvlNotificationTemplateRestService

@RestController @RequestMapping("${hvl.notification.mail.service.controller-path:/notification/template}") public class HvlNotificationMailTemplateController extends Object implements HvlNotificationTemplateRestService
The class in which service endpoints are defined for notification template operations.
  • Constructor Details

    • HvlNotificationMailTemplateController

      public HvlNotificationMailTemplateController(HvlNotificationTemplateService notificationTemplateService)
      Instantiates a new HvlNotificationMailRestController.
      Parameters:
      notificationTemplateService - the notification template service
  • Method Details

    • save

      @PreAuthorize("hasAuthority(\'notification_manager\')") public tr.com.havelsan.javarch.service.data.HvlResponse<Void> save(@NotNull @Valid @RequestBody @NotNull @Valid HvlNotificationTemplateModel notificationTemplateModel)
      Saves notification template.
      Specified by:
      save in interface HvlNotificationTemplateRestService
      Parameters:
      notificationTemplateModel - the notification template model
      Returns:
      the hvl response
    • update

      @PreAuthorize("hasAuthority(\'notification_manager\')") public tr.com.havelsan.javarch.service.data.HvlResponse<Void> update(@NotNull @Valid @RequestBody @NotNull @Valid HvlNotificationTemplateModel notificationTemplateModel)
      Updates notification template.
      Specified by:
      update in interface HvlNotificationTemplateRestService
      Parameters:
      notificationTemplateModel - the notification template model
      Returns:
      the hvl response
    • delete

      @PreAuthorize("hasAuthority(\'notification_manager\')") public tr.com.havelsan.javarch.service.data.HvlResponse<Void> delete(@NotBlank @Size(min=36,max=36) @PathVariable("uuid") @NotBlank @Size(min=36,max=36) String uuid)
      Deletes notification template by uuid.
      Specified by:
      delete in interface HvlNotificationTemplateRestService
      Parameters:
      uuid - the uuid
      Returns:
      the hvl response
    • getByUuid

      @PreAuthorize("hasAuthority(\'notification_manager\')") public tr.com.havelsan.javarch.service.data.HvlResponse<HvlNotificationTemplateModel> getByUuid(@NotBlank @Size(min=36,max=36) @PathVariable("uuid") @NotBlank @Size(min=36,max=36) String uuid)
      Gets notification template model by uuid.
      Specified by:
      getByUuid in interface HvlNotificationTemplateRestService
      Parameters:
      uuid - the uuid
      Returns:
      the hvl response
    • queryDataPage

      @PreAuthorize("hasAuthority(\'notification_manager\')") public tr.com.havelsan.javarch.service.data.HvlResponse<tr.com.havelsan.javarch.data.commons.pageable.HvlPage<HvlNotificationTemplateDataModel>> queryDataPage(@NotNull @Valid @RequestBody @NotNull @Valid HvlNotificationTemplateQueryModel notificationTemplateQueryModel)
      Returns a page of mail template matching the query criteria.
      Specified by:
      queryDataPage in interface HvlNotificationTemplateRestService
      Parameters:
      notificationTemplateQueryModel - the mail template query model
      Returns:
      the hvl response
    • preview

      public tr.com.havelsan.javarch.service.data.HvlResponse<HvlNotificationTemplateContentModel> preview(@NotNull @Valid @RequestBody @NotNull @Valid HvlNotificationTemplateQueryModel notificationTemplateQueryModel)
      Provides preview for mail with parameters
      Specified by:
      preview in interface HvlNotificationTemplateRestService
      Parameters:
      notificationTemplateQueryModel - the notification mail preview query model
      Returns:
      the hvl response