Search in sources :

Example 11 with AggregationEmailTemplate

use of com.redhat.cloud.notifications.models.AggregationEmailTemplate in project notifications-backend by RedHatInsights.

the class TemplateResourceTest method buildAggregationEmailTemplate.

private static AggregationEmailTemplate buildAggregationEmailTemplate(String appId, String subjectTemplateId, String bodyTemplateId) {
    AggregationEmailTemplate emailTemplate = new AggregationEmailTemplate();
    emailTemplate.setSubscriptionType(DAILY);
    if (appId != null) {
        emailTemplate.setApplicationId(UUID.fromString(appId));
    }
    emailTemplate.setSubjectTemplateId(UUID.fromString(subjectTemplateId));
    emailTemplate.setBodyTemplateId(UUID.fromString(bodyTemplateId));
    return emailTemplate;
}
Also used : AggregationEmailTemplate(com.redhat.cloud.notifications.models.AggregationEmailTemplate) CrudTestHelpers.deleteAggregationEmailTemplate(com.redhat.cloud.notifications.CrudTestHelpers.deleteAggregationEmailTemplate) CrudTestHelpers.createAggregationEmailTemplate(com.redhat.cloud.notifications.CrudTestHelpers.createAggregationEmailTemplate) CrudTestHelpers.updateAggregationEmailTemplate(com.redhat.cloud.notifications.CrudTestHelpers.updateAggregationEmailTemplate)

Aggregations

AggregationEmailTemplate (com.redhat.cloud.notifications.models.AggregationEmailTemplate)11 InstantEmailTemplate (com.redhat.cloud.notifications.models.InstantEmailTemplate)6 Template (com.redhat.cloud.notifications.models.Template)5 Application (com.redhat.cloud.notifications.models.Application)4 Transactional (javax.transaction.Transactional)3 CrudTestHelpers.createAggregationEmailTemplate (com.redhat.cloud.notifications.CrudTestHelpers.createAggregationEmailTemplate)2 CrudTestHelpers.deleteAggregationEmailTemplate (com.redhat.cloud.notifications.CrudTestHelpers.deleteAggregationEmailTemplate)2 CrudTestHelpers.updateAggregationEmailTemplate (com.redhat.cloud.notifications.CrudTestHelpers.updateAggregationEmailTemplate)2 CrudTestHelpers.createInstantEmailTemplate (com.redhat.cloud.notifications.CrudTestHelpers.createInstantEmailTemplate)1 CrudTestHelpers.createTemplate (com.redhat.cloud.notifications.CrudTestHelpers.createTemplate)1 CrudTestHelpers.deleteInstantEmailTemplate (com.redhat.cloud.notifications.CrudTestHelpers.deleteInstantEmailTemplate)1 CrudTestHelpers.deleteTemplate (com.redhat.cloud.notifications.CrudTestHelpers.deleteTemplate)1 CrudTestHelpers.updateInstantEmailTemplate (com.redhat.cloud.notifications.CrudTestHelpers.updateInstantEmailTemplate)1 CrudTestHelpers.updateTemplate (com.redhat.cloud.notifications.CrudTestHelpers.updateTemplate)1 DbIsolatedTest (com.redhat.cloud.notifications.db.DbIsolatedTest)1 Action (com.redhat.cloud.notifications.ingress.Action)1 Context (com.redhat.cloud.notifications.ingress.Context)1 Event (com.redhat.cloud.notifications.models.Event)1 User (com.redhat.cloud.notifications.recipients.User)1 EmailTemplate (com.redhat.cloud.notifications.templates.EmailTemplate)1