refactor: clean code and handle

This commit is contained in:
puri-ph4tt 2023-11-28 09:22:44 +07:00 committed by Methapon2001
parent aa63e9c8c5
commit e682485bce
No known key found for this signature in database
GPG key ID: 849924FEF46BD132
3 changed files with 40 additions and 28 deletions

View file

@ -20,16 +20,10 @@ const { getFolder, createFolder, editFolder, uploadFile } = useTreeDataStore()
const drawer = ref<boolean>(false)
const drawerFile = ref<boolean>(false)
const drawerStatus = ref<'edit' | 'create'>('create')
const input = ref<string>('')
const inputFile = ref<File>()
const fileTitle = ref<string>('')
const fileDesc = ref<string>('')
const fileCategory = ref<string>('')
const optionsCategory = [
{ label: 'ศิลปะ', value: 'art' },
{ label: 'ภาพวาด', value: 'drawing' },
{ label: 'ภาษาไทย', value: 'thai' },
]
const fileKeyword = ref<string>('')
const editPathname = ref<string>('')
@ -181,7 +175,7 @@ async function handleSubmit() {
>
<q-card-section class="column justify-center relative q-px-xl">
<q-icon
name="description"
name="mdi-file"
class="add-icon"
size="6em"
color="primary"
@ -259,10 +253,9 @@ async function handleSubmit() {
dense
/>
<span class="text-weight-bold">กล/หมวดหม</span>
<q-select
<q-input
class="q-my-md"
outlined
:options="optionsCategory"
v-model="fileCategory"
placeholder="เลือกกลุ่ม/หมวดหมู่"
dense