login - TYPO3 Plugin - One action public access and one private -
i'm developing extension have both, list of records (action show
) , form send new record (action new
).
the list must public access, form must require login form (i'm using login form content type comes typo3).
i have tried using access tab plugin selecting show @ login applies entire plugin not each action.
currently, how page looks like:
how display login form when tries create new record?
note: extension based on extbase , fluid. target version typo3 6.2.
the easiest split actions in different "views" switchablecontrolleractions
in flexform. need place separate plugins on 2 different pages, way can have different access configuration plugins. if don't know how adjust flexform, can post content of here.
the other way make check inside controller, use if have lot of different roles need check.
if ($this->loginuser === null && $globals['tsfe']->loginuser && !empty($globals['tsfe']->fe_user->user['uid'])) { // user logged in } else { // return '' action content return ''; }
Comments
Post a Comment