|
|
@ -41,11 +41,11 @@ |
|
|
|
/> |
|
|
|
<div v-if="isBasic && tabsExtend == 1"> |
|
|
|
<el-form ref="imageFormRef" :model="imageFormData" :key="formKey"> |
|
|
|
<el-form-item label="文件上传"> |
|
|
|
<el-form-item label=""> |
|
|
|
<UploadImgs v-model="imageFormData.filePathList" /> |
|
|
|
</el-form-item> |
|
|
|
</el-form> |
|
|
|
<el-button type="primary" @click="uploadImage">点击修改</el-button> |
|
|
|
<el-button type="primary" @click="uploadImage">提交</el-button> |
|
|
|
</div> |
|
|
|
<div v-if="isBasic && tabsExtend == 2"> |
|
|
|
<el-tabs class="demo-tabs" v-model="imageParmas.fileBusiType" @tab-change="handleTabsChange"> |
|
|
@ -57,11 +57,11 @@ |
|
|
|
/> |
|
|
|
</el-tabs> |
|
|
|
<el-form ref="fileFormRef" :model="fileFormData" :key="formKey"> |
|
|
|
<el-form-item label="文件上传"> |
|
|
|
<el-form-item label=""> |
|
|
|
<UploadFile v-model="fileFormData.filePathList" :limit="20" /> |
|
|
|
</el-form-item> |
|
|
|
</el-form> |
|
|
|
<el-button type="primary" @click="uploadFile">点击修改</el-button> |
|
|
|
<el-button type="primary" @click="uploadFile">提交</el-button> |
|
|
|
</div> |
|
|
|
<!-- 单表切换tabs 展现table --> |
|
|
|
<Table |
|
|
@ -197,7 +197,7 @@ |
|
|
|
:key="dialogFormKey" |
|
|
|
> |
|
|
|
<el-form ref="fileDialogUploadRef" :model="fileDialogUploadData" > |
|
|
|
<el-form-item label="文件选择"> |
|
|
|
<el-form-item label=""> |
|
|
|
<UploadFile v-model="fileDialogUploadData.filePathList" :limit="20" /> |
|
|
|
</el-form-item> |
|
|
|
</el-form> |
|
|
@ -598,7 +598,6 @@ defineExpose({ openDetail }) // 提供 open 方法,用于打开弹窗 |
|
|
|
// 获取图片详情 |
|
|
|
const formKey = ref(0) |
|
|
|
const getImage = () => { |
|
|
|
fileApi.selectList().then((response) => { |
|
|
|
props |
|
|
|
.getImageApi({ |
|
|
|
number: masterParmas.value.number, |
|
|
@ -611,23 +610,14 @@ const getImage = () => { |
|
|
|
imageFormData.value.filePathList = res |
|
|
|
} else { |
|
|
|
console.log(444,res) |
|
|
|
fileFormData.value.filePathList = res.map(item=>{ |
|
|
|
response.forEach(element=>{ |
|
|
|
if(item.url == element.url){ |
|
|
|
item.name = element.name |
|
|
|
} |
|
|
|
}) |
|
|
|
return item |
|
|
|
}) |
|
|
|
fileFormData.value.filePathList = res |
|
|
|
formKey.value += 1 |
|
|
|
} |
|
|
|
}) |
|
|
|
}) |
|
|
|
}) |
|
|
|
} |
|
|
|
|
|
|
|
const getImageDialog = () => { |
|
|
|
fileApi.selectList().then((response) => { |
|
|
|
props |
|
|
|
.getImageApi({ |
|
|
|
number: masterParmas.value.number, |
|
|
@ -640,19 +630,11 @@ const getImageDialog = () => { |
|
|
|
imageFormData.value.filePathList = res |
|
|
|
} else { |
|
|
|
console.log(444,res) |
|
|
|
fileDialogUploadData.value.filePathList = res.map(item=>{ |
|
|
|
response.forEach(element=>{ |
|
|
|
if(item.url == element.url){ |
|
|
|
item.name = element.name |
|
|
|
} |
|
|
|
}) |
|
|
|
return item |
|
|
|
}) |
|
|
|
fileDialogUploadData.value.filePathList = res |
|
|
|
formKey.value += 1 |
|
|
|
} |
|
|
|
}) |
|
|
|
}) |
|
|
|
}) |
|
|
|
} |
|
|
|
|
|
|
|
const tableObjectRef = ref() |
|
|
@ -818,6 +800,7 @@ const uploadImage = async () => { |
|
|
|
// if (!valid) return |
|
|
|
let data = { |
|
|
|
number: masterParmas.value.number, |
|
|
|
fileInfoList: imageFormData.value.filePathList, |
|
|
|
filePathList: imageFormData.value.filePathList.map((item) => item.url), |
|
|
|
funcCode: imageParmas.value.funcCode, |
|
|
|
fileBusiType: imageParmas.value.fileBusiType ? imageParmas.value.fileBusiType : '' |
|
|
@ -844,6 +827,7 @@ const uploadFile = async () => { |
|
|
|
// console.log(fileFormRef.value?.formModel.filePathList) |
|
|
|
let data = { |
|
|
|
number: masterParmas.value.number, |
|
|
|
fileInfoList: fileFormData.value.filePathList, |
|
|
|
filePathList: fileFormData.value.filePathList.map((item) => item.url), |
|
|
|
funcCode: imageParmas.value.funcCode, |
|
|
|
fileBusiType: imageParmas.value.fileBusiType ? imageParmas.value.fileBusiType : '' |
|
|
@ -1001,6 +985,7 @@ function dialogUploadFile() { |
|
|
|
let data = { |
|
|
|
number: dialogUploadNumber.value, |
|
|
|
filePathList: fileDialogUploadData.value.filePathList.map((item) => item.url), |
|
|
|
fileInfoList: fileDialogUploadData.value.filePathList, |
|
|
|
funcCode: props.milestoneFuncCode, |
|
|
|
fileBusiType: dialogUploadBusiCode.value |
|
|
|
} |
|
|
|