mirror of
https://github.com/colymba/GridFieldBulkEditingTools.git
synced 2024-10-22 11:05:57 +02:00
FIX Remove deprecated convert API for SS5.0 (#260)
This commit is contained in:
parent
741a20272a
commit
9a8cc3792e
@ -4,7 +4,6 @@ namespace Colymba\BulkManager\BulkAction;
|
||||
|
||||
use Colymba\BulkManager\BulkAction\Handler;
|
||||
use SilverStripe\Control\Controller;
|
||||
use SilverStripe\Core\Convert;
|
||||
use SilverStripe\Control\HTTPResponse;
|
||||
use SilverStripe\Forms\FieldList;
|
||||
use SilverStripe\Forms\Form;
|
||||
@ -373,9 +372,9 @@ class EditHandler extends Handler
|
||||
Requirements::add_i18n_javascript('colymba/gridfield-bulk-editing-tools:lang');
|
||||
|
||||
if ($this->request->isAjax()) {
|
||||
$response = new HTTPResponse(
|
||||
Convert::raw2json(array('Content' => $form->forAjaxTemplate()->getValue()))
|
||||
);
|
||||
$response = new HTTPResponse(json_encode([
|
||||
'Content' => $form->forAjaxTemplate()->getValue()
|
||||
]));
|
||||
$response->addHeader('X-Pjax', 'Content');
|
||||
$response->addHeader('Content-Type', 'text/json');
|
||||
$response->addHeader('X-Title', 'SilverStripe - Bulk ' . $this->gridField->list->dataClass . ' Editing');
|
||||
|
@ -7,7 +7,6 @@ use SilverStripe\Control\Controller;
|
||||
use SilverStripe\Control\RequestHandler;
|
||||
use SilverStripe\Control\HTTPRequest;
|
||||
use SilverStripe\Control\HTTPResponse;
|
||||
use SilverStripe\Core\Convert;
|
||||
use SilverStripe\Versioned\RecursivePublishable;
|
||||
|
||||
use SilverStripe\AssetAdmin\Controller\AssetAdmin;
|
||||
|
Loading…
Reference in New Issue
Block a user