mirror of
https://github.com/silverstripe/silverstripe-cms
synced 2024-10-22 08:05:56 +02:00
ENHANCEMENT Saving tab state for CMSPagesController
This commit is contained in:
parent
c9fc7cda65
commit
ad7c443255
@ -15,6 +15,13 @@ class CMSPagesController extends CMSMain {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return String
|
||||||
|
*/
|
||||||
|
public function ViewState() {
|
||||||
|
return $this->request->getVar('view');
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Doesn't deal with a single record, and we need
|
* Doesn't deal with a single record, and we need
|
||||||
* to avoid session state from previous record edits leaking in here.
|
* to avoid session state from previous record edits leaking in here.
|
||||||
|
@ -9,10 +9,10 @@
|
|||||||
|
|
||||||
<div class="cms-content-header-tabs">
|
<div class="cms-content-header-tabs">
|
||||||
<ul>
|
<ul>
|
||||||
<li class="content-treeview">
|
<li class="content-treeview<% if ViewState == tree %> ui-tabs-selected<% end_if %>">
|
||||||
<a href="#cms-content-treeview" class="cms-panel-link" data-href="$LinkTreeView"><% _t('CMSPagesController.TreeView', 'Tree View') %></a>
|
<a href="#cms-content-treeview" class="cms-panel-link" data-href="$LinkTreeView"><% _t('CMSPagesController.TreeView', 'Tree View') %></a>
|
||||||
</li>
|
</li>
|
||||||
<li class="content-listview">
|
<li class="content-listview<% if ViewState == list %> ui-tabs-selected<% end_if %>">
|
||||||
<a href="#cms-content-listview" class="cms-panel-link" data-href="$LinkListView"><% _t('CMSPagesController.ListView', 'List View') %></a>
|
<a href="#cms-content-listview" class="cms-panel-link" data-href="$LinkListView"><% _t('CMSPagesController.ListView', 'List View') %></a>
|
||||||
</li>
|
</li>
|
||||||
<!--
|
<!--
|
||||||
|
Loading…
Reference in New Issue
Block a user