thainv-dev: page chi tiết
This commit is contained in:
+3
-2
@@ -3,9 +3,10 @@ export const useArticleStore = defineStore("article", () => {
|
||||
|
||||
const getArticleById = async (id: string | number) => {
|
||||
try {
|
||||
const { data } = await useFetch(`/api/articles/get-by-id/${id}`)
|
||||
|
||||
const { data} = await useFetch(`/api/articles/get-by-id/${id}`)
|
||||
currentArticle.value = {}
|
||||
currentArticle.value = data.value
|
||||
currentArticle.value = data.value.item
|
||||
} catch (error: any) {}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user