Take redirect uri from controller class.

This commit is contained in:
James Cole 2017-09-29 16:53:09 +02:00
parent 40f2659b91
commit cca29bcdfe
No known key found for this signature in database
GPG Key ID: C16961E655E74B5E

View File

@ -44,6 +44,8 @@ class Controller extends BaseController
protected $monthAndDayFormat;
/** @var string */
protected $monthFormat;
/** @var string */
protected $redirectUri = '/';
/**
* Controller constructor.
@ -116,10 +118,10 @@ class Controller extends BaseController
{
$uri = strval(session($identifier));
if (!(strpos($identifier, 'delete') === false) && !(strpos($uri, '/show/') === false)) {
$uri = route('index');
$uri = $this->redirectUri;
}
if (!(strpos($uri, 'jscript') === false)) {
$uri = route('index');
$uri = $this->redirectUri;
}
return $uri;