Update Composer packages
This commit is contained in:
parent
d482354bdf
commit
e7e7361480
219 changed files with 6487 additions and 4444 deletions
|
@ -26,6 +26,8 @@ class Item
|
|||
|
||||
public const ITEMS_CLASS = Items::class;
|
||||
|
||||
protected Field|null $field;
|
||||
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
|
@ -57,6 +59,7 @@ class Item
|
|||
|
||||
$this->id = $params['id'] ?? Str::uuid();
|
||||
$this->params = $params;
|
||||
$this->field = $params['field'] ?? null;
|
||||
$this->parent = $params['parent'] ?? App::instance()->site();
|
||||
$this->siblings = $params['siblings'] ?? new $siblingsClass();
|
||||
}
|
||||
|
@ -72,6 +75,14 @@ class Item
|
|||
return new static($params);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the parent field if known
|
||||
*/
|
||||
public function field(): Field|null
|
||||
{
|
||||
return $this->field;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the unique item id (UUID v4)
|
||||
*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue