fixes
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
|
||||
namespace App\Models\Shop;
|
||||
|
||||
use App\Repositories\Core\DateTime;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Relations\BelongsTo;
|
||||
use Venturecraft\Revisionable\RevisionableTrait;
|
||||
@@ -47,4 +48,14 @@ class InvoicePayment extends Model
|
||||
{
|
||||
return $query->where('payment_type', $paymentType);
|
||||
}
|
||||
|
||||
public function getDateAttribute($value)
|
||||
{
|
||||
return DateTime::dateToLocale($value);
|
||||
}
|
||||
|
||||
public function setDateAttribute($value)
|
||||
{
|
||||
$this->attributes['date'] = DateTime::convert($value);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user