ng-repeat没有显示数据角度

时间:2013-12-15 13:45:07

标签: json angularjs ng-repeat

我有一个校园的JSON文件,需要完成房间和操作(比如修理投影仪......)

我想将操作放在表格中,但它没有显示任何内容

请参阅我的代码:

JSON文件

[
{
    "id": "Groenplaats",
    "name": "Handelswetenschappen en bedrijfskunde",
    "street": "Nationalestraat 5",
    "place": "Groenplaats",
    "region": "B-2000 Antwerp",
    "imageUrl": "../app/img/campusses/HandelswetenschappenEnBedrijfskundeGebouw.png",
    "levelsUp": 5,
    "levelsDown": 1,
    "rooms": [
        {
            "level": 1,
            "roomName": "GR100",
            "type": "Classroom",
            "beamer": "KD554622",
            "capacity": 100,
            "size": "150m²",
            "openingHours": "/",
            "x": -1,
            "y": -1,
            "width": 150,
            "height": 150,
            "actions": [
                {
                    "sort": "light",
                    "description": "Fix light",
                    "date": "15/12/2013"
                }
            ]
        },

HTML

<article ng-show="selection == 'actions'">
            <h2 class="h2">Actions</h2>


                <table class="listTable "ng-repeat="a in c.rooms.actions | filter:    {roomName:campusRoom}">

                    <thead>
                    <tr>
                        <th class="colHead" scope="col" abbr="Sort">Sort</th>
                        <th class="colCol">{{a.sort}}</th>
                        <th class="edit">Edit</th>
                    </tr>
                    <tr>
                        <th class="colHead" scope="col" abbr="Description">Description</th>
                        <th class="colCol">{{a.description}}</th>
                        <th class="edit">Edit</th>
                    </tr>
                    <tr>
                        <th class="colHead" scope="col" abbr="Date">Date</th>
                        <th class="colCol">{{a.date}}</th>
                        <th class="edit">Edit</th>
                    </tr>
                    </thead>

                </table>

        </article>

C在我的html代码的头部定义并且可以访问

有人可以帮我这个吗?

0 个答案:

没有答案