这是初始状态:
const initialState ={
ordersWholesale:[
{
"id": 14,
"name": "XTPara 650mg Tablet",
"code": "XTP5656",
"date": "17/10/2022",
"accepted": null,
"wholesale": "shakthi",
"quantity": "5"
},
{
"id": 15,
"name": "Dolo 650 Tablet",
"code": "DOL1213",
"date": "17/10/2022",
"accepted": false,
"wholesale": "shakthi",
"quantity": "5"
},
],
}
这是切片机
extraReducer: {
[asyncOrderAccept.fulfilled]: (state, { payload }) => {
}
}
如何使用为14的有效负载值仅更改值orderWholesale[0]['accepted']: true
?