-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
23 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -26,16 +26,18 @@ | |
* This copyright notice MUST APPEAR in all copies of the script! | ||
***************************************************************/ | ||
|
||
use Macopedia\Community\Controller\Cacheable\ControllerInterface; | ||
use Macopedia\Community\Domain\Model\Group; | ||
use Macopedia\Community\Domain\Model\User; | ||
use Macopedia\Community\Helper\GroupHelper; | ||
use TYPO3\CMS\Extbase\Annotation as Extbase; | ||
|
||
/** | ||
* Controller for the Group object | ||
* | ||
* @author Pascal Jungblut <[email protected]> | ||
*/ | ||
class GroupController extends BaseController implements \Macopedia\Community\Controller\Cacheable\ControllerInterface | ||
class GroupController extends BaseController implements ControllerInterface | ||
{ | ||
/** | ||
* Show the form to create a new group | ||
|
@@ -80,7 +82,7 @@ public function createAction(Group $group) | |
* Display the form to edit a group | ||
* | ||
* @param Group $group | ||
* @dontvalidate $group | ||
* @Extbase\IgnoreValidation("group") | ||
*/ | ||
public function editAction(Group $group) | ||
{ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -26,9 +26,13 @@ | |
* This copyright notice MUST APPEAR in all copies of the script! | ||
***************************************************************/ | ||
|
||
use Macopedia\Community\Controller\Cacheable\ControllerInterface; | ||
use Macopedia\Community\Domain\Model\Album; | ||
use Macopedia\Community\Domain\Model\Photo; | ||
use Macopedia\Community\Domain\Model\User; | ||
use Macopedia\Community\Service\Notification\Notification; | ||
use SJBR\StaticInfoTables\Domain\Repository\CountryRepository; | ||
use TYPO3\CMS\Core\Messaging\FlashMessage; | ||
|
||
/** | ||
* Controller for the User object | ||
|
@@ -38,7 +42,7 @@ | |
* @license http://www.gnu.org/licenses/gpl.html GNU General Public License, version 3 or later | ||
* @author Pascal Jungblut <[email protected]> | ||
*/ | ||
class UserController extends BaseController implements \Macopedia\Community\Controller\Cacheable\ControllerInterface | ||
class UserController extends BaseController implements ControllerInterface | ||
{ | ||
/** | ||
* @var \SJBR\StaticInfoTables\Domain\Repository\CountryRepository | ||
|
@@ -50,7 +54,7 @@ class UserController extends BaseController implements \Macopedia\Community\Cont | |
* | ||
* @param \SJBR\StaticInfoTables\Domain\Repository\CountryRepository $repository repository to inject | ||
*/ | ||
public function injectStaticCountryRepository(\SJBR\StaticInfoTables\Domain\Repository\CountryRepository $repository) | ||
public function injectStaticCountryRepository(CountryRepository $repository) | ||
{ | ||
$this->staticCountryRepository = $repository; | ||
} | ||
|
@@ -162,7 +166,7 @@ public function updateImageAction(User $user) | |
$this->addFlashMessage($this->_('profile.updateImage.success')); | ||
$this->redirect('edit', 'User', null, ['user' => $user]); | ||
} else { | ||
$this->addFlashMessage($this->_('profile.updateImage.error'), '', \TYPO3\CMS\Core\Messaging\FlashMessage::ERROR); | ||
$this->addFlashMessage($this->_('profile.updateImage.error'), '', FlashMessage::ERROR); | ||
$this->redirect('editImage', 'User', null, ['user' => $user]); | ||
} | ||
} | ||
|
@@ -241,11 +245,11 @@ public function searchBoxAction() | |
public function reportAction(User $user, $reason = '') | ||
{ | ||
if ($this->settings['profile']['reasonForReportRequired'] && strlen($reason) == 0) { | ||
$this->addFlashMessage($this->_('profile.report.needReason'), '', \TYPO3\CMS\Core\Messaging\FlashMessage::ERROR); | ||
$this->addFlashMessage($this->_('profile.report.needReason'), '', FlashMessage::ERROR); | ||
} else { | ||
$this->addFlashMessage($this->_('profile.report.reported')); | ||
|
||
$notification = new \Macopedia\Community\Service\Notification\Notification( | ||
$notification = new Notification( | ||
'userReport', | ||
$this->requestingUser, | ||
$this->requestedUser | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -28,6 +28,10 @@ | |
|
||
use Macopedia\Community\Domain\Model\Relation; | ||
use Macopedia\Community\Domain\Model\User; | ||
use Macopedia\Community\Service\RepositoryServiceInterface; | ||
use Macopedia\Community\Service\SettingsService; | ||
use TYPO3\CMS\Core\SingletonInterface; | ||
use TYPO3\CMS\Extbase\Object\ObjectManagerInterface; | ||
|
||
/** | ||
* A simple access helper. | ||
|
@@ -37,7 +41,7 @@ | |
* @license http://www.gnu.org/licenses/gpl.html GNU General Public License, version 3 or later | ||
* @author Pascal Jungblut <[email protected]> | ||
*/ | ||
class SimpleAccessService implements AccessServiceInterface, \TYPO3\CMS\Core\SingletonInterface | ||
class SimpleAccessService implements AccessServiceInterface, SingletonInterface | ||
{ | ||
/** | ||
* Logged out users, and requested user not set | ||
|
@@ -132,7 +136,7 @@ public function sameUser($requestingUser, $requestedUser) | |
* | ||
* @param \Macopedia\Community\Service\RepositoryServiceInterface $repositoryService | ||
*/ | ||
public function injectRepositoryService(\Macopedia\Community\Service\RepositoryServiceInterface $repositoryService) | ||
public function injectRepositoryService(RepositoryServiceInterface $repositoryService) | ||
{ | ||
$this->repositoryService = $repositoryService; | ||
} | ||
|
@@ -142,7 +146,7 @@ public function injectRepositoryService(\Macopedia\Community\Service\RepositoryS | |
* | ||
* @param \TYPO3\CMS\Extbase\Object\ObjectManagerInterface $objectManager | ||
*/ | ||
public function injectObjectManager(\TYPO3\CMS\Extbase\Object\ObjectManagerInterface $objectManager) | ||
public function injectObjectManager(ObjectManagerInterface $objectManager) | ||
{ | ||
$this->objectManager = $objectManager; | ||
} | ||
|
@@ -152,7 +156,7 @@ public function injectObjectManager(\TYPO3\CMS\Extbase\Object\ObjectManagerInter | |
* | ||
* @param \Macopedia\Community\Service\SettingsService $settingsService | ||
*/ | ||
public function injectSettingsService(\Macopedia\Community\Service\SettingsService $settingsService) | ||
public function injectSettingsService(SettingsService $settingsService) | ||
{ | ||
$this->settingsService = $settingsService; | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters