JMSSecurityExtraBundle icon indicating copy to clipboard operation
JMSSecurityExtraBundle copied to clipboard

Annotations from parents don't taken into account

Open qcho opened this issue 12 years ago • 3 comments
trafficstars

Can we expect to have annotations in parent clases? Want to avoid repeating code for it.

PARENT:
/**
 * @PreAuthorize("hasRole('ROLE_ADMIN')")
 */
abstract class BaseAdminController extends Controller
{
    ...
}

CHILDS:
/**
 * Agency controller.
 *
 * @Route("/admin/agency")
 */
class AgencyController extends BaseAdminController
{
    /**
     * Lists all Agency entities.
     *
     * @Route("/", name="admin_agency")
     * @Method("GET")
     * @Template()
     */
    public function indexAction()
    {
        ....
    }
}

The indexAction doesn't have the ROLE_ADMIN check.

qcho avatar Mar 03 '13 17:03 qcho

Sory for the duplicate issue, just realized it #83. It has a slight difference I'm referring to Classes not methods.

qcho avatar Mar 03 '13 17:03 qcho

+1 2 years and no solution ?

coelhoricardo avatar Sep 23 '15 08:09 coelhoricardo

@coelhoricardo i have the same issue:

https://github.com/schmittjoh/JMSSecurityExtraBundle/pull/128 (see the comment)

d3vpunk avatar Oct 27 '15 09:10 d3vpunk