diff --git a/src/Extensions/CustomSiteConfig.php b/src/Extensions/CustomSiteConfig.php index cc15c60..9ca1b20 100644 --- a/src/Extensions/CustomSiteConfig.php +++ b/src/Extensions/CustomSiteConfig.php @@ -6,9 +6,12 @@ use SilverStripe\Forms\TextField; use SilverStripe\ORM\DataExtension; use SilverStripe\ORM\FieldType\DBField; +use SilverStripe\SiteConfig\SiteConfig; /** * Adds new global settings. + * + * @extends DataExtension */ class CustomSiteConfig extends DataExtension { diff --git a/src/Extensions/CwpCommentingExtension.php b/src/Extensions/CwpCommentingExtension.php index b5cad6e..eb763fe 100644 --- a/src/Extensions/CwpCommentingExtension.php +++ b/src/Extensions/CwpCommentingExtension.php @@ -2,6 +2,7 @@ namespace CWP\CWP\Extensions; +use SilverStripe\Comments\Controllers\CommentingController; use SilverStripe\Control\Email\Email; use SilverStripe\Core\Extension; use SilverStripe\Forms\Form; @@ -9,7 +10,7 @@ /** * Customises the comment form to conform to government usability standards * - * {@see CommentingController} + * @extends Extension */ class CwpCommentingExtension extends Extension { diff --git a/src/Extensions/CwpSiteTreeExtension.php b/src/Extensions/CwpSiteTreeExtension.php index c6e742f..c6ef886 100644 --- a/src/Extensions/CwpSiteTreeExtension.php +++ b/src/Extensions/CwpSiteTreeExtension.php @@ -2,11 +2,15 @@ namespace CWP\CWP\Extensions; +use SilverStripe\CMS\Model\SiteTree; use SilverStripe\Forms\CheckboxField; use SilverStripe\Forms\FieldList; use SilverStripe\Forms\LiteralField; use SilverStripe\ORM\DataExtension; +/** + * @extends DataExtension + */ class CwpSiteTreeExtension extends DataExtension { private static $db = array( diff --git a/src/Extensions/CwpSiteTreeFileExtension.php b/src/Extensions/CwpSiteTreeFileExtension.php index 3017e7a..112bc58 100644 --- a/src/Extensions/CwpSiteTreeFileExtension.php +++ b/src/Extensions/CwpSiteTreeFileExtension.php @@ -2,15 +2,18 @@ namespace CWP\CWP\Extensions; +use SilverStripe\Assets\File; use SilverStripe\Core\Convert; use SilverStripe\Forms\FieldList; use SilverStripe\Forms\ReadonlyField; use SilverStripe\ORM\DataExtension; use SilverStripe\View\Requirements; +/** + * @extends DataExtension + */ class CwpSiteTreeFileExtension extends DataExtension { - public function updateCMSFields(FieldList $fields) { Requirements::css('cwp/cwp:css/fieldDescriptionToggle.css'); diff --git a/src/Extensions/CwpWorkflowDefinitionExtension.php b/src/Extensions/CwpWorkflowDefinitionExtension.php index 565dcb6..944e34e 100644 --- a/src/Extensions/CwpWorkflowDefinitionExtension.php +++ b/src/Extensions/CwpWorkflowDefinitionExtension.php @@ -9,6 +9,8 @@ /** * Ensures that the default template is created + * + * @extends DataExtension */ class CwpWorkflowDefinitionExtension extends DataExtension { diff --git a/src/Extensions/MaintenanceProxyExtension.php b/src/Extensions/MaintenanceProxyExtension.php index 9f32772..d538e18 100644 --- a/src/Extensions/MaintenanceProxyExtension.php +++ b/src/Extensions/MaintenanceProxyExtension.php @@ -3,6 +3,8 @@ namespace CWP\CWP\Extension; use BringYourOwnIdeas\Maintenance\Reports\SiteSummary; +use BringYourOwnIdeas\Maintenance\Util\ApiLoader; +use BringYourOwnIdeas\Maintenance\Util\ComposerLoader; use SilverStripe\Core\Environment; use SilverStripe\Core\Extension; @@ -10,6 +12,8 @@ * Used to configure proxy settings for bringyourownideas/silverstripe-maintenance and its related modules * * @see https://www.cwp.govt.nz/developer-docs/en/2/how_tos/external_http_requests_with_proxy + * + * @extends Extension */ class MaintenanceProxyExtension extends Extension { diff --git a/src/Extensions/TaxonomyTermExtension.php b/src/Extensions/TaxonomyTermExtension.php index 3567f38..0b230d2 100644 --- a/src/Extensions/TaxonomyTermExtension.php +++ b/src/Extensions/TaxonomyTermExtension.php @@ -6,10 +6,13 @@ use SilverStripe\ORM\DataExtension; use SilverStripe\Forms\FieldList; use SilverStripe\Forms\GridField\GridFieldAddNewButton; +use SilverStripe\Taxonomy\TaxonomyTerm; +/** + * @extends DataExtension + */ class TaxonomyTermExtension extends DataExtension { - private static $api_access = true; private static $belongs_many_many = array( diff --git a/src/PageTypes/BaseHomePageController.php b/src/PageTypes/BaseHomePageController.php index 92a637d..c36fdd2 100644 --- a/src/PageTypes/BaseHomePageController.php +++ b/src/PageTypes/BaseHomePageController.php @@ -4,6 +4,10 @@ use PageController; +/** + * @template T of BaseHomePage + * @extends PageController + */ class BaseHomePageController extends PageController { public function getNewsPage() diff --git a/src/PageTypes/BasePageController.php b/src/PageTypes/BasePageController.php index 032c577..3e550e5 100644 --- a/src/PageTypes/BasePageController.php +++ b/src/PageTypes/BasePageController.php @@ -5,6 +5,10 @@ use SilverStripe\CMS\Controllers\ContentController; use SilverStripe\ORM\FieldType\DBDatetime; +/** + * @template T of BasePage + * @extends ContentController + */ class BasePageController extends ContentController { /** diff --git a/src/PageTypes/DatedUpdateHolderController.php b/src/PageTypes/DatedUpdateHolderController.php index d721ffa..19bf1c1 100644 --- a/src/PageTypes/DatedUpdateHolderController.php +++ b/src/PageTypes/DatedUpdateHolderController.php @@ -32,6 +32,9 @@ * * When the user clicks on a month, pagination will be reset, but tags retained. Pagination retains all other * parameters. + * + * @template T of DatedUpdateHolder + * @extends PageController */ class DatedUpdateHolderController extends PageController { diff --git a/src/PageTypes/EventHolderController.php b/src/PageTypes/EventHolderController.php index 7bf676c..904af16 100644 --- a/src/PageTypes/EventHolderController.php +++ b/src/PageTypes/EventHolderController.php @@ -16,6 +16,8 @@ * * When the user clicks on a month, pagination will be reset, but tags retained. Pagination retains all other * parameters. + * + * @extends DatedUpdateHolderController */ class EventHolderController extends DatedUpdateHolderController { diff --git a/src/PageTypes/EventPageController.php b/src/PageTypes/EventPageController.php index 6d5eab6..d24c89b 100644 --- a/src/PageTypes/EventPageController.php +++ b/src/PageTypes/EventPageController.php @@ -4,6 +4,9 @@ use PageController; +/** + * @extends PageController + */ class EventPageController extends PageController { diff --git a/src/PageTypes/NewsHolderController.php b/src/PageTypes/NewsHolderController.php index 261ef6d..a9fed0d 100644 --- a/src/PageTypes/NewsHolderController.php +++ b/src/PageTypes/NewsHolderController.php @@ -5,6 +5,9 @@ use CWP\Core\Feed\CwpAtomFeed; use SilverStripe\Control\RSS\RSSFeed; +/** + * @extends DatedUpdateHolderController + */ class NewsHolderController extends DatedUpdateHolderController { private static $allowed_actions = [ diff --git a/src/PageTypes/SitemapPageController.php b/src/PageTypes/SitemapPageController.php index 5e2b310..a947bf2 100644 --- a/src/PageTypes/SitemapPageController.php +++ b/src/PageTypes/SitemapPageController.php @@ -5,6 +5,9 @@ use PageController; use SilverStripe\CMS\Model\SiteTree; +/** + * @extends PageController + */ class SitemapPageController extends PageController { private static $allowed_actions = [