0
我正在使用angularjs和javascript,並希望使用alasql將兩個數組導出到Excel。 Excel文件有兩張紙,每張紙上有一個數組。alasql導出到xlsx刪除hashkey
在我的Excel結果中,我找到了一個額外的列$$hashkey
。 根據我發現的信息,使用angularjs,$$hashkey
被自動刪除。我也嘗試加入'alasql.options.angularjs'
但它沒有幫助。 我在做什麼錯?
我使用這樣的兩個數組:
$scope.ExecutionsLC1: [[Execution,1,2,3],[Operators,1014,1019,1020],[Result,X,X,V]];
$scope.ExecutionsLC2: [[Execution,1,2,3],[Operators,2014,2019,2020],[Result,X,X,V]];
var opts = [{sheetid:'LC1',header:false},{sheetid:'LC2',header:false}];
var res = alasql('SELECT INTO XLSX("LCDetail.xlsx",?) FROM ?',[opts,[$scope.ExecutionsLC1,$scope.ExecutionsLC2]]);
angular.toJson()也可以工作 –