-
Notifications
You must be signed in to change notification settings - Fork 282
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
7858d30
commit c3f9fab
Showing
5 changed files
with
54 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
<template> | ||
<div class="p-5 px-10 w-full overflow-scroll items-center"> | ||
<LayoutHeader> | ||
<template #left-header> | ||
<div class="text-lg font-medium text-gray-900">Knowledge base</div> | ||
</template> | ||
</LayoutHeader> | ||
<div class="max-w-4xl pt-4 sm:px-5 w-full flex flex-col gap-2"> | ||
{{ categoryId }} | ||
</div> | ||
<div v-if="articles.data" class="text-wrap flex-1"> | ||
{{ articles.data }} | ||
</div> | ||
</div> | ||
</template> | ||
|
||
<script setup lang="ts"> | ||
import { createListResource } from "frappe-ui"; | ||
import LayoutHeader from "@/components/LayoutHeader.vue"; | ||
const props = defineProps({ | ||
categoryId: { | ||
required: true, | ||
type: String, | ||
}, | ||
}); | ||
const articles = createListResource({ | ||
doctype: "HD Article", | ||
fields: ["author", "title", "modified"], | ||
filters: { | ||
category: props.categoryId, | ||
status: "Published", | ||
}, | ||
auto: true, | ||
}); | ||
</script> | ||
|
||
<style scoped></style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters