[TASK] Add getGetValue() and $componentMode

This commit is contained in:
Philipp Dieter 2020-10-06 00:56:05 +02:00
parent 4680bce585
commit 5e7953acde

View File

@ -86,6 +86,11 @@ class ActionController extends BaseController
*/
protected $responseStatus = 200;
/**
* component mode, used in frontend
*/
protected $componentMode = 'default';
/**
* redirect url
*/
@ -331,6 +336,18 @@ class ActionController extends BaseController
return false;
}
/**
*
*/
protected function getGetValue(
$argument
) {
if (GeneralUtility::_GP($argument)) {
return GeneralUtility::_GP($argument);
}
return false;
}
/**
* shortcut to get translation
*
@ -655,8 +672,12 @@ class ActionController extends BaseController
}
return json_encode($result);
}
$result = array_merge($result, ['cid' => $this->contentObjectUid]);
$result = array_merge($result, ['isValid' => $this->isValid]);
$result = array_merge(
$result,
['cid' => $this->contentObjectUid],
['isValid' => $this->isValid],
['componentMode' => $this->componentMode]
);
if (!empty($this->ajaxEnv)) {
$result = array_merge(
$result,