OpenSlides/openslides/motion/signals.py

31 lines
979 B
Python
Raw Normal View History

2013-01-26 16:33:55 +01:00
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
openslides.motion.signals
~~~~~~~~~~~~~~~~~~~~~~~~~
2013-01-26 16:33:55 +01:00
Signals for the motion app.
2013-02-05 18:46:46 +01:00
:copyright: (c) 2011-2013 by the OpenSlides team, see AUTHORS.
2013-01-26 16:33:55 +01:00
:license: GNU GPL, see LICENSE for more details.
"""
from django.dispatch import receiver
from django.utils.translation import ugettext as _
from openslides.config.signals import default_config_value
2013-01-26 16:33:55 +01:00
@receiver(default_config_value, dispatch_uid="motion_default_config")
def default_config(sender, key, **kwargs):
2013-02-05 18:46:46 +01:00
"""Return the default config values for the motion app."""
2013-01-26 16:33:55 +01:00
return {
'motion_min_supporters': 0,
'motion_preamble': _('The assembly may decide,'),
'motion_pdf_ballot_papers_selection': 'CUSTOM_NUMBER',
'motion_pdf_ballot_papers_number': '8',
'motion_pdf_title': _('Motions'),
'motion_pdf_preamble': '',
'motion_allow_disable_versioning': False,
'motion_workflow': 1}.get(key)