Browse Source

基础信息删除图片

15591641157 2 tháng trước cách đây
mục cha
commit
322213d71b
1 tập tin đã thay đổi với 4 bổ sung0 xóa
  1. 4 0
      packages/merchant/src/components/data-form.vue

+ 4 - 0
packages/merchant/src/components/data-form.vue

@@ -255,6 +255,10 @@ defineExpose({
   const existingUrls = modelValue[prop]?.split(',') ?? [];
   modelValue[prop] = [...existingUrls, ...newUrls].join(',');
 }"
+            :before-remove="({file,fileList,resolve}) =>{
+              resolve(true)
+              modelValue[prop] = fileList.map(({ url }) => url).join(',');
+            }"
           ></wd-upload>
           <wd-button
             v-if="type === 'Submit'"