|
|
@@ -92,7 +92,7 @@
|
|
|
fit="cover"
|
|
|
class="record-image"
|
|
|
:preview-src-list="changeRecordList.map(record => record.imgUrl)"
|
|
|
- :initial-index="index"
|
|
|
+ :initial-index="Number(index)"
|
|
|
>
|
|
|
<template #error>
|
|
|
<div class="image-slot">
|
|
|
@@ -128,8 +128,7 @@ import {
|
|
|
uploadContractImage,
|
|
|
submitEntertainmentLicenseReview,
|
|
|
getEntertainmentChangeRecords,
|
|
|
- getStoreEntertainmentLicenceStatus,
|
|
|
- ocrRequestUrl
|
|
|
+ getStoreEntertainmentLicenceStatus
|
|
|
} from "@/api/modules/licenseManagement";
|
|
|
import { localGet } from "@/utils";
|
|
|
|
|
|
@@ -435,47 +434,6 @@ const uploadSingleFile = async (file: UploadFile) => {
|
|
|
if (!imageUrlList.value.includes(imageUrl)) {
|
|
|
imageUrlList.value.push(imageUrl);
|
|
|
}
|
|
|
-
|
|
|
- // 图片上传成功后调用 OCR 接口进行识别校验(其他资质证明)
|
|
|
- try {
|
|
|
- const params = {
|
|
|
- imageUrls: imageUrl,
|
|
|
- ocrType: "BUSINESS_LICENSE",
|
|
|
- storeId: userInfo.storeId,
|
|
|
- storeUserId: userInfo.id
|
|
|
- };
|
|
|
- const res: any = await ocrRequestUrl(params);
|
|
|
- if (res.code == 200) {
|
|
|
- ElMessage.success("识别成功");
|
|
|
- } else {
|
|
|
- // OCR 识别失败:提示并删除当前图片
|
|
|
- ElMessage.error(res?.msg || "识别失败,请重试");
|
|
|
- const index = fileList.value.findIndex((f: any) => f.uid === file.uid);
|
|
|
- if (index > -1) {
|
|
|
- fileList.value.splice(index, 1);
|
|
|
- }
|
|
|
- const urlIndex = imageUrlList.value.indexOf(imageUrl);
|
|
|
- if (urlIndex > -1) {
|
|
|
- imageUrlList.value.splice(urlIndex, 1);
|
|
|
- }
|
|
|
- if (file.url && file.url.startsWith("blob:")) {
|
|
|
- URL.revokeObjectURL(file.url);
|
|
|
- }
|
|
|
- }
|
|
|
- } catch (error) {
|
|
|
- // 调用接口异常时:提示并删除当前图片
|
|
|
- const index = fileList.value.findIndex((f: any) => f.uid === file.uid);
|
|
|
- if (index > -1) {
|
|
|
- fileList.value.splice(index, 1);
|
|
|
- }
|
|
|
- const urlIndex = imageUrlList.value.indexOf(imageUrl);
|
|
|
- if (urlIndex > -1) {
|
|
|
- imageUrlList.value.splice(urlIndex, 1);
|
|
|
- }
|
|
|
- if (file.url && file.url.startsWith("blob:")) {
|
|
|
- URL.revokeObjectURL(file.url);
|
|
|
- }
|
|
|
- }
|
|
|
} else {
|
|
|
throw new Error(result?.msg || "图片上传失败");
|
|
|
}
|
|
|
@@ -620,7 +578,7 @@ const handleSubmitReplace = async () => {
|
|
|
uploading.value = false;
|
|
|
await initData();
|
|
|
} catch (error) {
|
|
|
- ElMessage.error("提交审核失败");
|
|
|
+ // ElMessage.error("提交审核失败");
|
|
|
}
|
|
|
};
|
|
|
|