diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 414ad7f..5837125 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -15,6 +15,15 @@ Unreleased ********** +[0.1.9] - 2024-03-20 +************************************************ + +Changed +======= + +* Pass course key as query param to taxonomy skills api + + [0.1.8] - 2024-03-14 ************************************************ diff --git a/skill_tagging/__init__.py b/skill_tagging/__init__.py index 73731e5..c4d5ee8 100644 --- a/skill_tagging/__init__.py +++ b/skill_tagging/__init__.py @@ -2,7 +2,7 @@ Django app plugin for fetching and verifying tags for xblock skills. """ -__version__ = '0.1.8' +__version__ = '0.1.9' # pylint: disable=invalid-name default_app_config = 'skill_tagging.apps.SkillTaggingConfig' diff --git a/skill_tagging/skill_tagging_mixin.py b/skill_tagging/skill_tagging_mixin.py index 5c1ac99..0b14755 100644 --- a/skill_tagging/skill_tagging_mixin.py +++ b/skill_tagging/skill_tagging_mixin.py @@ -68,7 +68,11 @@ def fetch_skill_tags(self): user = user_service.get_user_by_anonymous_id() api_client = get_api_client(user=user) + course_key_str = str(self.scope_ids.usage_id.context_key) usage_id_str = str(self.scope_ids.usage_id) + LOGGER.info( + f"[XBLOCK_SKILL_TAGGING] Fetching Skills. XBlock: [{usage_id_str}], Course: [{course_key_str}]." + ) XBLOCK_SKILL_TAGS_API = urljoin( settings.TAXONOMY_API_BASE_URL, '/taxonomy/api/v1/xblocks/' @@ -76,6 +80,7 @@ def fetch_skill_tags(self): response = api_client.get( XBLOCK_SKILL_TAGS_API, params={ + "course_key": course_key_str, "usage_key": usage_id_str, "page_size": PAGE_SIZE, "verified": False, diff --git a/skill_tagging/static/tags_form.html b/skill_tagging/static/tags_form.html index a946c0b..7313309 100644 --- a/skill_tagging/static/tags_form.html +++ b/skill_tagging/static/tags_form.html @@ -4,7 +4,6 @@

{% translate "What did you learn?" %}

{% if block_type == 'vertical' %} - {% translate "Congratulations, you've reached the end of this unit!" %}
{% translate "Help future students by selecting the skills or subjects you learned from this unit." %} {% elif block_type == 'video' %} {% translate "Help future students by selecting the skills or subjects you learned from this video." %}