Merge branch 'net' into development
This commit is contained in:
commit
cdd2a90d06
1 changed files with 12 additions and 11 deletions
|
|
@ -15,12 +15,13 @@ const props = withDefaults(
|
||||||
defineProps<{ action: boolean; viewMode: 'view_list' | 'view_module' }>(),
|
defineProps<{ action: boolean; viewMode: 'view_list' | 'view_module' }>(),
|
||||||
{
|
{
|
||||||
action: false,
|
action: false,
|
||||||
},
|
}
|
||||||
)
|
)
|
||||||
const DEPT_NAME = ['ตู้เอกสาร', 'ลิ้นชัก', 'แฟ้ม', 'แฟ้มย่อย'] as const
|
const DEPT_NAME = ['ตู้เอกสาร', 'ลิ้นชัก', 'แฟ้ม', 'แฟ้มย่อย'] as const
|
||||||
const { getFileInfo, getFileNameFormat } = useFileInfoStore()
|
const { getFileInfo, getFileNameFormat } = useFileInfoStore()
|
||||||
const { currentFolder, currentFile, currentDept, currentPath } =
|
const { currentFolder, currentFile, currentDept, currentPath } = storeToRefs(
|
||||||
storeToRefs(useTreeDataStore())
|
useTreeDataStore()
|
||||||
|
)
|
||||||
const {
|
const {
|
||||||
createFolder,
|
createFolder,
|
||||||
editFolder,
|
editFolder,
|
||||||
|
|
@ -37,8 +38,8 @@ const currentIcon = computed(() =>
|
||||||
currentDept.value === 0
|
currentDept.value === 0
|
||||||
? 'mdi-file-cabinet'
|
? 'mdi-file-cabinet'
|
||||||
: currentDept.value === 1
|
: currentDept.value === 1
|
||||||
? 'inbox'
|
? 'inbox'
|
||||||
: 'o_folder_open',
|
: 'o_folder_open'
|
||||||
)
|
)
|
||||||
|
|
||||||
const dialogDeleteState = ref<boolean>(false)
|
const dialogDeleteState = ref<boolean>(false)
|
||||||
|
|
@ -113,7 +114,7 @@ function triggerFileEdit(
|
||||||
keyword: string[]
|
keyword: string[]
|
||||||
category: string[]
|
category: string[]
|
||||||
},
|
},
|
||||||
pathname: string,
|
pathname: string
|
||||||
) {
|
) {
|
||||||
fileFormState.value = true
|
fileFormState.value = true
|
||||||
fileFormType.value = 'edit'
|
fileFormType.value = 'edit'
|
||||||
|
|
@ -137,7 +138,7 @@ async function submitFileForm(
|
||||||
keyword: string[]
|
keyword: string[]
|
||||||
category: string[]
|
category: string[]
|
||||||
},
|
},
|
||||||
force = false,
|
force = false
|
||||||
) {
|
) {
|
||||||
currentParam.value = value
|
currentParam.value = value
|
||||||
|
|
||||||
|
|
@ -169,7 +170,7 @@ async function submitFileForm(
|
||||||
keyword: value.keyword,
|
keyword: value.keyword,
|
||||||
category: value.category,
|
category: value.category,
|
||||||
},
|
},
|
||||||
value.file,
|
value.file
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
fileFormData.value = {}
|
fileFormData.value = {}
|
||||||
|
|
@ -183,7 +184,7 @@ async function submitFileForm(
|
||||||
{{ DEPT_NAME[currentDept] }}
|
{{ DEPT_NAME[currentDept] }}
|
||||||
</div>
|
</div>
|
||||||
<div class="grid q-mt-md">
|
<div class="grid q-mt-md">
|
||||||
<div v-for="value in currentFolder" key="value.name">
|
<div v-for="(value, index) in currentFolder" key="value.name">
|
||||||
<div
|
<div
|
||||||
:style="{
|
:style="{
|
||||||
position: 'relative',
|
position: 'relative',
|
||||||
|
|
@ -288,7 +289,7 @@ async function submitFileForm(
|
||||||
เอกสาร
|
เอกสาร
|
||||||
</div>
|
</div>
|
||||||
<div class="grid q-mt-md">
|
<div class="grid q-mt-md">
|
||||||
<div v-for="value,index in currentFile">
|
<div v-for="(value, index) in currentFile">
|
||||||
<div
|
<div
|
||||||
:style="{
|
:style="{
|
||||||
position: 'relative',
|
position: 'relative',
|
||||||
|
|
@ -324,7 +325,7 @@ async function submitFileForm(
|
||||||
keyword: value.keyword,
|
keyword: value.keyword,
|
||||||
category: value.category,
|
category: value.category,
|
||||||
},
|
},
|
||||||
value.pathname,
|
value.pathname
|
||||||
)
|
)
|
||||||
"
|
"
|
||||||
@delete="() => triggerFileDelete(value.pathname)"
|
@delete="() => triggerFileDelete(value.pathname)"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue