**作为回应,我得到的数据不足**
[
{
"EmpId": "8139fb43-5958-44ab-b2a5-0205f828a4e0",
"Department": "0574109",
"EmpName": "Name1"
},
{
"EmpId": "42e1e945-d682-4215-9c82-02233c078d19",
"Department": "0574109",
"EmpName": "Name2"
},
{
"EmpId": "5ef9114c-2043-4f9a-8a5c-06898dcd572b",
"Department": "0674492",
"EmpName": "Name3"
}
]
**并且我需要以下格式的数据:-**
"Datails" :[
{
"Department": "0574109",
"Employee": [
{
"EmpId": "8139fb43-5958-44ab-b2a5-0205f828a4e0",
"EmpName": "Name1"
},
{
"EmpId": "42e1e945-d682-4215-9c82-02233c078d19",
"EmpName": "Name2"
}
]
},
{
"Department": "0674492",
"Employee": [
{
"EmpId": "5ef9114c-2043-4f9a-8a5c-06898dcd572b",
"EmpName": "Name3"
}
]
}
]
}
**我正在尝试使用“ $ apply = groupby”,但这没有给我预期的结果。 **