????

Your IP : 3.144.92.138


Current Path : /home/thenclexdoctor.com/.trash/app/Models/Observers/
Upload File :
Current File : /home/thenclexdoctor.com/.trash/app/Models/Observers/SaleNumberObserver.php

<?php

namespace App\Models\Observers;

use App\Models\Sale;

class SaleNumberObserver
{
    public function saving(Sale $model)
    {
        // Check if the number is below zero

        if ($model->tax < 0) {
            $model->tax = 0;
        }

        if ($model->commission < 0) {
            $model->commission = 0;
        }

        if ($model->discount < 0) {
            $model->discount = 0;
        }

        if ($model->total_amount < 0) {
            $model->total_amount = 0;
        }
    }
}

Page not found | The NCLEX Doctor

Page not found!

Sorry, this page is not available...