我正在尝试为具有字符串、数字和布尔值的混合值的数据集实现搜索管道。我正在尝试实现以下管道
演示,该链接适用于带有字符串的数据集,但我不断收到错误消息,即 toUpperCase() 不是函数,因为它无法遍历具有不同数据类型的数据,请建议我一个方法。我已经尝试以多种方式修改链接,但我失败了。我的数据集如下{
"pnr_id": 5037295,
"uniqueId": 103739,
"amount_paid": 37.2484,
"name": "Sharon",
"surname": "Monroe",
"fullname": "Rhonda McLean",
"email": "annette@puckett.mt",
"amount_due": true,
"amount_pending": 13.258,
"user_name": "brandon@hanna.gf"
},
{
"pnr_id": 5037296,
"uniqueId": 195415,
"amount_paid": 42.7672,
"name": "Don",
"surname": "Goldstein",
"fullname": "Christina Carroll",
"email": "steve@cochran.mo",
"amount_due": true,
"amount_pending": 35.9709,
"user_name": "renee@rogers.ao"
}
谢谢你和问候
使用字符串的数据集的工作 Plunkr 链接:-- https://plnkr.co/edit/jXfqfCuJpKdw9HtL569T?p=preview