新增角色模板优化店铺装修
This commit is contained in:
@@ -15,11 +15,11 @@
|
||||
<el-icon><zoom-in /></el-icon>
|
||||
</span>
|
||||
<!-- 删除 -->
|
||||
<!-- <span @click="handleRemove(file.url!)">
|
||||
<span @click="handleRemove(file.url!)">
|
||||
<el-icon>
|
||||
<Delete />
|
||||
</el-icon>
|
||||
</span> -->
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
</template>
|
||||
@@ -87,14 +87,20 @@ const fileList = ref<UploadUserFile[]>([]);
|
||||
* 删除图片
|
||||
*/
|
||||
function handleRemove(imageUrl: string) {
|
||||
FileAPI.delete(imageUrl).then(() => {
|
||||
const index = modelValue.value.indexOf(imageUrl);
|
||||
if (index !== -1) {
|
||||
// 直接修改数组避免触发整体更新
|
||||
modelValue.value.splice(index, 1);
|
||||
fileList.value.splice(index, 1); // 同步更新 fileList
|
||||
}
|
||||
});
|
||||
// FileAPI.delete(imageUrl).then(() => {
|
||||
// const index = modelValue.value.indexOf(imageUrl);
|
||||
// if (index !== -1) {
|
||||
// // 直接修改数组避免触发整体更新
|
||||
// modelValue.value.splice(index, 1);
|
||||
// fileList.value.splice(index, 1); // 同步更新 fileList
|
||||
// }
|
||||
// });
|
||||
const index = modelValue.value.indexOf(imageUrl);
|
||||
if (index !== -1) {
|
||||
// 直接修改数组避免触发整体更新
|
||||
modelValue.value.splice(index, 1);
|
||||
fileList.value.splice(index, 1); // 同步更新 fileList
|
||||
}
|
||||
}
|
||||
function handleProgress(event: any, file: any, fileList: any) {
|
||||
// console.log("handleProgress", evt, file, fileList);
|
||||
|
||||
Reference in New Issue
Block a user