mirror of
https://github.com/snipe/snipe-it.git
synced 2025-03-05 20:52:15 -08:00
Fixes all assets showing as unassigned in license checkout
This commit is contained in:
parent
1a7e3fbb4b
commit
be7598b279
|
@ -179,13 +179,14 @@ class Asset extends Depreciable
|
||||||
|
|
||||||
public function getDetailedNameAttribute()
|
public function getDetailedNameAttribute()
|
||||||
{
|
{
|
||||||
if ($this->assignedTo) {
|
if ($this->assignedto) {
|
||||||
$user_name = $this->assignedTo->present()->name();
|
$user_name = $this->assignedto->present()->name();
|
||||||
} else {
|
} else {
|
||||||
$user_name = "Unassigned";
|
$user_name = "Unassigned";
|
||||||
}
|
}
|
||||||
return $this->asset_tag . ' - ' . $this->name . ' (' . $user_name . ') ' . $this->model->name;
|
return $this->asset_tag . ' - ' . $this->name . ' (' . $user_name . ') ' . $this->model->name;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function validationRules($id = '0')
|
public function validationRules($id = '0')
|
||||||
{
|
{
|
||||||
return $this->rules;
|
return $this->rules;
|
||||||
|
|
Loading…
Reference in a new issue