From e2bc4edf394f0908613d15241e17b15e3ff4d131 Mon Sep 17 00:00:00 2001 From: Cristhian Garcia Date: Mon, 9 Sep 2024 11:20:53 -0500 Subject: [PATCH] feat: unify problem link and display name --- models/problems/fact_problem_responses.sql | 4 +--- models/problems/int_problem_results.sql | 3 +-- models/problems/schema.yml | 6 ------ models/problems/section_problem_engagement.sql | 4 +--- models/problems/subsection_problem_engagement.sql | 4 +--- 5 files changed, 4 insertions(+), 17 deletions(-) diff --git a/models/problems/fact_problem_responses.sql b/models/problems/fact_problem_responses.sql index 419a2474..1f34d9e2 100644 --- a/models/problems/fact_problem_responses.sql +++ b/models/problems/fact_problem_responses.sql @@ -23,8 +23,7 @@ select blocks.course_run as course_run, responses.problem_id as problem_id, blocks.block_name as problem_name, - blocks.display_name_with_location as problem_name_with_location, - {{ a_tag("responses.object_id", "blocks.block_name") }} as problem_link, + {{ a_tag("responses.object_id", "blocks.display_name_with_location") }} as problem_name_with_location, blocks.graded as graded, course_order as course_order, responses.actor_id as actor_id, @@ -55,7 +54,6 @@ group by problem_id, problem_name, problem_name_with_location, - problem_link, actor_id, responses, success, diff --git a/models/problems/int_problem_results.sql b/models/problems/int_problem_results.sql index b708eab0..10b9d376 100644 --- a/models/problems/int_problem_results.sql +++ b/models/problems/int_problem_results.sql @@ -31,9 +31,8 @@ select blocks.course_run as course_run, full_responses.problem_id as problem_id, blocks.block_name as problem_name, - blocks.display_name_with_location as problem_name_with_location, + {{ a_tag("full_responses.object_id", "blocks.display_name_with_location") }} as problem_name_with_location, blocks.course_order as course_order, - {{ a_tag("full_responses.object_id", "blocks.block_name") }} as problem_link, full_responses.actor_id as actor_id, full_responses.responses as responses, full_responses.success as success, diff --git a/models/problems/schema.yml b/models/problems/schema.yml index 2c49d727..2ccb8948 100644 --- a/models/problems/schema.yml +++ b/models/problems/schema.yml @@ -28,9 +28,6 @@ models: - name: problem_name_with_location data_type: String description: "The problem's display name with section, subsection, and unit prepended to the name. This provides additional context when looking at problem names and can help data consumers understand which problem they are analyzing" - - name: problem_link - data_type: String - description: "An anchor tag with a link to the problem" - name: graded data_type: Bool description: "Whether the block is graded" @@ -129,9 +126,6 @@ models: - name: problem_name_with_location data_type: String description: "The problem's display name with section, subsection, and unit prepended to the name. This provides additional context when looking at problem names and can help data consumers understand which problem they are analyzing" - - name: problem_link - data_type: String - description: "An anchor tag with a link to the problem" - name: actor_id data_type: String description: "The xAPI actor identifier" diff --git a/models/problems/section_problem_engagement.sql b/models/problems/section_problem_engagement.sql index fbb968fb..bf9de838 100644 --- a/models/problems/section_problem_engagement.sql +++ b/models/problems/section_problem_engagement.sql @@ -32,8 +32,7 @@ with blocks.course_name as course_name, responses.problem_id as problem_id, blocks.block_name as problem_name, - blocks.display_name_with_location as problem_name_with_location, - {{ a_tag("responses.object_id", "blocks.block_name") }} as problem_link, + {{ a_tag("responses.object_id", "blocks.display_name_with_location") }} as problem_name_with_location, blocks.graded as graded, course_order as course_order, responses.actor_id as actor_id, @@ -60,7 +59,6 @@ with problem_id, problem_name, problem_name_with_location, - problem_link, actor_id, responses, success, diff --git a/models/problems/subsection_problem_engagement.sql b/models/problems/subsection_problem_engagement.sql index 14c9f3cb..1dc2f7f4 100644 --- a/models/problems/subsection_problem_engagement.sql +++ b/models/problems/subsection_problem_engagement.sql @@ -32,8 +32,7 @@ with blocks.course_name as course_name, responses.problem_id as problem_id, blocks.block_name as problem_name, - blocks.display_name_with_location as problem_name_with_location, - {{ a_tag("responses.object_id", "blocks.block_name") }} as problem_link, + {{ a_tag("responses.object_id", "blocks.display_name_with_location") }} as problem_name_with_location, blocks.graded as graded, course_order as course_order, responses.actor_id as actor_id, @@ -60,7 +59,6 @@ with problem_id, problem_name, problem_name_with_location, - problem_link, actor_id, responses, success,