test
薛宇 2 years ago
parent 7b080d394b
commit 77afc7dd03

@ -544,19 +544,21 @@ export default {
'png', 'jpg', 'jpeg', 'bmp', 'gif', 'webp', 'psd', 'svg', 'tiff'].indexOf(ext.toLowerCase()) !== -1; 'png', 'jpg', 'jpeg', 'bmp', 'gif', 'webp', 'psd', 'svg', 'tiff'].indexOf(ext.toLowerCase()) !== -1;
}, },
showImgViewer(row) { showImgViewer(row) {
this.certFileUrl = this.BASE_URL + "/udiwms/image/register/file/getImage?type=image2&name="; let newWindow = window.open();
this.imgList = []; newWindow.document.write(row.filePath)
previewImage({imageUrl: row.filePath, certFileUrl: this.certFileUrl}).then(response => { // this.certFileUrl = this.BASE_URL + "/udiwms/image/register/file/getImage?type=image2&name=";
if (response.code === 20000) { // this.imgList = [];
this.imgList = response.data; // previewImage({imageUrl: row.filePath, certFileUrl: this.certFileUrl}).then(response => {
} // if (response.code === 20000) {
}); // this.imgList = response.data;
this.imgViewer = true; // }
const m = (e) => { // });
e.preventDefault() // this.imgViewer = true;
}; // const m = (e) => {
document.body.style.overflow = 'hidden'; // e.preventDefault()
document.addEventListener("touchmove", m, false); // // };
// document.body.style.overflow = 'hidden';
// document.addEventListener("touchmove", m, false); //
}, },
closeImgViewer() { closeImgViewer() {
this.imgViewerVisible = false; this.imgViewerVisible = false;

@ -579,19 +579,21 @@ export default {
'png', 'jpg', 'jpeg', 'bmp', 'gif', 'webp', 'psd', 'svg', 'tiff'].indexOf(ext.toLowerCase()) !== -1; 'png', 'jpg', 'jpeg', 'bmp', 'gif', 'webp', 'psd', 'svg', 'tiff'].indexOf(ext.toLowerCase()) !== -1;
}, },
showImgViewer(row) { showImgViewer(row) {
this.certFileUrl = this.BASE_URL + "/udiwms/image/register/file/getImage?type=image2&name="; let newWindow = window.open();
this.imgList = []; newWindow.document.write(row.filePath)
previewImage({imageUrl: row.filePath, certFileUrl: this.certFileUrl}).then(response => { // this.certFileUrl = this.BASE_URL + "/udiwms/image/register/file/getImage?type=image2&name=";
if (response.code === 20000) { // this.imgList = [];
this.imgList = response.data; // previewImage({imageUrl: row.filePath, certFileUrl: this.certFileUrl}).then(response => {
} // if (response.code === 20000) {
}); // this.imgList = response.data;
this.imgViewer = true; // }
const m = (e) => { // });
e.preventDefault() // this.imgViewer = true;
}; // const m = (e) => {
document.body.style.overflow = 'hidden'; // e.preventDefault()
document.addEventListener("touchmove", m, false); // // };
// document.body.style.overflow = 'hidden';
// document.addEventListener("touchmove", m, false); //
}, },
closeImgViewer() { closeImgViewer() {
this.imgViewerVisible = false; this.imgViewerVisible = false;

Loading…
Cancel
Save