question

mehran avatar image
mehran asked hinashah answered

How to know An LineItem quantity is decremented in register by pressing Subtract icon

I just want to know when the new line item is added to Clover register it notifies my app through broadcast action(com.clover.intent.action.LINE_ITEM_ADDED") when I trigger plus icon in a register to increment the quantity of line Item it again triggers the same action which is ok, So the main point of my question is when user will trigger the subtract icon for decrement of line items quantity it will notify me but I don't know which action I use or which technique I use to get decremented line item detail.
Any help will be appreciated.thanks
OrdersLineItems
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

yihil avatar image
yihil answered

Good tips for me! You start as small cells in a Petri dish and aim to grow by consuming smaller cells and pellets scattered around agar io the map.

10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

hinashah avatar image
hinashah answered

"This is an interesting scenario! For decrementing the line item quantity, you might need to listen for a different broadcast action, such as one specifically for quantity updates or item changes. If Clover doesn’t provide a direct action for this, you could track the changes by maintaining the previous state of the cart and comparing it whenever you receive a broadcast action like com.clover.intent.action.LINE_ITEM_UPDATED. This way, you can determine if the change was an increment or decrement.

For more insights and helpful discussions, check out Anitalks Official!"


10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Welcome to the
Clover Developer Community