* Moving plugins infrastructure to edx-django-utils This PR extracts the code that enables plugins in edx-platform and puts it in edx-django-utils. This is done to allow other IDAS to add plugin functionality.
33 lines
912 B
Python
33 lines
912 B
Python
"""
|
|
Announcements Application Configuration
|
|
"""
|
|
|
|
|
|
from django.apps import AppConfig
|
|
from edx_django_utils.plugins import PluginURLs, PluginSettings
|
|
|
|
from openedx.core.djangoapps.plugins.constants import ProjectType, SettingsType
|
|
|
|
|
|
class AnnouncementsConfig(AppConfig):
|
|
"""
|
|
Application Configuration for Announcements
|
|
"""
|
|
name = u'openedx.features.announcements'
|
|
|
|
plugin_app = {
|
|
PluginURLs.CONFIG: {
|
|
ProjectType.LMS: {
|
|
PluginURLs.NAMESPACE: u'announcements',
|
|
PluginURLs.REGEX: u'^announcements/',
|
|
PluginURLs.RELATIVE_PATH: u'urls',
|
|
}
|
|
},
|
|
PluginSettings.CONFIG: {
|
|
ProjectType.LMS: {
|
|
SettingsType.COMMON: {PluginSettings.RELATIVE_PATH: u'settings.common'},
|
|
SettingsType.TEST: {PluginSettings.RELATIVE_PATH: u'settings.test'},
|
|
}
|
|
}
|
|
}
|