|
@@ -154,4 +154,18 @@ class SecurityController extends Controller
|
|
|
|
|
|
}
|
|
|
|
|
|
+ /**
|
|
|
+ * @Route("/admin/resettokens", name="admin_resettokens")
|
|
|
+ */
|
|
|
+ public function resetTokensAction()
|
|
|
+ {
|
|
|
+ $em = $this->getDoctrine()->getManager();
|
|
|
+ $users = $em->getRepository('AppBundle:User')->findAll();
|
|
|
+ foreach ($users as $user)
|
|
|
+ {
|
|
|
+ $user->setToken();
|
|
|
+ }
|
|
|
+ $em->flush();
|
|
|
+ return $this->redirectToRoute('admin_index');
|
|
|
+ }
|
|
|
}
|