ng-repeat评论了在Internet Explorer中显示,同时在其他angularjs上也能正常工作

时间:2018-06-27 10:41:45

标签: angularjs

[
   {
      "user_id":95507,
      "social_id":null,
      "type":2,
      "spr_id":0,
      "link_confirmed":null,
      "sp":[
         {
            "id":"131556",
            "user_id":"95507",
            "spr_id":"1"
         },
         {
            "id":"131557",
            "user_id":"95507",
            "spr_id":"2"
         },
         {
            "id":"131558",
            "user_id":"95507",
            "spr_id":"3"
         },
         {
            "id":"131559",
            "user_id":"95507",
            "spr_id":"4"
         },
         {
            "id":"131560",
            "user_id":"95507",
            "spr_id":"5"
         },
         {
            "id":"131561",
            "user_id":"95507",
            "spr_id":"7"
         }
      ]
   },
   {
      "user_id":95509,
      "social_id":null,
      "type":3,
      "spr_id":1,
      "link_confirmed":null,
      "sp":[

      ]
   },
   {
      "user_id":95510,
      "social_id":null,
      "type":3,
      "spr_id":1,
      "link_confirmed":null,
      "sp":[

      ]
   },
   {
      "user_id":95512,
      "social_id":null,
      "type":2,
      "spr_id":0,
      "link_confirmed":null,
      "sp":[
         {
            "id":"131569",
            "user_id":"95512",
            "spr_id":"1"
         },
         {
            "id":"131570",
            "user_id":"95512",
            "spr_id":"2"
         },
         {
            "id":"131571",
            "user_id":"95512",
            "spr_id":"3"
         }
      ]
   },
   {
      "user_id":95513,
      "social_id":null,
      "type":3,
      "spr_id":1,
      "link_confirmed":null,
      "sp":[

      ]
   },
   {
      "user_id":96276,
      "social_id":null,
      "type":3,
      "spr_id":1,
      "link_confirmed":null,
      "sp":[

      ]
   },
   {
      "user_id":96277,
      "social_id":null,
      "type":3,
      "spr_id":1,
      "link_confirmed":null,
      "sp":[

      ]
   }
]

HTML

<tr ng-repeat="profile in profile_users | filter: { link_confirmed : '!' } | filter: filterExpressions track by $index">
    <td>{{ profile.user_id }}</td>
    <span ng-repeat="spd in profile.sp track by $index">
        {{ (profile.type == 2) ? ($index >= 0 && profile.sp.length - 1 &&  $last-1) ? sp[spd.spr_id] + ", " : sp[spd.spr_id] : '' }}
    </span>
    </td>
</tr>

ng-repeat评论了在Internet Explorer中显示的内容,同时在其他对象上的运行情况很好AngularJS不知道为什么我没有进行更改对我不起作用。请帮助我如何解决此问题,在此先感谢

更新了json格式以便更好地理解,请现在看看让我知道我错了

请注意,这仅在Internet Explorer中,其他浏览器似乎没什么问题

0 个答案:

没有答案