mirror of
https://github.com/silverstripe/silverstripe-subsites
synced 2024-10-22 11:05:55 +02:00
Merge pull request #318 from creative-commoners/pulls/2.0/subsite-management-ux-fixes
NEW Remove Subsite Configuration header, rename Main tab and remove Domains GridField title
This commit is contained in:
commit
3996810fa9
@ -29,12 +29,12 @@ en:
|
|||||||
CopyToSubsiteWithChildren: 'Include children pages?'
|
CopyToSubsiteWithChildren: 'Include children pages?'
|
||||||
SubsiteOperations: 'Subsite Operations'
|
SubsiteOperations: 'Subsite Operations'
|
||||||
SilverStripe\Subsites\Model\Subsite:
|
SilverStripe\Subsites\Model\Subsite:
|
||||||
|
ConfigurationTab: Configuration
|
||||||
CopyMessage: 'Created a copy of {title}'
|
CopyMessage: 'Created a copy of {title}'
|
||||||
CustomExtraMeta: 'Custom Meta Tags'
|
CustomExtraMeta: 'Custom Meta Tags'
|
||||||
CustomMetaDescription: Description
|
CustomMetaDescription: Description
|
||||||
CustomMetaKeywords: Keywords
|
CustomMetaKeywords: Keywords
|
||||||
CustomMetaTitle: Title
|
CustomMetaTitle: Title
|
||||||
DomainsListTitle: Domains
|
|
||||||
PLURALNAME: Subsites
|
PLURALNAME: Subsites
|
||||||
PLURALS:
|
PLURALS:
|
||||||
one: 'A Subsite'
|
one: 'A Subsite'
|
||||||
@ -43,7 +43,6 @@ en:
|
|||||||
SINGULARNAME: Subsite
|
SINGULARNAME: Subsite
|
||||||
SiteConfigSubtitle: 'Your tagline here'
|
SiteConfigSubtitle: 'Your tagline here'
|
||||||
SiteConfigTitle: 'Your Site Name'
|
SiteConfigTitle: 'Your Site Name'
|
||||||
SubsiteConfigurationHeader: 'Subsite Configuration'
|
|
||||||
ThemeFieldEmptyString: '-'
|
ThemeFieldEmptyString: '-'
|
||||||
ValidateTitle: 'Please add a "Title"'
|
ValidateTitle: 'Please add a "Title"'
|
||||||
SilverStripe\Subsites\Model\SubsiteDomain:
|
SilverStripe\Subsites\Model\SubsiteDomain:
|
||||||
|
@ -657,7 +657,7 @@ class Subsite extends DataObject
|
|||||||
$fields->addFieldsToTab('Root.Domains', [
|
$fields->addFieldsToTab('Root.Domains', [
|
||||||
GridField::create(
|
GridField::create(
|
||||||
'Domains',
|
'Domains',
|
||||||
_t(__CLASS__ . '.DomainsListTitle', 'Domains'),
|
'',
|
||||||
$this->Domains(),
|
$this->Domains(),
|
||||||
GridFieldConfig_RecordEditor::create(10)
|
GridFieldConfig_RecordEditor::create(10)
|
||||||
)
|
)
|
||||||
@ -668,13 +668,6 @@ class Subsite extends DataObject
|
|||||||
// in a wrapper further down. The RedirectURL field is currently not in use.
|
// in a wrapper further down. The RedirectURL field is currently not in use.
|
||||||
$fields->removeByName(['PageTypeBlacklist', 'RedirectURL']);
|
$fields->removeByName(['PageTypeBlacklist', 'RedirectURL']);
|
||||||
|
|
||||||
// Add the heading to the top of the fields list
|
|
||||||
$fields->fieldByName('Root.Main')
|
|
||||||
->unshift(HeaderField::create(
|
|
||||||
'ConfigForSubsiteHeaderField',
|
|
||||||
_t(__CLASS__ . '.SubsiteConfigurationHeader', 'Subsite Configuration')
|
|
||||||
));
|
|
||||||
|
|
||||||
$fields->addFieldToTab('Root.Main', DropdownField::create(
|
$fields->addFieldToTab('Root.Main', DropdownField::create(
|
||||||
'Language',
|
'Language',
|
||||||
$this->fieldLabel('Language'),
|
$this->fieldLabel('Language'),
|
||||||
@ -709,6 +702,9 @@ class Subsite extends DataObject
|
|||||||
|
|
||||||
// We don't need the Groups many many tab
|
// We don't need the Groups many many tab
|
||||||
$fields->removeByName('Groups');
|
$fields->removeByName('Groups');
|
||||||
|
|
||||||
|
// Rename the main tab to configuration
|
||||||
|
$fields->fieldByName('Root.Main')->setTitle(_t(__CLASS__ . '.ConfigurationTab', 'Configuration'));
|
||||||
});
|
});
|
||||||
|
|
||||||
return parent::getCMSFields();
|
return parent::getCMSFields();
|
||||||
|
Loading…
Reference in New Issue
Block a user