Initial pop3 email fetch task
This commit is contained in:
@@ -8,6 +8,7 @@ from common.utils import encapsulate
|
||||
from project_setup.api import register_setup
|
||||
from documents.permissions import (PERMISSION_DOCUMENT_NEW_VERSION,
|
||||
PERMISSION_DOCUMENT_CREATE)
|
||||
from scheduler.api import register_interval_job
|
||||
|
||||
from .staging import StagingFile
|
||||
from .models import (WebForm, StagingFolder, SourceTransformation,
|
||||
@@ -16,6 +17,7 @@ from .widgets import staging_file_thumbnail
|
||||
from .permissions import (PERMISSION_SOURCES_SETUP_VIEW,
|
||||
PERMISSION_SOURCES_SETUP_EDIT, PERMISSION_SOURCES_SETUP_DELETE,
|
||||
PERMISSION_SOURCES_SETUP_CREATE)
|
||||
from .tasks import task_fetch_pop3_emails
|
||||
|
||||
staging_file_preview = {'text': _(u'preview'), 'class': 'fancybox-noscaling', 'view': 'staging_file_preview', 'args': ['source.source_type', 'source.pk', 'object.id'], 'famfam': 'zoom', 'permissions': [PERMISSION_DOCUMENT_NEW_VERSION, PERMISSION_DOCUMENT_CREATE]}
|
||||
staging_file_delete = {'text': _(u'delete'), 'view': 'staging_file_delete', 'args': ['source.source_type', 'source.pk', 'object.id'], 'famfam': 'delete', 'keep_query': True, 'permissions': [PERMISSION_DOCUMENT_NEW_VERSION, PERMISSION_DOCUMENT_CREATE]}
|
||||
@@ -76,3 +78,5 @@ register_model_list_columns(StagingFile, [
|
||||
])
|
||||
|
||||
register_setup(setup_sources)
|
||||
|
||||
#register_interval_job('task_fetch_pop3_emails', _(u'Connects to the POP3 email sources and fetches the attached documents.'), task_fetch_pop3_emails, seconds=5)#QUEUE_PROCESSING_INTERVAL)
|
||||
|
||||
Reference in New Issue
Block a user