Source of file CMSBatchAction_Archive.php
Size: 0,700 Bytes - Last Modified: 2021-12-23T10:28:18+00:00
/var/www/docs.ssmods.com/process/src/code/BatchActions/CMSBatchAction_Archive.php
1234567891011121314151617181920212223242526272829303132 | <?php namespace SilverStripe\CMS\BatchActions; use SilverStripe\ORM\SS_List; use SilverStripe\Admin\CMSBatchAction; /** * Delete items batch action. */ class CMSBatchAction_Archive extends CMSBatchAction { public function getActionTitle() { return _t(__CLASS__ . '.TITLE', 'Unpublish and archive'); } public function run(SS_List $pages) { return $this->batchaction( $pages, 'doArchive', _t(__CLASS__ . '.RESULT', 'Deleted %d pages from draft and live, and sent them to the archive') ); } public function applicablePages($ids) { return $this->applicablePagesHelper($ids, 'canArchive'); } } |