diff --git a/Admin/Installer.php b/Admin/Installer.php index 92710d2..6d55a69 100755 --- a/Admin/Installer.php +++ b/Admin/Installer.php @@ -149,7 +149,7 @@ final class Installer extends InstallerAbstract return []; } - /** @var \Modules\Editor\Models\EditorDocType $type */ + /** @var \phpOMS\Localization\BaseStringL11nType $type */ $type = $responseData['response']; $id = $type->id; diff --git a/Controller/ApiDocTypeController.php b/Controller/ApiDocTypeController.php index b62b146..25664b8 100644 --- a/Controller/ApiDocTypeController.php +++ b/Controller/ApiDocTypeController.php @@ -261,7 +261,7 @@ final class ApiDocTypeController extends Controller return; } - /** @var \Modules\Editor\Models\EditorDocType $contractType */ + /** @var BaseStringL11nType $contractType */ $contractType = EditorDocTypeMapper::get()->where('id', (int) $request->getData('id'))->execute(); $this->deleteModel($request->header->account, $contractType, EditorDocTypeMapper::class, 'contract_type', $request->getOrigin()); $this->createStandardDeleteResponse($request, $response, $contractType); @@ -377,7 +377,7 @@ final class ApiDocTypeController extends Controller return; } - /** @var \Modules\Editor\Models\EditorDocTypeL11n $contractTypeL11n */ + /** @var BaseStringL11n $contractTypeL11n */ $contractTypeL11n = EditorDocTypeL11nMapper::get()->where('id', (int) $request->getData('id'))->execute(); $this->deleteModel($request->header->account, $contractTypeL11n, EditorDocTypeL11nMapper::class, 'contract_type_l11n', $request->getOrigin()); $this->createStandardDeleteResponse($request, $response, $contractTypeL11n); diff --git a/Models/EditorDoc.php b/Models/EditorDoc.php index ec17961..97a55b4 100755 --- a/Models/EditorDoc.php +++ b/Models/EditorDoc.php @@ -73,7 +73,7 @@ class EditorDoc implements \JsonSerializable /** * Type. * - * @var null|EditorDocType + * @var null|BaseStringL11nType * @since 1.0.0 */ public ?BaseStringL11nType $type = null; diff --git a/Models/EditorDocListTrait.php b/Models/EditorDocListTrait.php index 3ef6e06..3049ac6 100644 --- a/Models/EditorDocListTrait.php +++ b/Models/EditorDocListTrait.php @@ -87,7 +87,7 @@ trait EditorDocListTrait { $notes = []; foreach ($this->notes as $note) { - if ($note->type?->name === $type) { + if ($note->type?->title === $type) { $notes[] = $note; } } @@ -107,7 +107,7 @@ trait EditorDocListTrait public function hasEditorDocTypeName(string $type) : bool { foreach ($this->notes as $note) { - if ($note->type?->name === $type) { + if ($note->type?->title === $type) { return true; } }