add EmailTemplate

helpdesk-email
Nate Smith 2019-07-19 20:52:01 -05:00
parent de07b42082
commit 05d5898fa9
2 changed files with 31 additions and 0 deletions

View File

@ -0,0 +1,23 @@
# -*- coding: utf-8 -*-
# Generated by Django 1.10.2 on 2019-07-20 01:40
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('help', '0004_ticket_submitted'),
]
operations = [
migrations.CreateModel(
name='EmailTemplate',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('name', models.CharField(max_length=50)),
('body', models.TextField()),
],
),
]

View File

@ -46,3 +46,11 @@ class Note(Model):
def __str__(self):
return "admin note"
class EmailTemplate(Model):
name = CharField(blank=False, null=False, max_length=50)
body = TextField(blank=False, null=False)
def __str__(self):
return f"'{self.name}' email template"