Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

API: Add history tab. Migrate content style variants to BaseElement #123

Merged
merged 17 commits into from Oct 30, 2017

Conversation

wilr
Copy link
Member

@wilr wilr commented Oct 19, 2017

History tab changes and report.

Blockers:

Report blockers:

$elements[$key] = $this->stripNamespacing($value);
}
$config = GridFieldConfig_RecordViewer::create();
$config->removeComponentsByType('SilverStripe\Forms\GridField\GridFieldPageCount');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor: it'd be a little more consistent to use GridFieldPageCount::class here

@wilr wilr changed the title CC-126 Add history tab to elements Add history tab to elements Oct 19, 2017
@wilr wilr changed the title Add history tab to elements API: Add history tab. Migrate content style variants to BaseElement Oct 19, 2017
@robbieaverill robbieaverill self-assigned this Oct 27, 2017
@robbieaverill robbieaverill changed the title API: Add history tab. Migrate content style variants to BaseElement WIP: API: Add history tab. Migrate content style variants to BaseElement Oct 27, 2017
@robbieaverill
Copy link
Contributor

robbieaverill commented Oct 27, 2017

Updates required:

  • Core: don't show GridField header if empty string is given (null renders the GridField name, empty string renders a tr+th with nothing in it) Removed GridFieldToolbarHeader in BaseElement GridField
  • Remove sort on ID column
  • Hide actions via JS when going into History tab, show again when changing out of it
  • Show blue header bar (see Invision designs) to indicate which history record you're viewing

Address separately:

  • Don't show draft records when they were published immediately (e.g. draft ID === live ID) - check CMS page history to see how this is handled there
  • Show draft records if saved then revisited later and published with no extra changes

@robbieaverill robbieaverill changed the title WIP: API: Add history tab. Migrate content style variants to BaseElement API: Add history tab. Migrate content style variants to BaseElement Oct 30, 2017
@robbieaverill
Copy link
Contributor

A few issues came up while testing this, I'll log them individually once merged.

@robbieaverill
Copy link
Contributor

Report removed from this pull request, it will be reintroduced in a separate pull request.

README.md Outdated
private static $controller_template = 'MyElementHolder';
```

To customise existing block templates such as `Content` and `Form` templates copy the relevant files from
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

- templates copy
+ templates, copy

@@ -11,8 +11,7 @@ class ElementContent extends BaseElement
private static $icon = 'dnadesign/silverstripe-elemental:images/content.svg';

private static $db = [
'HTML' => 'HTMLText',
'Style' => 'Varchar(255)'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why was this removed?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Moved to base element

@robbieaverill
Copy link
Contributor

robbieaverill commented Oct 30, 2017

@NightJar I've fixed the docs typo and rebased

@NightJar NightJar merged commit b1117b3 into silverstripe:master Oct 30, 2017
@NightJar NightJar deleted the pulls/history-view branch October 30, 2017 22:45
@robbieaverill robbieaverill removed their assignment Apr 4, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants