在声明多个资源路由时,除了第一个路由之外,其余的都无法正确传递参数。
作者: drahija-gli创建于 2021年12月30日更新于 2021年12月30日
If I send a GET request to `/companies/5837991a-9f8d-47d7-9453-13e1b67bae35` I get a 200 OK response and the request data. However, if I send a GET request to `/roles/0553a087-457a-4124-8669-ca29f4c06c64` or `users/46e8b3a5-085d-4f4a-bf30-411159591b56` I get the 500 Internal Server Error posted above (substitute Controller/Key details). If however, I move the API Resource statements around, for example, putting the Role Routes before the Company Routes, the request to `/roles/0553a087-457a-4124-8669-ca29f4c06c64` will work, but the request to `/companies/5837991a-9f8d-47d7-9453-13e1b67bae35` will fail.
内容来源: dingo/api