ปรับเมนู และเพิ่ม UI ผลงาน

This commit is contained in:
Warunee Tamkoo 2024-06-27 14:59:54 +07:00
parent b53765a469
commit 38aa872064
11 changed files with 609 additions and 74 deletions

View file

@ -99,13 +99,13 @@ const fecthDataTransfer = async (id: string) => {
};
/**
* งกนดาวโหลดอโหลดไฟล
* งกนดาวโหลดอโหลดไฟล
*/
const fileDocDataUpload = ref<File[]>([]);
const filesNull = () => {
files.value = null;
};
//
//
const fileUploadDoc = async (file: any) => {
fileDocDataUpload.value.push(file);
nameFile.value = file[0].name;
@ -178,25 +178,12 @@ function fileOpen(url: string) {
lazy-rules
hide-bottom-space
accept=".pdf"
:rules="[
(val) => !!val || 'กรุณากรอกอัพโหลดเอกสารเพิ่มเติม',
]"
:rules="[(val: string) => !!val || 'กรุณาเลือกไฟล์เอกสารเพิ่มเติม']"
label="เอกสารเพิ่มเติม"
>
<template v-slot:prepend>
<q-icon name="attach_file" /> </template
></q-file>
<!-- <q-uploader
bordered
flat
class="col-12"
accept=".jpg,.png,.pdf,.csv,.doc"
url="http://localhost:4444/upload"
label="เอกสารเพิ่มเติม"
type="file"
@added="fileUploadDoc"
@removed="filesNull"
/> -->
</div>
<div class="col-12 row" v-if="routeName != 'addTransfer'">
<q-card bordered flat class="full-width">
@ -209,10 +196,7 @@ function fileOpen(url: string) {
</div>
<q-separator />
<q-list separator>
<q-item
v-for="file in files"
:key="file.key"
>
<q-item v-for="file in files" :key="file.key">
<q-item-section>
{{ file.fileName }}
</q-item-section>