SilverStripe\Admin\CMSBatchAction::batchaction
Helper method for processing batch actions.
Returns a set of status-updating JavaScript to return to the CMS.
Signature
public function batchaction(SS_List
$objs,
string
$helperMethod,
string
$successMessage,
[array
$arguments = ] )
Parameters
$objs
— SilverStripe\ORM\SS_List- The SS_List of objects to perform this batch action
on. $helperMethod
— string- The method to call on each of those objects.
$successMessage
— string$arguments
— array
Returns
- string
- JSON encoded map in the following format:
{ 'modified': { 3: {'TreeTitle': 'Page3'}, 5: {'TreeTitle': 'Page5'} }, 'deleted': { // all deleted pages } }