feat(file):add validateFileSize
This commit is contained in:
parent
c69c4c1fa8
commit
44487139ea
2 changed files with 28 additions and 2 deletions
|
|
@ -10,6 +10,7 @@ import { checkPermission } from "@/utils/permissions";
|
|||
import { useCounterMixin } from "@/stores/mixin";
|
||||
import { usePlacementDataStore } from "@/modules/05_placement/store";
|
||||
import { useMenuDataStore } from "@/stores/menuList";
|
||||
import { validateFileSize } from "@/utils/function";
|
||||
import avatar from "@/assets/avatar_user.jpg";
|
||||
|
||||
import type { PartialTableName } from "@/modules/05_placement/interface/request/placement";
|
||||
|
|
@ -1056,7 +1057,8 @@ onMounted(async () => {
|
|||
checkPermission($route)?.attrIsUpdate &&
|
||||
props.row.isDraft &&
|
||||
props.row.statusId === 'PREPARE-CONTAIN' &&
|
||||
(DataStore.isOfficer || checkPermission($route)?.attrOwnership == 'OWNER')
|
||||
(DataStore.isOfficer ||
|
||||
checkPermission($route)?.attrOwnership == 'OWNER')
|
||||
"
|
||||
clickable
|
||||
v-close-popup
|
||||
|
|
@ -1543,7 +1545,10 @@ onMounted(async () => {
|
|||
:label="`${'เลือกไฟล์เอกสารหลักฐาน'}`"
|
||||
outlined
|
||||
use-chips
|
||||
:rules="[(val:string) => !!val || 'กรุณาเลือกไฟล์เอกสารหลักฐาน']"
|
||||
:rules="[
|
||||
(val) => !!val || 'กรุณาเลือกไฟล์เอกสารหลักฐาน',
|
||||
(val) => validateFileSize(val),
|
||||
]"
|
||||
multiple
|
||||
@update:model-value="clickEditRow"
|
||||
class="q-py-sm"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue