diff --git a/components/dynamic-page/page-component/templates/articles/individuals/Card.vue b/components/dynamic-page/page-component/templates/articles/individuals/Card.vue
index bac430b..3750238 100644
--- a/components/dynamic-page/page-component/templates/articles/individuals/Card.vue
+++ b/components/dynamic-page/page-component/templates/articles/individuals/Card.vue
@@ -55,7 +55,7 @@ const drop = (e: any) => {
-
+
{{ parseData.title?.replace(/<[^>]+>/g, '') }}
diff --git a/pages/bai-viet/[slug].vue b/pages/bai-viet/[slug].vue
index d736189..33876eb 100644
--- a/pages/bai-viet/[slug].vue
+++ b/pages/bai-viet/[slug].vue
@@ -23,7 +23,7 @@ const store = reactive({
(async () => {
try {
- store.article.getArticleById(route.params.slug);
+ store.article.getArticleBySlug(route.params.slug);
} catch (error) {
console.error("Error fetching data:", error);
}
diff --git a/stores/articles.ts b/stores/articles.ts
index 0c1523e..1853b64 100644
--- a/stores/articles.ts
+++ b/stores/articles.ts
@@ -10,7 +10,7 @@ export const useArticleStore = defineStore("article", () => {
} catch (error: any) {}
}
- const getArticleByCode = async (slug: string) => {
+ const getArticleBySlug = async (slug: string) => {
try {
const { data} = await useFetch(`/api/articles/get-by-slug/${slug}`)
currentArticle.value = {}
@@ -21,7 +21,7 @@ export const useArticleStore = defineStore("article", () => {
return {
currentArticle,
getArticleById,
- getArticleByCode
+ getArticleBySlug
}
});