Skip to content

Commit

Permalink
add strict tag filtering
Browse files Browse the repository at this point in the history
  • Loading branch information
ElectronicBlueberry committed Oct 26, 2023
1 parent 2d64ef1 commit b082a12
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions client/src/components/Tool/ToolHelpForum.vue
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ const props = defineProps<{
toolName: string;
}>();
const toolHelpTag = "tool-help";
const helpFetcher = fetcher.path("/api/help/forum/search").method("get").create();
const topics = ref<HelpForumTopic[]>([]);
Expand All @@ -24,7 +26,7 @@ const helpAvailable = computed(() => topics.value.length > 0);
const root = ref(null);
const query = computed(() => `${props.toolName} min_posts:2`);
const query = computed(() => `tag:${props.toolId} tag:${toolHelpTag}`);
onMounted(async () => {
const response = await helpFetcher({ query: query.value });
Expand All @@ -47,7 +49,7 @@ function blurbForTopic(topicId: number): string {
const { createNewTopicUrl, searchTopicUrl } = useHelpURLs({
title: computed(() => props.toolName),
tags: computed(() => [props.toolId]),
tags: computed(() => [props.toolId, toolHelpTag]),
query,
});
Expand Down

0 comments on commit b082a12

Please sign in to comment.