philiplb / CRUDlex

CRUDlex is an easy to use CRUD generator for Symfony 4 and Silex 2 which is great for auto generated admin pages
https://philiplb.de/crudlex/
MIT License
109 stars 23 forks source link

Issue with type: many #102

Closed th-lange closed 4 years ago

th-lange commented 5 years ago

crud.yml

user:
  label: User
  table: user
  listFields: [id, email, user_role]
  filter: [email, user_role]
.........
    user_role:
      type: many
      label: Roles
      many:
        hideId: true
        entity: role
        nameField: group
        thisField: user_id
        thatField: role_id

Leads to the error:

An exception has been thrown during the rendering of a template ("An exception occurred while executing 'SELECT id,group FROM role t1 WHERE deleted_at IS NULL ORDER BY group ASC':

I think the ORDER BY group ASC should be like `group`.