Mapping nested JSON object from api to json object
My api return a nested json object and I want to map it in json object in data in vue.
My api response:

I want to map it to:
editedItem:{
FirstName: '',
LastName: '',
Address: '',
DepartmentName: '',
}
I just want to map the DepartmentModel.DepartmentName to DepartmentName.
This is how what I've done by the way.
item contains:

this.editedItem = Object.assign({}, item)