update image thumb
This commit is contained in:
@@ -19,6 +19,7 @@
|
||||
<section v-if="record" class="photo-panel">
|
||||
<photo-scroller
|
||||
:model-value="recordPhotoList"
|
||||
:photo-items="recordPhotoItemList"
|
||||
:show-add="false"
|
||||
:show-remove="false"
|
||||
title="登记照片"
|
||||
@@ -54,10 +55,12 @@ const record = ref<EventRecord>();
|
||||
const isLoading = ref(false);
|
||||
|
||||
const canUpdateRecord = computed(() => userStore.hasPermissions(permissionCodes.eventRecord.update));
|
||||
const recordPhotoList = computed(() => {
|
||||
const recordPhotoItemList = computed(() => {
|
||||
const url = getEventRecordPhotoURL(record.value);
|
||||
return url ? [url] : [];
|
||||
const thumbnailURL = getEventRecordPhotoURL(record.value, 64);
|
||||
return thumbnailURL ? [{ url: thumbnailURL, previewUrl: url }] : [];
|
||||
});
|
||||
const recordPhotoList = computed(() => recordPhotoItemList.value.map(item => item.url));
|
||||
|
||||
function getNumberValueText(value: EventRecord): string {
|
||||
return formatEventNumberValue(value.event, value.numberValue);
|
||||
|
||||
Reference in New Issue
Block a user