From 91086acdecc7f31593f0eaaf694f1159e9be8892 Mon Sep 17 00:00:00 2001 From: Sean Hammond Date: Wed, 20 Feb 2013 17:31:52 +0100 Subject: [PATCH] Show vocab tags as normal tags by default Commit 77663865a changed the default behaviour of vocab tags so that they are _not_ shown as normal tags (e.g. on the dataset read and search pages). I thought this was a good idea because it's weird when you use tag vocabulary to add a custom field, to see that tag also appear in the normal tags. However, changing this behaviour breaks some tests, so I'm changing it back! If an extension is using a tag vocabulary to add a custom field, and it doesn't want tags from that vocabulary to appear alongside normal tags, then the extension can add the freet_tags_only converter to the schema itself. --- ckan/logic/schema.py | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/ckan/logic/schema.py b/ckan/logic/schema.py index 53af9fd01ef..23877518b8b 100644 --- a/ckan/logic/schema.py +++ b/ckan/logic/schema.py @@ -196,11 +196,7 @@ def db_to_form_package_schema(): schema = default_package_schema() schema.update({ - 'tags': { - '__extras': [ckan.lib.navl.validators.keep_extras, - ckan.logic.converters.free_tags_only] - }, - }) + 'tags': {'__extras': [ckan.lib.navl.validators.keep_extras]}}) # Add several keys to the 'resources' subschema so they don't get stripped # from the resource dicts by validation.