From 6a75a6c56adb6c0ab6403424f755e7a7f3405140 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=98=8E?= <775174143@qq.com> Date: Sat, 6 Jul 2019 12:35:03 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/modules/courses/Resource/Fileslistitem.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/public/react/src/modules/courses/Resource/Fileslistitem.js b/public/react/src/modules/courses/Resource/Fileslistitem.js index 5eef94d9f..239fd34a4 100644 --- a/public/react/src/modules/courses/Resource/Fileslistitem.js +++ b/public/react/src/modules/courses/Resource/Fileslistitem.js @@ -43,10 +43,10 @@ class Fileslistitem extends Component{ }).then((result)=>{ if(result.data.attachment_histories.length===0){ - link.href = result.data.url; - link.style.display = 'none'; - document.body.appendChild(link); - link.click(); + // link.href = result.data.url; + // link.style.display = 'none'; + // document.body.appendChild(link); + // link.click(); //兼容火狐浏览器 // let evt = document.createEvent("MouseEvents"); // evt.initEvent("click", false, false); @@ -60,7 +60,7 @@ class Fileslistitem extends Component{ // link.setAttribute('download',result.data.title); // document.body.appendChild(link); // link.click(); - + window.open=result.data.url; }else{ this.setState({ Showoldfiles:true,