Merge branch 'stefanX201-patch-3' into 3.1

This commit is contained in:
Simon Welsh 2014-08-07 20:16:29 +10:00
commit e92896016f

View File

@ -67,8 +67,8 @@ __Example: using a subclass__
// return either true or false
}
public function getStatusFlags(){
$flags = parent::getStatusFlags();
public function getStatusFlags($cached = true) {
$flags = parent::getStatusFlags($cached);
$flags['scheduledtopublish'] = "Scheduled To Publish";
return $flags;
}
@ -78,4 +78,4 @@ The above subclass of `[api:SiteTree]` will add a new flag for indicating its
__'Scheduled To Publish'__ status. The look of the page node will be changed
from ![Normal Page Node](../_images/page_node_normal.png) to ![Scheduled Page Node](../_images/page_node_scheduled.png). The getStatusFlags has an `updateStatusFlags()`
extension point, so the flags can be modified through `DataExtension` rather than
inheritance as well. Deleting existing flags works by simply unsetting the array key.
inheritance as well. Deleting existing flags works by simply unsetting the array key.