How to extend attribute repository properly


#1

i am trying to add custom function to product attribute repository
but i don’t know why it’s hard to manage config for attribute resource unlike any other resource in sylius
here is my config

sylius_attribute:
driver: doctrine/orm
resources:
product:
subject: Sylius\Component\Core\Model\Product
attribute:
classes:
repository: AppBundle\Repository\AttributeRepository

and it works fine but why i try to add attrbiute from admin dashboard i get this error

Parameter “id” for route “sylius_admin_product_attribute_update” must match “[^/]++” ("" given) to generate a corresponding URL.

i am sure that the problem is in my config but i don’t know what config i should add ?
thanks