Skip to content

Commit

Permalink
Merge pull request #84 from nswdpc/feat-content-block
Browse files Browse the repository at this point in the history
(enh) Tidy content block by moving seldom used image and link to thei…
  • Loading branch information
JamesDPC authored Mar 4, 2024
2 parents fa2a775 + cd3ff5e commit 3085a43
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/Extensions/ElementContentExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,8 @@ public function updateCMSFields(FieldList $fields)
}

$fields->removeByName(['ContentLinkID']);
$fields->addFieldsToTab(
'Root.Main',
[
$fields->addFieldToTab(
'Root.Image',
UploadField::create(
'ContentImage',
_t('nswds.IMAGE', 'Image')
Expand All @@ -107,11 +106,12 @@ public function updateCMSFields(FieldList $fields)
'types' => implode(",", $this->owner->getAllowedFileTypes())
]
)
),
)
);
$fields->addFieldToTab(
'Root.Link',
$this->getLinkField()
], 'ParentID'
);

}

/**
Expand Down

0 comments on commit 3085a43

Please sign in to comment.