aa(event){//选择的excel文件
            var file=event.target.files[0];
            console.log(file);
            var reader = new FileReader(); 
            reader.readAsBinaryString(file); 
            reader.onload=(e=>{
                var bb={lang:1,fileinfo:e.target.result,enen:2};
                console.log(bb)
                var xx = Qs.stringify(bb);
                console.log(xx);
            })
            
        }

以上是处理方法,原因是我们拿到的file是File的示例,不包含文件,需要filereader才能获取到真实文件。

问题还原:

var bb={lang:1,fileinfo:function(){},enen:2};
            console.log(bb)
            var xx = Qs.stringify(bb);
            console.log(xx);

这样就可以还原上面的问题了

相关文章:

  • 2021-10-08
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-10-20
  • 2021-07-20
猜你喜欢
  • 2021-06-17
  • 2021-12-07
  • 2022-01-12
  • 2022-12-23
  • 2021-10-31
  • 2021-12-09
相关资源
相似解决方案