У меня есть служба отдыха, которая создает данные JSON ниже:
{
"root": {
"branches": [
{
"branch_addr": "string",
"branch_telp": "string",
"branch_loc": "string",
"branch_dept_it": {
"branch_dept_it_employees": {
"properties": [
{
"content": "string",
"attr": "emp_id"
},
{
"content": "string",
"attr": "emp_name"
},
{
"content": "string",
"attr": "emp_pos"
}
],
"branch_dept_it_code": "string"
}
},
"branch_dept_finance": {
"branch_dept_finance_employees": {
"properties": [
{
"content": "string",
"attr": "emp_id"
},
{
"content": "string",
"attr": "emp_name"
},
{
"content": "string",
"attr": "emp_pos"
}
],
"branch_dept_finance_code": "string"
}
},
"branch_name": "Mars",
"branch_id": "MarsID"
},
{
"branch_addr": "string",
"branch_telp": "string",
"branch_loc": "string",
"branch_dept_it": {
"branch_dept_it_employees": {
"properties": [
{
"content": "string",
"attr": "emp_id"
},
{
"content": "string",
"attr": "emp_name"
},
{
"content": "string",
"attr": "emp_pos"
}
],
"branch_dept_it_code": "string"
}
},
"branch_dept_finance": {
"branch_dept_finance_employees": {
"properties": [
{
"content": "string",
"attr": "emp_id"
},
{
"content": "string",
"attr": "emp_name"
},
{
"content": "string",
"attr": "emp_pos"
}
],
"branch_dept_finance_code": "string"
}
},
"branch_name": "VENUS",
"branch_id": "venusID"
},
{
"branch_addr": "string",
"branch_telp": "string",
"branch_loc": "string",
"branch_dept_it": {
"branch_dept_it_employees": {
"properties": [
{
"content": "string",
"attr": "emp_id"
},
{
"content": "string",
"attr": "emp_name"
},
{
"content": "string",
"attr": "emp_pos"
}
],
"branch_dept_it_code": "string"
}
},
"branch_dept_finance": {
"branch_dept_finance_employees": {
"properties": [
{
"content": "string",
"attr": "emp_id"
},
{
"content": "string",
"attr": "emp_name"
},
{
"content": "string",
"attr": "emp_pos"
}
],
"branch_dept_finance_code": "string"
}
},
"branch_name": "Mercury",
"branch_id": "mercuryID"
}
],
"regions": {
"region_data": {
"properties": [
{
"content": "string",
"attr": "reg_id"
},
{
"content": "string",
"attr": "reg_name"
},
{
"content": "string",
"attr": "reg_loc"
}
],
"region_name": "Galaxy"
}
},
"other": {
"other_data": {
"properties": [
{
"content": "string",
"attr": "reg_id"
},
{
"content": "string",
"attr": "reg_name"
},
{
"content": "string",
"attr": "reg_loc"
}
],
"region_name": "Galaxy"
}
}
},
"tree": {
"tree_var1": "string",
"tree-var2": "string",
"tree-var3": "string"
}
}
Когда я проверяю консольный браузер, служба RESTful уже правильно ПОЛУЧАЕТСЯ с определенным запросом, определенным в JsonRestStore.
Как отобразить на основе указанного выше формата в dojox.grid.DataGrid/dijit.tree (Dojo 1.8)?