From 883f912969874ddcf2fe0dc7567881e1ec8f79aa Mon Sep 17 00:00:00 2001 From: Chris Church Date: Wed, 15 Apr 2015 13:09:03 -0400 Subject: [PATCH] Allow verbosity level choices to be specified by settings. --- awx/main/models/base.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/awx/main/models/base.py b/awx/main/models/base.py index 99511f6330..da76af7688 100644 --- a/awx/main/models/base.py +++ b/awx/main/models/base.py @@ -9,6 +9,7 @@ import shlex import yaml # Django +from django.conf import settings from django.db import models from django.core.exceptions import ValidationError from django.utils.translation import ugettext_lazy as _ @@ -58,14 +59,14 @@ PERMISSION_TYPE_CHOICES = [ CLOUD_INVENTORY_SOURCES = ['ec2', 'rax', 'vmware', 'gce', 'azure', 'openstack', 'custom'] -VERBOSITY_CHOICES = [ +VERBOSITY_CHOICES = getattr(settings, 'VERBOSITY_CHOICES', [ (0, '0 (Normal)'), (1, '1 (Verbose)'), (2, '2 (More Verbose)'), (3, '3 (Debug)'), (4, '4 (Connection Debug)'), (5, '5 (WinRM Debug)'), -] +]) class VarsDictProperty(object):