|
@@ -151,7 +151,7 @@
|
|
|
</el-col>
|
|
|
<el-col :span="24">
|
|
|
<el-form-item label="凭证附件:" required>
|
|
|
- <dragUpload :accept="accept" style="width:100%" @file="upload"
|
|
|
+ <!-- <dragUpload :accept="accept" style="width:100%" @file="upload"
|
|
|
v-if="form.files == null || form.files == ''" />
|
|
|
<img v-else style="height: 148px; width: 148px" :src="`${baseUrl}/${form.files[0].fileUrl}`"
|
|
|
class="avatar" @click="openEvidience('files[0]')" />
|
|
@@ -160,8 +160,8 @@
|
|
|
@click="form.files = []" class="delete-button">
|
|
|
<Delete />
|
|
|
</el-icon>
|
|
|
- </div>
|
|
|
- <!-- <div class="details-btns-container" style="display: flex">
|
|
|
+ </div> -->
|
|
|
+ <div class="details-btns-container" style="display: flex">
|
|
|
<el-upload action="#" :http-request="upload" :with-credentials="true" :show-file-list="false" multiple>
|
|
|
<el-button size="small" type="primary" icon="Upload">点击上传</el-button>
|
|
|
</el-upload>
|
|
@@ -181,7 +181,7 @@
|
|
|
<el-button link size="small" type="danger" @click="handleDelFile(scope.$index)">删除</el-button>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- </el-table> -->
|
|
|
+ </el-table>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
</el-row>
|
|
@@ -519,9 +519,25 @@
|
|
|
});
|
|
|
}
|
|
|
|
|
|
+ // function upload(param) {
|
|
|
+ // const formData = new FormData();
|
|
|
+ // formData.append("file", param);
|
|
|
+ // uploadFile(formData).then((res) => {
|
|
|
+ // if (res.code === 200) {
|
|
|
+ // const file = {};
|
|
|
+ // file.fileName = res.newFileName;
|
|
|
+ // file.url = res.url;
|
|
|
+ // file.originalFileName = res.originalFilename;
|
|
|
+ // file.fileUrl = res.fileName;
|
|
|
+ // file.masterId = form.value.id;
|
|
|
+ // file.masterTableName = "biz_deduction";
|
|
|
+ // form.value.files.push(file);
|
|
|
+ // }
|
|
|
+ // });
|
|
|
+ // }
|
|
|
function upload(param) {
|
|
|
const formData = new FormData();
|
|
|
- formData.append("file", param);
|
|
|
+ formData.append("file", param.file);
|
|
|
uploadFile(formData).then((res) => {
|
|
|
if (res.code === 200) {
|
|
|
const file = {};
|
|
@@ -535,7 +551,6 @@
|
|
|
}
|
|
|
});
|
|
|
}
|
|
|
-
|
|
|
function openFollowFile(arg) {
|
|
|
// console.log(arg)
|
|
|
const attach = arg;
|