refactor: add defineProps readonly
This commit is contained in:
parent
7bcdb26c4b
commit
57a32bdd04
2 changed files with 10 additions and 2 deletions
|
|
@ -4,7 +4,7 @@ import { SaveButton, UndoButton } from 'components/button';
|
||||||
|
|
||||||
import { VuePDF, usePDF } from '@tato30/vue-pdf';
|
import { VuePDF, usePDF } from '@tato30/vue-pdf';
|
||||||
|
|
||||||
const currentFileSelected = ref<string>('');
|
const currentFileSelected = ref<string>('citizenId');
|
||||||
const file = defineModel<
|
const file = defineModel<
|
||||||
{
|
{
|
||||||
group?: string;
|
group?: string;
|
||||||
|
|
@ -27,6 +27,7 @@ const currentIndexDropdownList = ref(0);
|
||||||
const props = withDefaults(
|
const props = withDefaults(
|
||||||
defineProps<{
|
defineProps<{
|
||||||
treeFile: { label: string; file: { label: string }[] }[];
|
treeFile: { label: string; file: { label: string }[] }[];
|
||||||
|
readonly?: boolean;
|
||||||
dropdownList?: { label: string; value: string }[];
|
dropdownList?: { label: string; value: string }[];
|
||||||
hideAction?: boolean;
|
hideAction?: boolean;
|
||||||
}>(),
|
}>(),
|
||||||
|
|
@ -101,7 +102,13 @@ const { pdf, pages } = usePDF(computed(() => currentFile.value?.url));
|
||||||
<div class="full-width row" stlye="min-height: 500px">
|
<div class="full-width row" stlye="min-height: 500px">
|
||||||
<div>
|
<div>
|
||||||
<div class="q-pa-sm text-center bordered" style="height: 50px">
|
<div class="q-pa-sm text-center bordered" style="height: 50px">
|
||||||
<q-btn-dropdown icon="mdi-upload" color="info" label="อัปโหลดเอกสาร">
|
<q-btn-dropdown
|
||||||
|
:disable="readonly"
|
||||||
|
icon="mdi-upload"
|
||||||
|
color="info"
|
||||||
|
label="อัปโหลดเอกสาร"
|
||||||
|
d
|
||||||
|
>
|
||||||
<q-list v-for="(v, i) in dropdownList" :key="v.value">
|
<q-list v-for="(v, i) in dropdownList" :key="v.value">
|
||||||
<q-item
|
<q-item
|
||||||
clickable
|
clickable
|
||||||
|
|
|
||||||
|
|
@ -172,6 +172,7 @@ defineProps<{
|
||||||
<q-tab-panel name="attachment">
|
<q-tab-panel name="attachment">
|
||||||
<UploadFile
|
<UploadFile
|
||||||
hide-action
|
hide-action
|
||||||
|
:readonly="readonly"
|
||||||
:dropdown-list="uploadFileListCustomer"
|
:dropdown-list="uploadFileListCustomer"
|
||||||
v-model:status-ocr="statusOcr"
|
v-model:status-ocr="statusOcr"
|
||||||
v-model:file="item.file"
|
v-model:file="item.file"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue