调整检验报告

ywj_dev
wangwei 2 years ago
parent 4ffa5747ae
commit 0788934cc7

@ -127,7 +127,7 @@
<el-row>
<el-col :span="3">
<div class="ao-text">
<span>检验报告</span>
<span>检验报告上传</span>
</div>
</el-col>
<el-col :span="8">
@ -159,13 +159,13 @@
</el-col>
<el-col :span="3">
<div class="ao-text" v-if="this.inputQuery.filePath!=null">
<span>预览</span>
<span>检验报告预览</span>
</div>
</el-col>
<el-col :span="8">
<el-button type="primary" size="mini" icon="search" v-if="this.inputQuery.filePath!=null"
style="text-align:right" @click="showImgViewer" >
文件预览
检验报告预览
</el-button>
<el-image-viewer v-if="imgViewerVisible" style="z-index:9999" :on-close="closeImgViewer" :url-list="imgList"/>
</el-col>
@ -199,6 +199,10 @@ export default {
type: Object,
required: true,
},
checkFileName: {
type: Object,
required: true,
},
},
@ -305,6 +309,7 @@ export default {
this.$message.warning(`当前限制选择 1 个文件,本次选择了 ${files.length} 个文件,共选择了 ${files.length + fileList.length} 个文件`);
},
uploadOnchange(file, fileList) {
this.inputQuery.checkFileName=file.name;
let fileName = file.name;
let uid = file.uid
let pos = fileName.lastIndexOf(".");
@ -387,10 +392,10 @@ export default {
this.formData = this.inputQuery.formData;
console.log(this.inputQuery.formData);
}
if (this.formData.filePath != null) {
this.choiceFile = "更换文件";
if (this.inputQuery.filePath != null) {
this.choiceFile = "更换检验报告";
} else {
this.choiceFile = "选取文件";
this.choiceFile = "选取检验报告";
}
},
};

@ -158,6 +158,8 @@
</el-table-column>
<el-table-column label="收货仓库" prop="invName" width="120">
</el-table-column>
<el-table-column label="审核人" prop="reviewUserName" width="120">
</el-table-column>
<el-table-column label="来源单号" prop="corpOrderId" show-overflow-tooltip width="180"></el-table-column>
<el-table-column label="来源" prop="fromType" width="120">
<template slot-scope="scope">
@ -314,8 +316,17 @@
prop="certCode" width="180"
show-overflow-tooltip
></el-table-column>
<el-table-column label="操作">
<el-table-column
label="检验报告"
width="160"
prop="checkFileName"
show-overflow-tooltip
>
<template slot-scope="scope">
<div style="color: #1890ff;" @click="showImgViewer(scope.row)">{{ scope.row.checkFileName }}</div>
</template>
</el-table-column>
<el-table-column label="操作" fixed="right">
<template slot-scope="scope">
<el-button
type="text"

