Skip to content

Commit

Permalink
chore(add-item): permit insert flags when is the same product
Browse files Browse the repository at this point in the history
  • Loading branch information
matheusgnreis authored Aug 4, 2022
1 parent 48ec36b commit d9726b9
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/methods/add-item.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,13 @@ export default ({ data, save }, emitter, [newItem, canSave = true]) => {
if (newItem.final_price) {
item.final_price = newItem.final_price
}
if (newItem.flags) {
if (!item.flags) {
item.flags = newItem.flags
} else {
item.flags.concat(newItem.flags)
}
}
fixedItem = fixItemQuantity(item)
}
}
Expand Down

0 comments on commit d9726b9

Please sign in to comment.