-1
如何获得值和display from below string?如何解析这个特定的json字符串?
[
{
"hdr":"",
"forElement":"",
"preFields":[
],
"rows":[
[
{
"field":"subject_area",
"label":"Subject Area",
"mandatory":"",
"type":"text",
"giveFocus":"",
"reference":"",
"choiceOptions":null,
"refQual":"",
"onChangeFunc":"",
"cellCSS":"",
"labelCSS":"",
"show":"always",
"imageSrc":"",
"value":"helo",
"display":"helods",
"relatedTable":"",
"disabled":false
},
{
"field":"table",
"label":"Table",
"mandatory":"",
"type":"text",
"giveFocus":"",
"reference":"",
"choiceOptions":null,
"refQual":"",
"onChangeFunc":"",
"cellCSS":"",
"labelCSS":"",
"show":"always",
"imageSrc":"",
"value":"helasdsao",
"display":"helo",
"relatedTable":"",
"disabled":false
},
{
"field":"column",
"label":"Column",
"mandatory":"",
"type":"text",
"giveFocus":"",
"reference":"",
"choiceOptions":null,
"refQual":"",
"onChangeFunc":"",
"cellCSS":"",
"labelCSS":"",
"show":"always",
"imageSrc":"",
"value":"hesadslo",
"display":"helo",
"relatedTable":"",
"disabled":false
},
{
"field":"description",
"label":"Description",
"mandatory":"",
"type":"text",
"giveFocus":"",
"reference":"",
"choiceOptions":null,
"refQual":"",
"onChangeFunc":"",
"cellCSS":"",
"labelCSS":"",
"show":"always",
"imageSrc":"",
"value":"helo",
"display":"hedsadlo",
"relatedTable":"",
"disabled":false
}
]
]
}
]
什么编程语言?你期望什么样的数据结构?你试过什么了? – Ruud
我正在试图在JavaScript中。 – user3781360
那么,由于没有名为'values'的字段,您将无法得到它。对于'陈列'你需要剥洋葱。最外层是一个数组,然后你有一个对象,另外两个数组,以及另一个要剥离的对象。 –