@ -259,9 +259,19 @@
prop="certCode"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="检验报告"
width="160"
prop="checkFileName"
show-overflow-tooltip
>
<template slot-scope="scope">
<div style="color: #1890ff;" @click="showImgViewer(scope.row)">{{ scope.row.checkFileName }}</div>
</template>
</el-table-column>
<el-table-column label="操作" width="160" fixed="right">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@ -361,6 +371,7 @@
/>
</el-tab-pane>
</el-tabs>
<el-image-viewer v-if="imgViewerVisible" style="z-index:9999" :on-close="closeImgViewer" :url-list="imgList"/>
<el-dialog
@ -412,6 +423,9 @@ import AcceptOrder from "@/views/inout/DialogThrReviewOrder";
import {getDeptListByUser} from "@/api/auth/authDept";
import DialogCheck from "@/views/inout/DialogCheck";
import { getBizDetailList } from '@/api/inout/orderDetailBiz'
import { previewImage } from '@/api/purchase/supCompany'
import ElImageViewer from "element-ui/packages/image/src/image-viewer";
const formJson = {
site_id: "",
@ -424,6 +438,9 @@ export default {
name: "IoSupSearchOrder",
data() {
return {
BASE_URL: process.env.VUE_APP_BASE_API,
imgList:[],
imgViewerVisible:false,
showSearch: true,
Upinvoice:false,
currentManufacturer:{},
@ -547,7 +564,7 @@ export default {
acceptOrderVisible: false,
};
},
components: {AcceptOrder,DialogCheck},
components: {AcceptOrder,DialogCheck,ElImageViewer},
methods: {
onReset() {
this.$router.push({
@ -596,12 +613,38 @@ export default {
});
},
showImgViewer(row){
this.certFileUrl = this.BASE_URL + "/udiwms/image/register/file/getImage?type=image2&name=";
console.log(this.certFileUrl+"========");
this.imgList=[];
previewImage({imageUrl:row.filePath,certFileUrl:this.certFileUrl}).then(response => {
if (response.code === 20000) {
this.imgList=response.data;
}
console.log(this.imgList)
this.imgViewerVisible = true;
});
const m = (e) => { e.preventDefault() };
document.body.style.overflow = 'hidden';
document.addEventListener("touchmove", m, false); //
},
closeImgViewer(){
this.imgViewerVisible = false;
const m = (e) => { e.preventDefault() };
document.body.style.overflow = 'auto';
document.removeEventListener("touchmove", m, true);
},
upload(row){
this.currentManufacturer = row;
this.Upinvoice = true;
},
closeCheckDialog(){
this.Upinvoice = false;
this.getOrderDetails();
},
handleSelectionChange(val) {
this.currentRow.billNo=val.billNo;

@ -285,6 +285,17 @@
prop="certCode"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="检验报告"
width="160"
prop="checkFileName"
show-overflow-tooltip
>
<template slot-scope="scope">
<div style="color: #1890ff;" @click="showImgViewer(scope.row)">{{ scope.row.checkFileName }}</div>
</template>
</el-table-column>
<el-table-column label="操作" width="160" fixed="right">
<template slot-scope="scope">
@ -389,6 +400,9 @@
</el-tab-pane>
</el-tabs>
<el-image-viewer v-if="imgViewerVisible" style="z-index:9999" :on-close="closeImgViewer" :url-list="imgList"/>
<el-dialog
title="编辑"
:visible.sync="Upinvoice"
@ -438,6 +452,9 @@ import AcceptOrder from "@/views/inout/DialogReviewOrder";
import {getDeptListByUser} from "@/api/auth/authDept";
import DialogCheck from "@/views/inout/DialogCheck";
import {getBizDetailList} from "@/api/inout/orderDetailBiz";
import { previewImage } from '@/api/purchase/supCompany'
import ElImageViewer from "element-ui/packages/image/src/image-viewer";
const formJson = {
@ -451,6 +468,9 @@ export default {
name: "IoSupSearchOrder",
data() {
return {
BASE_URL: process.env.VUE_APP_BASE_API,
imgList:[],
imgViewerVisible:false,
showSearch: true,
Upinvoice: false,
currentManufacturer: {},
@ -580,7 +600,7 @@ export default {
acceptOrderVisible: false,
};
},
components: {AcceptOrder, DialogCheck},
components: {AcceptOrder, DialogCheck,ElImageViewer},
methods: {
onReset() {
this.$router.push({
@ -623,7 +643,28 @@ export default {
hideSearch() {
this.showSearch = !this.showSearch;
},
showImgViewer(row){
this.certFileUrl = this.BASE_URL + "/udiwms/image/register/file/getImage?type=image2&name=";
console.log(this.certFileUrl+"========");
this.imgList=[];
previewImage({imageUrl:row.filePath,certFileUrl:this.certFileUrl}).then(response => {
if (response.code === 20000) {
this.imgList=response.data;
}
console.log(this.imgList)
this.imgViewerVisible = true;
});
const m = (e) => { e.preventDefault() };
document.body.style.overflow = 'hidden';
document.addEventListener("touchmove", m, false); //
},
closeImgViewer(){
this.imgViewerVisible = false;
const m = (e) => { e.preventDefault() };
document.body.style.overflow = 'auto';
document.removeEventListener("touchmove", m, true);
},
upload(row) {
this.currentManufacturer = row;
this.Upinvoice = true;

Loading…
Cancel
Save