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,