Skip to content

Commit cce8d69

Browse files
committed
fixup! ✨(backend) add EmailTemplate model and API
1 parent 7c44ade commit cce8d69

File tree

1 file changed

+0
-13
lines changed

1 file changed

+0
-13
lines changed

src/backend/core/models.py

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1466,21 +1466,8 @@ def get_formatted_content(self) -> str:
14661466
Returns:
14671467
Formatted template content
14681468
"""
1469-
if self.type == TemplateTypeChoices.SIGNATURE:
1470-
# For signatures, prefer HTML body if available, otherwise text body
1471-
return self.html_body or self.text_body
1472-
1473-
# For non-signatures, return HTML body if available, otherwise text body
14741469
return self.html_body or self.text_body
14751470

1476-
def is_signature(self) -> bool:
1477-
"""Check if this template is a signature."""
1478-
return self.type == TemplateTypeChoices.SIGNATURE
1479-
1480-
def is_template(self) -> bool:
1481-
"""Check if this template is a regular template (not a signature)."""
1482-
return self.type != TemplateTypeChoices.SIGNATURE
1483-
14841471

14851472
class EmailTemplateMailDomain(BaseModel):
14861473
"""Through model for EmailTemplate to MailDomain relationship with is_default flag."""

0 commit comments

Comments
 (0)