feat: delete item

This commit is contained in:
efrilm
2025-08-02 11:06:41 +07:00
parent 08df1b6384
commit 79d606a08e
4 changed files with 354 additions and 19 deletions
@@ -7,6 +7,8 @@ class CheckoutEvent with _$CheckoutEvent {
const factory CheckoutEvent.addItem(Product product) = _AddItem;
//remove item
const factory CheckoutEvent.removeItem(Product product) = _RemoveItem;
// Delete Item
const factory CheckoutEvent.deleteItem(Product product) = _DeleteItem;
//add discount
const factory CheckoutEvent.addDiscount(Discount discount) = _AddDiscount;
@@ -20,13 +22,15 @@ class CheckoutEvent with _$CheckoutEvent {
//remove tax
const factory CheckoutEvent.removeTax() = _RemoveTax;
//remove service charge
const factory CheckoutEvent.removeServiceCharge() = _RemoveServiceCharge;
const factory CheckoutEvent.removeServiceCharge() = _RemoveServiceCharge;
//update order type
const factory CheckoutEvent.updateOrderType(OrderType orderType) = _UpdateOrderType;
const factory CheckoutEvent.updateOrderType(OrderType orderType) =
_UpdateOrderType;
//update item notes
const factory CheckoutEvent.updateItemNotes(Product product, String notes) = _UpdateItemNotes;
const factory CheckoutEvent.updateItemNotes(Product product, String notes) =
_UpdateItemNotes;
//save draft order
const factory CheckoutEvent.saveDraftOrder(