[英]what is the problem with my handlebar code?
我的车把代码有什么问题?我想打印“ availability”数组的数据。作为响应,所有其他字段数据都被打印了,但在“ availability”字段方面显示了空白页。以下是我的代码,然后是我要从中访问“可用性”数组字段的格式。
<body> <table> {{#each availability}} <tr> <td><div>{{this.date}}</div></td> <td><div>{{this.status}}</div></td></tr> {{/each}} </table> </body> ======below is the format which I want to access======== { "response_code": 200, "debit": 3, "train": { "name": "NDLS SHATABDI E", "number": "12001" }, "from_station": { "lat": 23.2599333, "name": "BHOPAL JN", "lng": 77.412615, "code": "BPL" }, "to_station": { "lat": 30.6016778, "name": "NEW DELHI", "lng": -98.3488272, "code": "NDLS" }, "journey_class": { "name": "AC CHAIR CAR", "code": "CC" }, "quota": { "name": "GENERAL QUOTA", "code": "GN" }, "availability": [ { "date": "14-07-2017", "status": "AVAILABLE 364" }, { "date": "15-07-2017", "status": "AVAILABLE 361" }, { "date": "16-07-2017", "status": "AVAILABLE 284" }, { "date": "17-07-2017", "status": "AVAILABLE 351" }, { "date": "18-07-2017", "status": "AVAILABLE 303" }, { "date": "19-07-2017", "status": "AVAILABLE 329" } ] }
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.