From 615413ae90da109309a2d94066c203eb76a5ea11 Mon Sep 17 00:00:00 2001 From: Khanh Ngo Date: Sun, 2 Sep 2018 08:03:01 +0700 Subject: [PATCH] Add record_quick_edit config to DB --- app/models.py | 2 +- app/views.py | 2 +- migrations/versions/4a666113c7bb_add_operator_role.py | 1 + 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/app/models.py b/app/models.py index 82fabf9..505fd62 100644 --- a/app/models.py +++ b/app/models.py @@ -1796,7 +1796,7 @@ class Setting(db.Model): 'default_record_table_size': 15, 'default_domain_table_size': 10, 'auto_ptr': False, - 'allow_quick_edit': True, + 'record_quick_edit': True, 'pretty_ipv6_ptr': False, 'dnssec_admins_only': False, 'allow_user_create_domain': False, diff --git a/app/views.py b/app/views.py index 691072d..4cdbda8 100644 --- a/app/views.py +++ b/app/views.py @@ -567,7 +567,7 @@ def domain(domain_name): # can not get any record, API server might be down return redirect(url_for('error', code=500)) - quick_edit = Setting().get('allow_quick_edit') + quick_edit = Setting().get('record_quick_edit') records_allow_to_edit = Setting().get_records_allow_to_edit() forward_records_allow_to_edit = Setting().get_forward_records_allow_to_edit() reverse_records_allow_to_edit = Setting().get_reverse_records_allow_to_edit() diff --git a/migrations/versions/4a666113c7bb_add_operator_role.py b/migrations/versions/4a666113c7bb_add_operator_role.py index 057937f..b3f7522 100644 --- a/migrations/versions/4a666113c7bb_add_operator_role.py +++ b/migrations/versions/4a666113c7bb_add_operator_role.py @@ -29,6 +29,7 @@ def update_data(): [ {'id': 44, 'name': 'ldap_operator_group', 'value': '', 'view': 'authentication'}, {'id': 45, 'name': 'allow_user_create_domain', 'value': 'False', 'view': 'basic'}, + {'id': 46, 'name': 'record_quick_edit', 'value': 'True', 'view': 'basic'}, ] )