我想通过简单的链接过滤我的观点。我有几个对象都包含日期。例如。如果我点击仅限三月份数据" Startdate"应该显示三月。我在网上搜索但发现没有什么对我有用。这是我的json对象,标准应该是" Startdate"。
trips.son
[{
"Startdate": "Thu Jan 02 2014 00:00:00 +0100",
"DAYS": [{
"DATE": "Thu Jan 02 2014 00:00:00 +0100",
"IATA": "TXL",
"DUTY": "6:10"
}]
}, {
"Startdate": "Sun Jan 05 2014 00:00:00 +0100",
"DAYS": [{
"DATE": "Sun Jan 05 2014 00:00:00 +0100",
"IATA": "CBTH",
"DUTY": "8:07"
}]
}, {
"Startdate": "Wed Sep 24 2014 00:00:00 +0200",
"DAYS": [{
"DATE": "Wed Sep 24 2014 00:00:00 +0200",
"IATA": "BCN",
"DUTY": "9:35"
}, {
"DATE": "Thu Sep 25 2014 00:00:00 +0200",
"IATA": "BCN",
"DUTY": "15:34"
}]
}, {
"Startdate": "Sat Sep 27 2014 00:00:00 +0200",
"DAYS": [{
"DATE": "Sat Sep 27 2014 00:00:00 +0200",
"IATA": "CPH",
"DUTY": "4:44"
}]
}]
在这里你可以看到我的意思:
更新: plnkr
默认情况下,只显示1月 - 单击每个链接时更改视图!