refactor: click file 2 preview & clean search comp
This commit is contained in:
parent
37b8f64027
commit
43d009c35e
5 changed files with 191 additions and 9 deletions
|
|
@ -4,7 +4,10 @@ import { storeToRefs } from 'pinia'
|
|||
|
||||
import FileItemAction from '@/components/FileItemAction.vue'
|
||||
import { useTreeDataStore } from '@/stores/tree-data'
|
||||
import { useFileInfoStore } from '@/stores/file-info-data'
|
||||
|
||||
const { isPreview } = storeToRefs(useFileInfoStore())
|
||||
const { getFileInfo } = useFileInfoStore()
|
||||
const DEPT_NAME = ['ตู้เอกสาร', 'ลิ้นชัก', 'แฟ้ม', 'แฟ้มย่อย']
|
||||
|
||||
const { currentFolder, currentFile, currentDept } = storeToRefs(
|
||||
|
|
@ -113,9 +116,21 @@ const props = withDefaults(
|
|||
</div>
|
||||
<div class="q-mt-md">
|
||||
<div class="q-gutter-md">
|
||||
<div v-for="value in currentFile" :key="value.title" class="inline-block">
|
||||
<div
|
||||
v-for="(value, index) in currentFile"
|
||||
:key="value.title"
|
||||
class="inline-block"
|
||||
>
|
||||
<div class="box border-radius-inherit">
|
||||
<q-card flat @click="">
|
||||
<q-card
|
||||
flat
|
||||
@click="
|
||||
() => {
|
||||
getFileInfo(currentFile[index])
|
||||
isPreview = true
|
||||
}
|
||||
"
|
||||
>
|
||||
<q-card-section class="column justify-center relative q-px-xl">
|
||||
<q-icon name="description" size="6em" color="primary" />
|
||||
<div
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue