Merge branch 'phatt' into development

This commit is contained in:
puri-ph4tt 2023-12-26 15:06:29 +07:00
commit 9e574450e2
4 changed files with 26 additions and 20 deletions

View file

@ -17,19 +17,6 @@ const optionsOp = [
]
const props = defineProps<{
submitSearch: Function
submitSearchData: {
AND: {
field: string
value: string
exact?: boolean
}[]
OR: {
field: string
value: string
exact?: boolean
}[]
exact?: boolean
}
}>()
function addAdvSearchData() {

View file

@ -145,6 +145,15 @@ async function downloadSubmit(path: string | undefined) {
</div>
</div>
<q-separator />
<div class="row">
<div class="col-12 col-md-3">
<span>เขยน</span>
</div>
<div class="col-grow">
<span class="text-grey">{{ fileInfo?.author }}</span>
</div>
</div>
<q-separator />
<div class="row">
<div class="col-12 col-md-3">
<span>กล/หมวดหม</span>

View file

@ -31,9 +31,18 @@ const optionsField = [
{ label: 'หมวดหมู่ (category)', value: 'category' },
{ label: 'เนื้อหาในไฟล์ (content)', value: 'attachment.content' },
]
const submitSearchData = ref<
InstanceType<typeof AdvancedSearch>['submitSearchData']
>({
const submitSearchData = ref<{
AND: {
field: string
value: string
exact?: boolean
}[]
OR: {
field: string
value: string
exact?: boolean
}[]
}>({
AND: [],
OR: [],
})
@ -211,7 +220,6 @@ watch(
<div class="col-grow">
<advanced-search
:submitSearch="submitSearch"
:submit-search-data="submitSearchData"
/>
</div>
<div v-if="isAdvSearchCall === false">

View file

@ -26,6 +26,8 @@ export interface StorageFile {
fileType: string
title: string
description: string
author: string,
metadata: Record<string, unknown>
category: string[]
keyword: string[]
updatedAt: string
@ -439,9 +441,9 @@ const useStorage = defineStore('storageStore', () => {
},
to: file?.name
? {
file: file.name,
path: arr,
}
file: file.name,
path: arr,
}
: undefined,
upload: !!file,
},