From 0fb6a92e257771ba8af6192c040ab41f2e14b93b Mon Sep 17 00:00:00 2001 From: brandonkelly Date: Mon, 4 Nov 2024 06:00:23 -0800 Subject: [PATCH] Unused methods --- src/Command.php | 33 --------------------------------- 1 file changed, 33 deletions(-) diff --git a/src/Command.php b/src/Command.php index d80d746..d458829 100644 --- a/src/Command.php +++ b/src/Command.php @@ -950,39 +950,6 @@ function() use ($uid, $name, $handle, $populate, &$tagGroup) { return $tagGroup; } - private function fieldLayout(array $elements = []): FieldLayout - { - $fieldLayout = new FieldLayout(); - $fieldLayout->setTabs([ - new FieldLayoutTab([ - 'layout' => $fieldLayout, - 'name' => 'Content', - 'elements' => $elements, - ]), - ]); - return $fieldLayout; - } - - private function assignFieldToEntryType(FieldInterface $field, EntryType $entryType): void - { - $fieldLayout = $entryType->getFieldLayout(); - if (!$fieldLayout->getFieldById($field->id)) { - $tab = $fieldLayout->getTabs()[0] ?? null; - if (!$tab) { - $tab = new FieldLayoutTab([ - 'name' => 'Content', - 'layout' => $fieldLayout, - ]); - $fieldLayout->setTabs([$tab]); - } - - $elements = $tab->getElements(); - $elements[] = new CustomField($field); - $tab->setElements($elements); - Craft::$app->entries->saveEntryType($entryType); - } - } - public function import(string $resource, int|array $data, array $queryParams = []): int { $importer = $this->importers[$resource] ?? null;