Skip to content

Instantly share code, notes, and snippets.

@annibuliful
Last active September 2, 2018 14:53
Show Gist options
  • Save annibuliful/6b475af83d112ce1fdf6966d77a48d89 to your computer and use it in GitHub Desktop.
Save annibuliful/6b475af83d112ce1fdf6966d77a48d89 to your computer and use it in GitHub Desktop.
$push:{
activityLog:{
status:2, // status number when the driver change
remark:this.quote.REMARK, // if the driver has remark, fill it. If the driver hasn't remark, file ""
byUser:{
id:this.forwarderId, // the driver Id
name:this.forwarderName, // if it nothing, fille "driver" or ""
}
}
}
// example
shipmentsService.patch(this.shipmentId, {
selectedTrucker: {
id: this.quote.ID,
name: this.quote.NAME,
rating: this.quote.RATING,
price: this.quote.PRICE,
remark: this.quote.REMARK,
date: this.quote.DATE,
},
$push:{
activityLog:{
status:2,
remark:this.quote.REMARK,
byUser:{
id:this.forwarderId,
name:this.forwarderName,
}
}
},
status: 2
}),
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment