我正在使用alasql.js文件将 JSON 数据导出到 excel 文件中。我面临的问题是,当我导出数据时,它正在导出没有任何问题,但是类型为数字的列在 Excel 中导出为文本。
有谁知道任何备用库将数据从 json 导出到 excel 并保留数据类型。
我的 JSON 看起来像:--
[{"emplId":"Empl Id","emplName":"Empl Name","formNumber":"Form Number","costCenter":"Cost Center","emplDept":"Empl Dept","invoiceNumber":"Invoice Number","totalPrice":"Total Price","purchaseDate":"Purchase Date","shoesStyle":"Shoes Style","shoesSize":"Shoes Size","shoesWidth":"Shoes Width","companyname":"Companyname","shoePrice":"Shoe Price","taxAmountPaid":"Tax Amount Paid","shippinghandling":"Shippinghandling","typeofPurchase":"Typeof Purchase","storeAccountNumber":"Store Account Number","refundFlag":"Refund Flag","manufacturer":"Manufacturer"},
{"emplId":1234567,"emplName":"Kevin W Hays","formNumber":5734,"costCenter":"PM555","emplDept":"SUPPLY","invoiceNumber":"ACCC1213","totalPrice":201.45,"purchaseDate":"01/05/2015","shoesStyle":"W02053","shoesSize":11,"shoesWidth":"E3","companyname":"XXX","shoePrice":180,"taxAmountPaid":21.45,"shippinghandling":"","typeofPurchase":"Store","storeAccountNumber":"1707401","refundFlag":"N","manufacturer":"XXX"}]
任何帮助是极大的赞赏。