get choosen item id

i have this code
$total_amount = Pay::where('purchase_id', $purchase_id)
->where('item_id', '!=', $excluded_item_id) // Exclude the specific item
->sum('amount');
$total_amount = Pay::where('purchase_id', $purchase_id)
->where('item_id', '!=', $excluded_item_id) // Exclude the specific item
->sum('amount');
i want get choosen item id to pass for exlcuded_item_id
1 Reply
gigiloouu
gigiloouu4mo ago
like when i click edit i want to get this item id is it normal to take from $this->mountedTableActionRecord ???