js 把字符串转jsonArray "[{fd_zj_materialCode_dataModelName=, fd_zj_materialCode_dataFdId=, fd_zj_machine_series_code=18, fd_zj_screw=46/B, fd_zj_crm_flag=同步成功, fd_zj_quantity=1.0, fd_zj_delivery_date_record=[{id=16eeff527815c214b0af8404e9e9e1cf, time=Wed Feb 08 17:00:15 CST 2023, name=蓝凌, data=2023-02-13}], fd_zj_materialCode_dataSourceId=, fd_zj_materialCode=2260933346643275, fd_zj_demand_desc_record=[{id=16eeff527815c214b0af8404e9e9e1cf, time=Wed Feb 08 17:00:15 CST 2023, name=蓝凌, data=1、配镀铬混炼B螺杆 2、加装 抽芯一组 3、加装吹风一组}], fd_zj_materialCode_selectedDatas=, fd_zj_crm_flag_record=[{id=16eeff527815c214b0af8404e9e9e1cf, time=Wed Feb 08 17:00:15 CST 2023, name=蓝凌, data=}], fd_zj_remark=, fd_zj_machine_series_desc_record=[{id=16eeff527815c214b0af8404e9e9e1cf, time=Wed Feb 08 17:00:15 CST 2023, name=蓝凌, data=JM168-MK6.6/A注塑机}], fd_zj_materialCode_text=2F800-000000000, fd_zj_quantity_record=[{id=16eeff527815c214b0af8404e9e9e1cf, time=Wed Feb 08 17:00:15 CST 2023, name=蓝凌, data=1.0}], fd_zj_machine_series_desc=JM168-MK6.6/A注塑机, fd_zj_factory_source_record=[{id=16eeff527815c214b0af8404e9e9e1cf, time=Wed Feb 08 17:00:15 CST 2023, name=蓝凌, data=null}, {id=16eeff527815c214b0af8404e9e9e1cf, time=Wed Feb 08 17:02:22 CST 2023, name=蓝凌, data=震德机}], fd_zj_remark_record=[{id=16eeff527815c214b0af8404e9e9e1cf, time=Wed Feb 08 17:00:15 CST 2023, name=蓝凌, data=}], fd_zj_screw_record=[{id=16eeff527815c214b0af8404e9e9e1cf, time=Wed Feb 08 17:00:15 CST 2023, name=蓝凌, data=46/B}], fd_zj_factory_source=3.0, fd_zj_delivery_date=Mon Feb 13 00:00:00 CST 2023, fd_zj_assess=null, fd_zj_demand_desc=1、配镀铬混炼B螺杆 2、加装 抽芯一组 3、加装吹风一组, fdId=18630410f7c0108ea5df44646d5acea6, fd_zj_machine_series_code_record=[{id=16eeff527815c214b0af8404e9e9e1cf, time=Wed Feb 08 17:00:15 CST 2023, name=蓝凌, data=18}]}]"
时间: 2024-02-20 19:00:51 浏览: 72
J2EE中JSON+Jquery_AJAX应用.pdf
5星 · 资源好评率100%
您可以使用 JSON.parse() 方法将该字符串转换为 JSON 数组,代码如下:
```javascript
var jsonArray = JSON.parse('[{"fd_zj_materialCode_dataModelName":"","fd_zj_materialCode_dataFdId":"","fd_zj_machine_series_code":"18","fd_zj_screw":"46/B","fd_zj_crm_flag":"同步成功","fd_zj_quantity":"1.0","fd_zj_delivery_date_record":[{"id":"16eeff527815c214b0af8404e9e9e1cf","time":"Wed Feb 08 17:00:15 CST 2023","name":"蓝凌","data":"2023-02-13"}],"fd_zj_materialCode_dataSourceId":"","fd_zj_materialCode":"2260933346643275","fd_zj_demand_desc_record":[{"id":"16eeff527815c214b0af8404e9e9e1cf","time":"Wed Feb 08 17:00:15 CST 2023","name":"蓝凌","data":"1、配镀铬混炼B螺杆 2、加装 抽芯一组 3、加装吹风一组"}],"fd_zj_materialCode_selectedDatas":"","fd_zj_crm_flag_record":[{"id":"16eeff527815c214b0af8404e9e9e1cf","time":"Wed Feb 08 17:00:15 CST 2023","name":"蓝凌","data":""}],"fd_zj_remark":"","fd_zj_machine_series_desc_record":[{"id":"16eeff527815c214b0af8404e9e9e1cf","time":"Wed Feb 08 17:00:15 CST 2023","name":"蓝凌","data":"JM168-MK6.6/A注塑机"}],"fd_zj_materialCode_text":"2F800-000000000","fd_zj_quantity_record":[{"id":"16eeff527815c214b0af8404e9e9e1cf","time":"Wed Feb 08 17:00:15 CST 2023","name":"蓝凌","data":"1.0"}],"fd_zj_machine_series_desc":"JM168-MK6.6/A注塑机","fd_zj_factory_source_record":[{"id":"16eeff527815c214b0af8404e9e9e1cf","time":"Wed Feb 08 17:00:15 CST 2023","name":"蓝凌","data":null},{"id":"16eeff527815c214b0af8404e9e9e1cf","time":"Wed Feb 08 17:02:22 CST 2023","name":"蓝凌","data":"震德机"}],"fd_zj_remark_record":[{"id":"16eeff527815c214b0af8404e9e9e1cf","time":"Wed Feb 08 17:00:15 CST 2023","name":"蓝凌","data":""}],"fd_zj_screw_record":[{"id":"16eeff527815c214b0af8404e9e9e1cf","time":"Wed Feb 08 17:00:15 CST 2023","name":"蓝凌","data":"46/B"}],"fd_zj_factory_source":"3.0","fd_zj_delivery_date":"Mon Feb 13 00:00:00 CST 2023","fd_zj_assess":null,"fd_zj_demand_desc":"1、配镀铬混炼B螺杆 2、加装 抽芯一组 3、加装吹风一组","fdId":"18630410f7c0108ea5df44646d5acea6","fd_zj_machine_series_code_record":[{"id":"16eeff527815c214b0af8404e9e9e1cf","time":"Wed Feb 08 17:00:15 CST 2023","name":"蓝凌","data":"18"}]}]');
```
这样,您就可以使用 jsonArray 数组来访问该 JSON 数据了。注意,该字符串中的键名需要使用双引号包裹起来,否则无法正确解析。
阅读全文