mirror of
https://github.com/coddingtonbear/django-mailbox.git
synced 2026-07-09 22:38:19 +02:00
add DJANGO_MAILBOX_MESSAGE_UPLOAD_TO to settings, change utils.get_attachment_save_path to utils.get_save_path, change eml upload_to in model
This commit is contained in:
parent
6004a2286f
commit
2824cde5e9
3 changed files with 17 additions and 5 deletions
|
|
@ -512,7 +512,7 @@ class Message(models.Model):
|
|||
eml = models.FileField(
|
||||
_('Raw message contents'),
|
||||
null=True,
|
||||
upload_to="messages",
|
||||
upload_to=utils.get_save_path(setting='message_upload_to'),
|
||||
help_text=_('Original full content of message')
|
||||
)
|
||||
objects = models.Manager()
|
||||
|
|
@ -752,7 +752,7 @@ class MessageAttachment(models.Model):
|
|||
|
||||
document = models.FileField(
|
||||
_('Document'),
|
||||
upload_to=utils.get_attachment_save_path,
|
||||
upload_to=utils.get_save_path(setting='attachment_upload_to'),
|
||||
)
|
||||
|
||||
def delete(self, *args, **kwargs):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue