gpt4 book ai didi

javascript - 使用 angularjs ng-repeat 构建 2 路表

转载 作者:行者123 更新时间:2023-12-03 05:20:51 26 4
gpt4 key购买 nike

我想生成如下所示的表 https://output.jsbin.com/nowacafacu

但我被困在这里 http://jsfiddle.net/ez2e12e4/

<div class="table-row" ng-repeat="student in students">
<div><i>{{student.name}}</i></div>
<div>Grade:</div>
<div>Mark:</div>
<br>
<div ng-repeat="data in student.data">

</div>
</div>

尝试了几个小时,需要擅长 angularjs 的人的帮助

最佳答案

试试这个内特利

http://jsfiddle.net/sharmi1308/ez2e12e4/2/

                <div ng-controller="MyCtrl">
<div id="header-row">
<div class="date-header" ng-repeat="date in dates">
{{date}}
</div>
</div>
<div class="table-row" ng-repeat="student in students">
<div><i>{{student.name}}</i></div>
<div class="gradewrap">
<div class="gradedetails">
<div>Grade:</div>
<div>Mark:</div>
</div>
<div class="gradevalueswrap">
<div class="gradevalues" ng-repeat="data in student.data">
<div>
{{data.grade}}
</div>
<div>
{{data.mark}}
</div>
</div>
</div>
</div>
</div>
</div>

关于javascript - 使用 angularjs ng-repeat 构建 2 路表,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41391656/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com