update an array in database
Dears,
I want to use mongoDB $push or $addToSet to append to an array in a collection
when I execute the below code I got successful result but no update happen to the array in the collection , please advise.
update_request_login_page.execute({
'data' : {
"$addToSet": {"driversRecivedTheRequest": "999999" }
Code: Select all
},
'parameters': {
reqID: "5a63c695a428937aa506b06f"
},
success: function(data){
toast('تم تعديل حالة الطلب..!!');
},
error: function(e){
toast('خطأ لم يتم تعديل حالت الطلب..!!');
}
});