|
@@ 2220-2227 (lines=8) @@
|
| 2217 |
|
return $actions; |
| 2218 |
|
} |
| 2219 |
|
|
| 2220 |
|
if($this->isPublished() && $this->canPublish() && !$this->getIsDeletedFromStage() && $this->canUnpublish()) { |
| 2221 |
|
// "unpublish" |
| 2222 |
|
$moreOptions->push( |
| 2223 |
|
FormAction::create('unpublish', _t('SiteTree.BUTTONUNPUBLISH', 'Unpublish'), 'delete') |
| 2224 |
|
->setDescription(_t('SiteTree.BUTTONUNPUBLISHDESC', 'Remove this page from the published site')) |
| 2225 |
|
->addExtraClass('ss-ui-action-destructive') |
| 2226 |
|
); |
| 2227 |
|
} |
| 2228 |
|
|
| 2229 |
|
if($this->stagesDiffer('Stage', 'Live') && !$this->getIsDeletedFromStage()) { |
| 2230 |
|
if($this->isPublished() && $this->canEdit()) { |
|
@@ 2229-2237 (lines=9) @@
|
| 2226 |
|
); |
| 2227 |
|
} |
| 2228 |
|
|
| 2229 |
|
if($this->stagesDiffer('Stage', 'Live') && !$this->getIsDeletedFromStage()) { |
| 2230 |
|
if($this->isPublished() && $this->canEdit()) { |
| 2231 |
|
// "rollback" |
| 2232 |
|
$moreOptions->push( |
| 2233 |
|
FormAction::create('rollback', _t('SiteTree.BUTTONCANCELDRAFT', 'Cancel draft changes'), 'delete') |
| 2234 |
|
->setDescription(_t('SiteTree.BUTTONCANCELDRAFTDESC', 'Delete your draft and revert to the currently published page')) |
| 2235 |
|
); |
| 2236 |
|
} |
| 2237 |
|
} |
| 2238 |
|
|
| 2239 |
|
if($this->canEdit()) { |
| 2240 |
|
if($this->getIsDeletedFromStage()) { |