我在 couchdb 存储中有以下 json(简化)对象:
[{
"_id": "5ea7a53e670b432e0fe22a7bc10024db",
"_rev": "1-ae70c8906f7aa6d73539a89f7ad960ee",
"type": "job"
}, {
"_id": "5ea7a53e670b432e0fe22a7bc10041d9",
"_rev": "4-fa0ba68c35ca548b497a7309389f9087",
"type": "scan",
"job_id": "5ea7a53e670b432e0fe22a7bc10024db",
"number": 1
}, {
"_id": "5ea7a53e670b432e0fe22a7bc100520e",
"_rev": "4-3e6b1a028786c265ecb7362e245d049e",
"type": "scan",
"job_id": "5ea7a53e670b432e0fe22a7bc10024db",
"number": 2
}]
我想使用键 ["5ea7a53e670b432e0fe22a7bc10024db", 2] (作业 ID 和扫描号)发出一个发布请求。如何为视图制作地图功能以过滤出具有给定 id 的作业以及与 job_id 和数字匹配的测量值?
谢谢,拉杜