improve array docblock

This commit is contained in:
Dennis Eichhorn 2020-02-08 13:26:44 +01:00
parent 49bbf54621
commit 9db5cc0a22
2 changed files with 10 additions and 3 deletions

View File

@ -17,7 +17,6 @@ namespace Modules\Navigation\Admin;
use Modules\Navigation\Models\NavElement;
use Modules\Navigation\Models\NavElementMapper;
use phpOMS\DataStorage\Database\DatabasePool;
use phpOMS\DataStorage\Database\RelationType;
use phpOMS\Module\InstallerAbstract;
use phpOMS\System\File\PathException;
@ -99,7 +98,7 @@ class Installer extends InstallerAbstract
$navElement->permissionType = $data['permission']['type'] ?? null;
$navElement->permissionElement = $data['permission']['element'] ?? null;
$lastInsertID = NavElementMapper::create($navElement, RelationType::ALL, true);
$lastInsertID = NavElementMapper::create($navElement);
foreach ($data['children'] as $link) {
$parent = ($link['parent'] === null ? $lastInsertID : $link['parent']);

View File

@ -29,7 +29,7 @@ final class NavElementMapper extends DataMapperAbstract
/**
* Columns.
*
* @var array<string, array<string, bool|string>>
* @var array<string, array{name:string, type:string, internal:string, autocomplete?:bool, annotations?:array}>
* @since 1.0.0
*/
protected static array $columns = [
@ -65,4 +65,12 @@ final class NavElementMapper extends DataMapperAbstract
* @since 1.0.0
*/
protected static string $primaryField = 'nav_id';
/**
* Autoincrement primary field.
*
* @var bool
* @since 1.0.0
*/
protected static bool $autoincrement = false;
}