You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I found an error in processing data. <tr ng-repeat="data in BuildData(csv.result)"> <td class="text-center">{{data.height1}}</td> <td class="text-center">{{data.volume1}}</td> <td class="text-center">{{data.height2}}</td> <td class="text-center">{{data.volume2}}</td> <td class="text-center">{{data.height3}}</td> <td class="text-center">{{data.volume3}}</td> <td class="text-center">{{data.height4}}</td> <td class="text-center">{{data.volume4}}</td> </tr>
`$scope.BuildData = function (json) {
console.log(calFlag);
console.log(JSON.stringify(json));
if(json==null||calFlag){
return;
}
calFlag=true;
console.log("2:"+calFlag);
var result = [];
var obj = [];
// console.log($scope.csv.result.length);
for (var i = 0;i<json.length;i++) {
var element = json[i];
var key = i % 4 + 1;
// console.log(JSON.stringify( element)+":" +key);
obj["height" + key] = element["#高度"];
obj["volume" + key] = element["体积"];
if (key === 4) {
// console.log(JSON.stringify(result));
result.push(obj);
obj = [];
}
}
if(obj.length>0){
result.push(obj);
obj = [];
}
//console.log(JSON.stringify(result));
calFlag=false;
return result;
};
I found an error in processing data.
<tr ng-repeat="data in BuildData(csv.result)"> <td class="text-center">{{data.height1}}</td> <td class="text-center">{{data.volume1}}</td> <td class="text-center">{{data.height2}}</td> <td class="text-center">{{data.volume2}}</td> <td class="text-center">{{data.height3}}</td> <td class="text-center">{{data.volume3}}</td> <td class="text-center">{{data.height4}}</td> <td class="text-center">{{data.volume4}}</td> </tr>
`$scope.BuildData = function (json) {
console.log(calFlag);
console.log(JSON.stringify(json));
if(json==null||calFlag){
return;
}
calFlag=true;
console.log("2:"+calFlag);
var result = [];
var obj = [];
// console.log($scope.csv.result.length);
for (var i = 0;i<json.length;i++) {
angular.js:11383 Error: [$rootScope:infdig] 15 $digest() iterations reached. Aborting!
at angular.js:80
at Scope.$digest (angular.js:14080)
at Scope.$apply (angular.js:14304)
at FileReader.reader.onload (angular-csv-import.js:110)(anonymous function) @ angular.js:11383(anonymous function) @ angular.js:8459$apply @ angular.js:14306reader.onload @ angular-csv-import.js:110
angular.js:80 Uncaught Error: [$rootScope:infdig] 15 $digest() iterations reached. Aborting!(…)(anonymous function) @ angular.js:80$digest @ angular.js:14080$apply @ angular.js:14304reader.onload @ angular-csv-import.js:110`
body is too long (maximum is 65536 characters).
The text was updated successfully, but these errors were encountered: