change code in some item
This commit is contained in:
@@ -126,4 +126,18 @@ class Accident extends Model
|
||||
get: fn ($value) => env("PAYMENT_LINK")."/#/pay/".explode("/", $this->bill_code)[0]."/{$this->final_amount}",
|
||||
);
|
||||
}
|
||||
|
||||
protected function depositInsuranceImage(): Attribute
|
||||
{
|
||||
return Attribute::make(
|
||||
get: fn($value) => $value == null ? null : Storage::disk('public')->url($value)
|
||||
);
|
||||
}
|
||||
|
||||
protected function depositIdaghiImage(): Attribute
|
||||
{
|
||||
return Attribute::make(
|
||||
get: fn($value) => $value == null ? null : Storage::disk('public')->url($value)
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -15,6 +15,10 @@ class Mission extends Model
|
||||
|
||||
protected $guarded = [];
|
||||
protected $hidden = ['pivot'];
|
||||
protected $casts = [
|
||||
'start_time' => 'datetime',
|
||||
'finish_time' => 'datetime',
|
||||
];
|
||||
|
||||
protected function requestedMachines(): Attribute
|
||||
{
|
||||
@@ -26,7 +30,7 @@ class Mission extends Model
|
||||
protected function area(): Attribute
|
||||
{
|
||||
return Attribute::make(
|
||||
get: fn($value) => json_decode($value)
|
||||
get: fn($value) => json_decode($value, true)
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user