AngularJS中如何去掉 ng-repeat的自动排序?

2025-04-05 19:09:44
推荐回答(1个)
回答1:

$scope.records = {
"2013": [
{order_year:"2013", order_date:"3-5", order_number: "A123445678", mileage: 20000, sname: "华盛汽车" },
{order_year:"2013", order_date:"6-5", order_number: "A123445678", mileage: 28000, sname: "华盛汽车" },
{order_year:"2013", order_date:"3-25", order_number: "A123445678", mileage: 16000, sname: "华盛汽车" }
], 
"2016": [
{order_year:"2016", order_date:"3-25", order_number: "A123445678", mileage: 14000, sname: "华盛汽车" }
], 
"2012": [
{order_year:"2012", order_date:"3-25", order_number: "A123445678", mileage: 14000, sname: "华盛汽车" }
]}; 

$scope.keys = Object.keys($scope.records);

        {{records[key]}}
    

相关问答