"""Module manifest — see core/modules/model.py and APPS_PLATFORM §4.""" from core.modules.model import Module, Mount, Perm, SettingDef MODULE = Module( key='pricing', kind='feature', name='Pricing', description='Price groups, happy hours, modifiers, deals and waiter discounts.', depends=('ordering',), permissions=( Perm('pricing.manage', 'Set up price groups, modifiers and deals', roles=('owner', 'store_manager')), Perm('pricing.discounts.apply', 'Give discounts', roles=('owner', 'store_manager')), Perm('pricing.discounts.over_limit', 'Give discounts beyond the per-waiter limits', roles=('owner', 'store_manager'), overridable=True), ), settings=( SettingDef('discounts.enabled', 'true', 'Global switch for waiter discounts.', type='bool'), SettingDef('discounts.max_total_value_workday', '', 'Max total discount value per business day (empty = no limit).', type='str'), SettingDef('discounts.max_total_value_shift', '', 'Max total discount value per waiter shift (empty = no limit).', type='str'), SettingDef('discounts.max_items_per_shift', '', 'Max discounted items per waiter shift (empty = no limit).', type='str'), ), routers=( Mount('routers.pricing', '/api/pricing'), ), )