mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
FEATURE: Make navigator items more overloadable (from r97376)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@99047 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
1f60bde524
commit
76b366e760
@ -302,7 +302,7 @@ class ContentController extends Controller {
|
||||
Requirements::javascript(SAPPHIRE_DIR . '/thirdparty/jquery/jquery.js');
|
||||
Requirements::customScript(<<<JS
|
||||
(function($) {
|
||||
$('#switchView a').click(function() {
|
||||
$('#switchView a.newWindow').click(function() {
|
||||
var w = window.open(this.href,windowName(this.target));
|
||||
w.focus();
|
||||
return false;
|
||||
@ -341,7 +341,8 @@ JS
|
||||
|
||||
$text = $obj->getHTML($this->dataRecord);
|
||||
if($text) $items .= $text;
|
||||
if(!$message) $message = $obj->getMessage($this);
|
||||
$newMessage = $obj->getMessage($this);
|
||||
if($newMessage) $message = $newMessage;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -25,7 +25,7 @@ class SilverStripeNavigatorItem_StageLink extends SilverStripeNavigatorItem {
|
||||
static $priority = 20;
|
||||
|
||||
function getHTML($controller) {
|
||||
if(Versioned::current_stage() == 'Stage') {
|
||||
if(Versioned::current_stage() == 'Stage' && !(ClassInfo::exists('SiteTreeFutureState') && SiteTreeFutureState::get_future_datetime())) {
|
||||
return "<a class=\"current\">". _t('ContentController.DRAFTSITE', 'Draft Site') ."</a>";
|
||||
} else {
|
||||
$thisPage = $controller->Link();
|
||||
|
@ -7,7 +7,6 @@
|
||||
border-top: 2px solid #d4d0c8;
|
||||
background-color:#81858d;
|
||||
height: 22px;
|
||||
overflow:hidden;
|
||||
background: #4d4e5a url(../../cms/images/textures/footerBg.gif) repeat-x left top;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user