i am trying to update my remaining_quantity by decreasing the checked_out_quantity from the initial Quantity like this but its not working
public function updating(Consumable $consumable)
{
$consumable->remaining_qty = $consumable->quantity - $consumable->checked_out_qty;
$consumable->save();
}
anybody know how i can get it to trigger?
from Newest questions tagged laravel-5 - Stack Overflow http://bit.ly/2HNjbMS
via IFTTT
Aucun commentaire:
Enregistrer un commentaire